diff --git a/source/src/client.cpp b/source/src/client.cpp index e70bbeed..90f625b7 100644 --- a/source/src/client.cpp +++ b/source/src/client.cpp @@ -334,4 +334,4 @@ void lsinfo() { printf("%s\t%i\n", players[i]->name, players[i]->lifesequence); } -} +}; COMMAND(lsinfo, ARG_NONE); diff --git a/source/src/clientgame.cpp b/source/src/clientgame.cpp index 2a61035c..3a3d3d2f 100644 --- a/source/src/clientgame.cpp +++ b/source/src/clientgame.cpp @@ -413,7 +413,7 @@ void mousemove(int dx, int dy) // damage arriving from the network, monsters, yourself, all ends up here. void selfdamage(int damage, int actor, dynent *act) -{ +{ printf("selfdmg\n"); if(player1->state!=CS_ALIVE || editmode || intermission) return; damageblend(damage); demoblend(damage); @@ -451,7 +451,7 @@ void selfdamage(int damage, int actor, dynent *act) }; }; // EDIT: AH - if(m_teammode) ctf_death(); + if(m_ctf) ctf_death(); showscores(true); addmsg(1, 2, SV_DIED, actor); player1->lifesequence++; @@ -531,8 +531,8 @@ void preparectf(bool cleanonly=false) void startmap(char *name) // called just after a map load { - if(netmapstart()) { gamemode = 0;}; //needs fixed to switch modes? - //netmapstart(); //should work + //if(netmapstart()) { gamemode = 0;}; //needs fixed to switch modes? + netmapstart(); //should work sleepwait = 0; //put call to clear/restart game mode extras here projreset(); @@ -567,7 +567,6 @@ void suicide() //particle_splash(3, 1000, 1000, player1->o); //edit out? demodamage(1000, player1->o); playsound(S_SUICIDE, &player1->o); - }; COMMAND(suicide, ARG_NONE); diff --git a/source/src/clients2c.cpp b/source/src/clients2c.cpp index be044881..06b8e8e8 100644 --- a/source/src/clients2c.cpp +++ b/source/src/clients2c.cpp @@ -190,7 +190,6 @@ void localservertoclient(uchar *buf, int len) // processes any updates from th if(gun==GUN_SHOTGUN) createrays(s, e); int nademillis = 2000/100*getint(p); if(nademillis<0 || nademillis>100) nademillis = 100; - printf("nadesec: %i\n", nademillis); shootv(gun, s, e, d, nademillis); break; }; @@ -200,7 +199,7 @@ void localservertoclient(uchar *buf, int len) // processes any updates from th int target = getint(p); int damage = getint(p); int ls = getint(p); - if(target==clientnum) { if(ls==player1->lifesequence) selfdamage(damage, cn, d); } + if(target==clientnum) { if(ls==player1->lifesequence) selfdamage(damage, cn, d); else printf("wrong lifesequence\n"); } else playsound(S_PAIN1+rnd(5), &getclient(target)->o); break; }; diff --git a/source/src/physics.cpp b/source/src/physics.cpp index 0042b536..f4088252 100644 --- a/source/src/physics.cpp +++ b/source/src/physics.cpp @@ -178,7 +178,7 @@ void physicsframe() // optimally schedule physics frames inside the gra }; }; -void selfdamage(dynent * d, int dm) +void selfdamage(dynent *d, int dm) { if(d==player1) selfdamage(dm, -1, d); else { addmsg(1, 4, SV_DAMAGE, d, dm, d->lifesequence); playsound(S_FALL1+rnd(5), &d->o); }; diff --git a/source/src/rendermd3.cpp b/source/src/rendermd3.cpp index 79d250dc..9105f749 100644 --- a/source/src/rendermd3.cpp +++ b/source/src/rendermd3.cpp @@ -434,7 +434,7 @@ struct weaponmove bool throwingnade = player1->gunselect==GUN_GRENADE && player1->thrownademillis; int timediff = throwingnade ? (lastmillis-player1->thrownademillis) : lastmillis-basetime; int animtime = attackdelay(player1->gunselect); - int rtime = reloadtime(player1->gunselect); + int rtime = reloadtime(player1->gunselect); kick = k_rot = 0.0f; pos = player1->o; anim = MDL_GUN_IDLE; diff --git a/source/src/server.cpp b/source/src/server.cpp index e612df84..c9129c8b 100644 --- a/source/src/server.cpp +++ b/source/src/server.cpp @@ -337,7 +337,7 @@ void process(ENetPacket * packet, int sender) // sender may be -1 sgetstr(); strcpy_s(clients[cn].name, text); sgetstr(); - getint(p); + getint(p); getint(p); break; @@ -349,7 +349,7 @@ void process(ENetPacket * packet, int sender) // sender may be -1 if(smapname[0] && !mapreload && !vote(text, reqmode, sender)) return; mapreload = false; mode = reqmode; - minremain = mode&1 ? 15 : 10; + minremain = m_ctf_s ? 10 : (mode&1 ? 15 : 10); mapend = lastsec+minremain*60; interm = 0; strcpy_s(smapname, text); diff --git a/source/src/weapon.cpp b/source/src/weapon.cpp index 4d7aa2bf..0db6ff43 100644 --- a/source/src/weapon.cpp +++ b/source/src/weapon.cpp @@ -187,7 +187,7 @@ void hit(int target, int damage, dynent *d, dynent *at) if(d==player1) selfdamage(damage, at==player1 ? -1 : -2, at); else { addmsg(1, 4, SV_DAMAGE, target, damage, d->lifesequence); playsound(S_PAIN1+rnd(5), &d->o); }; particle_splash(3, damage, 1000, d->o); - demodamage(damage, d->o); + demodamage(damage, d->o); }; const float RL_RADIUS = 7;