21.12.2011, 18:44
(
Последний раз редактировалось Domenic_Corleone; 21.12.2011 в 19:58.
)
Ok i need some help with my gamemod. im making Humans Vs. Zombies TDM
I have 12 teams 5 teams comes under survivors and other 5 comes under the infected.
Humans - Civil,Sheriff.cop,Swat,Fbi,army
Zombies - Zombie,Runner,Smoker,Hunter,Witch,Xmutant
Everything like Team colors and spawns have been added and working properly....
note:that i added more than 1 skin for each team so i used ''AddPlayerClassEx"
Now i Really need a code to make all zombie teams infect human teams .... And Not other zombie teams...
like Zombie teams like :zombie,Runner,Smoker,Hunter,Witch,Xmutant can Infect all human teams... but not other zombies teams.... the zombies should get 2 score fore one kill
for eg. something like this....
pls dont link any tutorials... there isnt any tutorial based on this... Thanks in advance !
I have 12 teams 5 teams comes under survivors and other 5 comes under the infected.
Humans - Civil,Sheriff.cop,Swat,Fbi,army
Zombies - Zombie,Runner,Smoker,Hunter,Witch,Xmutant
Код:
#define CIVIL 0 #define SHERIFF 1 #define POLICE 2 #define SWAT 3 #define FBI 4 #define ARMY 5 #define ZOMBIE 6 #define RUNNER 7 #define SMOKER 8 #define HUNTER 9 #define WITCH 10 #define XMUTANT 11 new gTeam[MAX_PLAYERS];
note:that i added more than 1 skin for each team so i used ''AddPlayerClassEx"
Now i Really need a code to make all zombie teams infect human teams .... And Not other zombie teams...
like Zombie teams like :zombie,Runner,Smoker,Hunter,Witch,Xmutant can Infect all human teams... but not other zombies teams.... the zombies should get 2 score fore one kill
for eg. something like this....
Код:
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys) { if(newkeys == KEY_FIRE) { for(new i=0;i<MAX_PLAYERS;i++) { new Float:X, Float:Y, Float:Z; GetPlayerPos(i, X, Y, Z); if(gTeam[playerid] == 0) { if(IsPlayerInRangeOfPoint(playerid, 1.0, X, Y, Z)) { if(gTeam[i] != 0) { new Float:H; GetPlayerHealth(i, H); SetPlayerHealth(i, H-10); SetPVarInt(playerid, "Infected", 1); if(GetPVarInt(playerid,"Infected") == 0) { GameTextForPlayer(i, "~r~Infected!", 500, 3); } } } } } } return 1; }