Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
��.vs/
.vs/
77 changes: 77 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@

# Quake 2 Assassins Creed Mod

This mod takes some features from the game franchise Assassins Creed and implements them into the game Quake 2. These features include the some stealth and movement mechanics, as well as weapons and tools used in many of the games.


## Authors

- [@Frokey17](https://www.github.com/Frokey17)


## How To Play

1. Go to my git hub account which should be linked in Authors
2. Click on quake2-mod and then click on the branch named ac_mod
3. Download or extract the mod folder and implement it as a new folder into your Quake 2 file
4. Launch Quake 2 and then in the console type "set game <name of your folder>"
5. Start a new game and enjoy



## Features

- Weapons
- Blaster
- Fires an invisble projectile at close range
- Tweaked damage
- BFG
- Can only be fired when the play isn't moving
- Tweaked projectile speed
- Grenande Launcher
- Now shoots mutiple grenades at once which explode in short intervals
- Causes enemies to lose player agro for 8 seconds
- No longer does damage
- Shotgun
- Now produces particles when fired
- Tweaked spread
- Super Shotgun
- Now produces particles when fired
- Tweaked spread
- Hyperblaster
- Zooms in player screen when held and unzooms when not
- No longer fires any projectiles
- Hand Grenande
- Causes enemies to lose player agro for 3 seconds
- No longer does damage
- Tweaked timer
- Machine Gun
- Now shoots accuratly
- Projectiles fired now do damage over time
- Tweaked firerate
- Tweaked damage
- Chain Gun
- Now shoots accuratly
- Projectiles now freeze enemies in place and make them lose player agro
- Tweaked firerate
- Railgun
- Projectiles now teleport enemies in front of the player
- Tweaked damage
- Tweaked kick
- Stealth Mechanics
- Added code to the enemy AI so that they lose agro on the player if the player is crouching or in water
- Movement Mechanics
- Removed the ground check on jumping so that the player can infinitely jump even in mid air, allowing them to wall climb
- Added code so that if the player is moving into a wall while falling, their fall speed is decreased by half, allowing them to wall run.
- Commands
- ModHelp
- Shows a help screen with fixes to common issues
- Gives instructions on how to get to HelpWeapons and HelpMove
- HelpWeapons
- Shows a help screen with fixes to weapon problems and reccomended ways to use them.
- Gives instructions on how to get to ModHelp
- HelpMove
- Shows a help screen with fixes to stealth and movement problems, as well as reccomended ways to use them
- Gives instructions on how to get to ModHelp


8 changes: 4 additions & 4 deletions ctf/ctf.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -26,22 +26,22 @@
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug Alpha|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<PlatformToolset>v142</PlatformToolset>
<PlatformToolset>v143</PlatformToolset>
<UseOfMfc>false</UseOfMfc>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<PlatformToolset>v142</PlatformToolset>
<PlatformToolset>v143</PlatformToolset>
<UseOfMfc>false</UseOfMfc>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release Alpha|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<PlatformToolset>v142</PlatformToolset>
<PlatformToolset>v143</PlatformToolset>
<UseOfMfc>false</UseOfMfc>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>DynamicLibrary</ConfigurationType>
<PlatformToolset>v142</PlatformToolset>
<PlatformToolset>v143</PlatformToolset>
<UseOfMfc>false</UseOfMfc>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
Expand Down
Empty file added g_acmelee.h
Empty file.
109 changes: 109 additions & 0 deletions game/g_acmelee.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,109 @@
/*
* sword variable definitions, I have this here because the sword is most likely still unbalanced
* I know this because I killed a super tank with it without taking ANY damaga
*/
#define SWORD_NORMAL_DAMAGE 100
#define SWORD_DEATHMATCH_DAMAGE 150
#define SWORD_KICK 500

/*
===========
fire_sword
===========
*/
void fire_sword(edict_t* self, vec3_t start, vec3_t aimdir, int damage, int kick)
{
//You may recognize a lot of this from the fire lead command, which
//is the one that I understood best what the hell was going on

trace_t tr; //Not entirely sure what this is, I know that it is used
//to trace out the route of the weapon being used...gotta limit it

vec3_t dir; //Another point I am unclear about
vec3_t forward; //maybe someday I will know a little bit
vec3_t right; //better about what these are
vec3_t up;
vec3_t end;

tr = gi.trace(self->s.origin, NULL, NULL, start, self, MASK_SHOT);

if (!(tr.fraction < 1.0)) //I can only assume this has something to do
//with the progress of the trace
{
vectoangles(aimdir, dir);
AngleVectors(dir, forward, right, up); //possibly sets some of the angle vectors
//as standards?

VectorMA(start, 8192, forward, end); //This does some extension of the vector...
//note how short I have this attack going
}

//The fire_lead had an awful lot of stuff in here dealing with the effect of the shot
//upon water and whatnot, but a sword doesn't make you worry about that sort of stuff
//thats why highlanders are so damn cool.

if (!((tr.surface) && (tr.surface->flags & SURF_SKY)))
{
if (tr.fraction < 1.0)
{
if (tr.ent->takedamage)
{
//This tells us to damage the thing that in our path...hehehehegit
T_Damage(tr.ent, self, self, aimdir, tr.endpos, tr.plane.normal, damage, kick, 0, 1);
}
else
{
if (strncmp(tr.surface->name, "sky", 3) != 0)
{
gi.WriteByte(svc_temp_entity);
gi.WriteByte(TE_GUNSHOT);
gi.WritePosition(tr.endpos);
gi.WriteDir(tr.plane.normal);
gi.multicast(tr.endpos, MULTICAST_PVS);

if (self->client)
PlayerNoise(self, tr.endpos, PNOISE_IMPACT);
}
}
}
}
return;
}

void sword_attack(edict_t* ent, vec3_t g_offset, int damage)
{
vec3_t forward, right;
vec3_t start;
vec3_t offset;

if (is_quad)
damage *= 4;
AngleVectors(ent->client->v_angle, forward, right, NULL);
VectorSet(offset, 24, 8, ent->viewheight - 8);
VectorAdd(offset, g_offset, offset);
P_ProjectSource(ent->client, ent->s.origin, offset, forward, right, start);

VectorScale(forward, -2, ent->client->kick_origin);
ent->client->kick_angles[0] = -1;

fire_sword(ent, start, forward, damage, SWORD_KICK);
}

void Weapon_Sword_Fire(edict_t* ent)
{
int damage;
if (deathmatch->value)
damage = SWORD_DEATHMATCH_DAMAGE;
else
damage = SWORD_NORMAL_DAMAGE;
sword_attack(ent, vec3_origin, damage);
ent->client->ps.gunframe++;
}

void Weapon_Sword (edict_t *ent)
{
static int pause_frames[] = {19, 32, 0};
static int fire_frames[] = {5, 0};

Weapon_Generic (ent, 4, 8, 52, 55, pause_frames, fire_frames, Weapon_Sword_Fire);
}
21 changes: 21 additions & 0 deletions game/g_ai.c
Original file line number Diff line number Diff line change
Expand Up @@ -773,6 +773,27 @@ qboolean ai_checkattack (edict_t *self, float dist)
vec3_t temp;
qboolean hesDeadJim;

if (self->enemy && self->enemy->client && (self->enemy->flags & FL_NOTARGET))
{
self->enemy = NULL;
self->oldenemy = NULL;
self->monsterinfo.stand(self);
return false;
}

if (self->enemy && self->enemy->client) {

if (self->enemy->client->ps.pmove.pm_flags & PMF_DUCKED) {
self->monsterinfo.stand(self);
return false;
}

if (self->enemy->waterlevel > 0) {
self->monsterinfo.stand(self);
return false;
}
}

// this causes monsters to run blindly to the combat point w/o firing
if (self->goalentity)
{
Expand Down
52 changes: 52 additions & 0 deletions game/g_cmds.c
Original file line number Diff line number Diff line change
Expand Up @@ -899,6 +899,51 @@ void Cmd_PlayerList_f(edict_t *ent)
gi.cprintf(ent, PRINT_HIGH, "%s", text);
}

//new commands
void Cmd_ModHelp_f(edict_t* ent) {
gi.cprintf(ent, PRINT_HIGH,
"===Common Problems===\n");
gi.cprintf(ent, PRINT_HIGH,
"Game might freeze for a little when first using the mods\n");
gi.cprintf(ent, PRINT_HIGH,
"Dont use rocket launcher or starter pistol since they were just used to test if mod would compile\n");
gi.cprintf(ent, PRINT_HIGH,
"If enemies are stuck frozen just damage them to make them move again\n");
gi.cprintf(ent, PRINT_HIGH,
"For more info on weapons type HelpWeapons\n");
gi.cprintf(ent, PRINT_HIGH,
"For more info on stealth and movement type HelpMove\n");
}

void Cmd_HelpWeapons_f(edict_t* ent) {
gi.cprintf(ent, PRINT_HIGH,
"===Weapons===\n");
gi.cprintf(ent, PRINT_HIGH,
"Ten weapons including the grenade have been changed to match weapons/tools from the game franchise Assassins Creed\n");
gi.cprintf(ent, PRINT_HIGH,
"To use your dagger switch weapons with / as it doesnt't have a dedicated button\n");
gi.cprintf(ent, PRINT_HIGH,
"For more detailed info on how each weapon was changed please look at the README file on my GitHub repository\n");
gi.cprintf(ent, PRINT_HIGH,
"To return to original help screen type ModHelp\n");
}

void Cmd_HelpMove_f(edict_t* ent) {
gi.cprintf(ent, PRINT_HIGH,
"===Stealth and Movement===\n");
gi.cprintf(ent, PRINT_HIGH,
"You can now avoid enemy agro by crouching or going into water\n");
gi.cprintf(ent, PRINT_HIGH,
"You also now have two new movement abilities, infinite jump and wall run\n");
gi.cprintf(ent, PRINT_HIGH,
"Infinite jump allows you to continously jump even in mid air, used to simulate climbing from Assassins Creed\n");
gi.cprintf(ent, PRINT_HIGH,
"Wall run allows you to now basically stick on move on walls, allowing for more movement options\n");
gi.cprintf(ent, PRINT_HIGH,
"To return to original help screen type ModHelp\n");
}
//End of new commands


/*
=================
Expand Down Expand Up @@ -987,6 +1032,13 @@ void ClientCommand (edict_t *ent)
Cmd_Wave_f (ent);
else if (Q_stricmp(cmd, "playerlist") == 0)
Cmd_PlayerList_f(ent);
//new commands
else if (Q_stricmp(cmd, "ModHelp") == 0)
Cmd_ModHelp_f(ent);
else if (Q_stricmp(cmd, "HelpWeapons") == 0)
Cmd_HelpWeapons_f(ent);
else if (Q_stricmp(cmd, "HelpMove") == 0)
Cmd_HelpMove_f(ent);
else // anything that doesn't match a command will be a chat
Cmd_Say_f (ent, false, true);
}
26 changes: 26 additions & 0 deletions game/g_items.c
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@ void Weapon_GrenadeLauncher (edict_t *ent);
void Weapon_Railgun (edict_t *ent);
void Weapon_BFG (edict_t *ent);

/* new stuff for the sword */
void Weapon_Sword(edict_t* ent);

gitem_armor_t jacketarmor_info = { 25, 50, .30, .00, ARMOR_JACKET};
gitem_armor_t combatarmor_info = { 50, 100, .60, .30, ARMOR_COMBAT};
gitem_armor_t bodyarmor_info = {100, 200, .80, .60, ARMOR_BODY};
Expand Down Expand Up @@ -1539,6 +1542,29 @@ always owned, never in the world
/* precache */ "sprites/s_bfg1.sp2 sprites/s_bfg2.sp2 sprites/s_bfg3.sp2 weapons/bfg__f1y.wav weapons/bfg__l1a.wav weapons/bfg__x1b.wav weapons/bfg_hum.wav"
},

/* weapon_sword*/
{
"weapon_sword",
NULL,
Use_Weapon, //How to use
NULL,
Weapon_Sword, //What the function is
"misc/w_pkup.wav",
NULL,
0,
"models/weapons/v_blast/tris.md2", //The models stuff
"w_blaster", //Icon to be used
"Sword", //Pickup name
0,
0,
NULL,
IT_WEAPON,
NULL,
0,
"weapons/blastf1a.wav misc/lasfly.wav" //The sound of the blaster
//This is precached
},

//
// AMMO ITEMS
//
Expand Down
6 changes: 6 additions & 0 deletions game/g_local.h
Original file line number Diff line number Diff line change
Expand Up @@ -1109,5 +1109,11 @@ struct edict_s
// common data blocks
moveinfo_t moveinfo;
monsterinfo_t monsterinfo;

//new for poison
float poison_time;
float poison_damage;
edict_t* poison_attacker;
float next_poison_tick;
};

16 changes: 16 additions & 0 deletions game/g_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -355,6 +355,22 @@ void G_RunFrame (void)
int i;
edict_t *ent;

//new for poison
for (ent = g_edicts + 1; ent < &g_edicts[globals.num_edicts]; ent++)
{
if (!ent->inuse) {
continue;
}
if (ent->poison_time > level.time) {
if (level.time >= ent->next_poison_tick) {
if (ent->takedamage && ent->health > 0) {
T_Damage(ent, ent->poison_attacker, ent->poison_attacker, vec3_origin, ent->s.origin, vec3_origin, ent->poison_damage, 0, 0, MOD_MACHINEGUN);
}
ent->next_poison_tick = level.time + 1.0;
}
}
}

level.framenum++;
level.time = level.framenum*FRAMETIME;

Expand Down
Loading