problem with C4
#7

is the problem with this?

Код:
		if(BombID[playerid] != 0)
		{
		    if(GetPlayerWeapon(playerid) == 0)
		    {
		        if(!IsPlayerInAnyVehicle(playerid))
		        {
			        ClearAnimations(playerid);
			        ApplyAnimation(playerid,"PED","bomber",4.0,0,0,0,0,0);
		        }
		    	new Float:X,Float:Y,Float:Z;
				GetObjectPos(BombID[playerid],X,Y,Z);
				DestroyDynamicObject(BombID[playerid]);
				CreateExplosion(X,Y,Z,12,1);
				BombID[playerid] = 0;
				SetPlayerWeapons(playerid);
				new killerid = GoChase[playerid];
                if(IsPlayerInRangeOfPoint(killerid,3,X,Y,Z))
                {
                    if(GoChase[playerid] == killerid)
                    {
                        if(PlayerInfo[killerid][pHeadValue] > 0)
                        {
	                    	new price = PlayerInfo[killerid][pHeadValue];
	                    	new name[MAX_PLAYER_NAME];
							new killa[MAX_PLAYER_NAME];
	                    	GetPlayerName(playerid, name, sizeof(name));
							GetPlayerName(killerid, killa, sizeof(killa));
							PlayerInfo[killerid][pCash] = PlayerInfo[killerid][pCash]-price/2;
							GivePlayerMoney(killerid, -price/2);
	                		PlayerInfo[playerid][pCash] = PlayerInfo[playerid][pCash]+price/2;
							GivePlayerMoney(playerid, price/2);
	                    	format(string,128,"Hitman %s has fulfilled the contract on %s and collected $%d.",name,killa,price/2);
							SendFamilyMessage(8, COLOR_YELLOW, string);
							format(string,128,"You have been critically injured by a hitman and lost $%d.",price/2);
							SendClientMessage(killerid, COLOR_YELLOW, string);
							SetPlayerHealth(killerid, 0);
	                        ClearContract(killerid);
	                        GoChase[playerid] = 999;
	                        PlayerInfo[playerid][pCHits]++;
						}
					}
                }
			}
		}
	}
Reply


Messages In This Thread
problem with C4 - by Antoniohl - 03.01.2014, 16:23
Re: problem with C4 - by Yashas - 03.01.2014, 16:27
Re: problem with C4 - by newbienoob - 03.01.2014, 16:30
Re: problem with C4 - by Antoniohl - 03.01.2014, 16:36
Re: problem with C4 - by Antoniohl - 03.01.2014, 16:54
Re: problem with C4 - by [EnErGyS]KING - 03.01.2014, 17:17
Re: problem with C4 - by Antoniohl - 03.01.2014, 19:28
Re: problem with C4 - by Antoniohl - 04.01.2014, 00:05
Re: problem with C4 - by Seif- - 04.01.2014, 13:39

Forum Jump:


Users browsing this thread: 3 Guest(s)