*** empty log message ***

git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@600 e016b1c5-ed68-44aa-a2f7-31cac88cffde
This commit is contained in:
Lee Salzman
2006-11-11 23:46:54 +00:00
parent 605507f236
commit 21b950e479
3 changed files with 10 additions and 8 deletions
-5
View File
@@ -396,23 +396,19 @@ void parsemessages(int cn, playerent *d, ucharbuf &p)
// EDIT: AH
case SV_FLAGINFO:
{
conoutf("received server flag answer 1"); //fixme
int flag = getint(p);
if(flag<0||flag>1) return;
flaginfo &f = flaginfos[flag];
f.state = getint(p);
int action = getint(p);
conoutf("received server flag answer 2");
if(f.state==CTFF_STOLEN)
{
conoutf("flag stolen"); //fixme
int actor_cn = getint(p);
f.actor = actor_cn == getclientnum() ? player1 : getclient(actor_cn);
f.flag->spawned = false;
}
else if(f.state==CTFF_DROPPED)
{
conoutf("flag dropped"); //fixme
f.flag->x = (ushort) (getint(p)/DMF);
f.flag->y = (ushort) (getint(p)/DMF);
f.flag->z = (ushort) (getint(p)/DMF);
@@ -429,7 +425,6 @@ void parsemessages(int cn, playerent *d, ucharbuf &p)
}
else if(f.state==CTFF_INBASE)
{
conoutf("flag in base"); //fixme
if(action==SV_FLAGRETURN)
{
int returnerer_cn = getint(p);
-1
View File
@@ -203,7 +203,6 @@ void pickup(int n, playerent *d)
}
else if(!isownflag)
{
conoutf("asking the server for pickup ACK"); //fixme
addmsg(SV_FLAGPICKUP, "ri", team);
ents[n].spawned = false;
f.actor = player1; // do this although we don't know if we picked the flag to avoid getting it after a possible respawn
+10 -2
View File
@@ -684,10 +684,18 @@ void process(ENetPacket *packet, int sender, int chan) // sender may be -1
};
case SV_RECVMAP:
{
SENDER_CHECK;
sendpacket(sender, 3, recvmap(sender));
ENetPacket *mappacket = recvmap(sender);
if(mappacket)
{
sendpacket(sender, 3, mappacket);
if(!mappacket->referenceCount) enet_packet_destroy(mappacket);
}
else sendservmsg("no map to get", sender);
break;
};
// EDIT: AH
case SV_FLAGPICKUP:
{