06.08.2017, 07:59
when enter deathmatch the Interior is blank and then the player money
Ascending slightly when enter the room.
the dialog
the command
another question,how make limit of room example if the maximum of room is 5 and other player cant go in
Ascending slightly when enter the room.
PHP код:
public OnPlayerSpawn(PID)
PHP код:
if(InDM[PID] == true)
{
switch (DM[PID])
{
case 0: shamal
{
GivePlayerWeapon(PID, 24, 1000);
SetPlayerHealth(PID, 99);
SetPlayerArmour(PID, 99);
new spawn = random(sizeof(DMZeroSpawns));
SetPlayerPos(PID, DMZeroSpawns[spawn][0], DMZeroSpawns[spawn][1], DMZeroSpawns[spawn][2]);
SetPlayerFacingAngle(PID, DMZeroSpawns[spawn][3]); //>> SetPlayerInterior
SetPlayerVirtualWorld(PID, 1);
SetPlayerInterior(playerid, 17);
SetPlayerHealth(PID, 99);
}
}
}
PHP код:
public OnPlayerDeath(PID, killerid, reason)
PHP код:
if(InDM[PID] == true)
{
if(anakko[PID] == 1)
{
anakko[PID] = 0;
if(makko[PID] != INVALID_PLAYER_ID)
TogglePlayerSpectating(PID, 1);
PlayerSpectatePlayer(PID, killerid);
SendClientMessage(PID, SKYBLUE , "You have been killed, you are now spectating your killer.");
SetTimerEx("EndDeathCam", 10000, false, "i", playerid);
}
else
{
TogglePlayerSpectating(PID, 0);
killstreak(PID, killerid);
DestroyDynamic3DTextLabel(wanted[killerid]);
return 1;
}
}
PHP код:
Dialog:RandomDM(PID, response, listitem, inputtext[])
{
new string[128], playerName[MAX_PLAYER_NAME];
GetPlayerName(PID, playerName, sizeof(playerName));
if (response)
{
switch(listitem) // Check which option was chosen when they responded. We only have one for now. The next would be case 1, then case 2 and so on.
{
case 0:
{
InDM[PID] = true;
DM[PID] = 0;
SpawnPlayer(PID);
PlayerTextDrawHide(PID,Textdraw0);
PlayerTextDrawHide(PID,Textdraw1);
PlayerTextDrawHide(PID,Textdraw2);
PlayerTextDrawHide(PID,Textdraw3);
SetPlayerInterior(playerid, 17);
SetPlayerVirtualWorld(PID, 1);
}
}
format(string, sizeof(string), "{77B3D9}[DM Zones] {ffffff}%s(%i) has just entered {77B3D9}DM zone %i {ffffff}(/dm)", playerName, PID, DM[PID]);
scms(-1, string);
return 1; // ?? One you missed
}
return 0;
}
PHP код:
CMD:dmlist(PID, params[])
{
Dialog_Show(PID, RandomDM, DIALOG_STYLE_LIST, "DM Zones", "DM 0 - Shamal", "Enter", "Cancel");
return 1;
}