21.07.2015, 21:42
Testa ae
PHP код:
public OnGameModeInit()
{
SetTimer("info", 1000, 1);
return 1;
}
PHP код:
public OnPlayerConnect(playerid)
{
INFO[2][playerid] = CreatePlayerTextDraw(playerid,145.000000,347.000000,"_");
PlayerTextDrawUseBox(playerid, INFO[2][playerid],1);
PlayerTextDrawBoxColor(playerid, INFO[2][playerid],0x00000066);
PlayerTextDrawTextSize(playerid, INFO[2][playerid],196.000000,14.000000);
PlayerTextDrawAlignment(playerid, INFO[2][playerid],0);
PlayerTextDrawBackgroundColor(playerid, INFO[2][playerid],0xffffffff);
PlayerTextDrawFont(playerid, INFO[2][playerid],2);
PlayerTextDrawLetterSize(playerid, INFO[2][playerid],0.199999,1.400000);
PlayerTextDrawColor(playerid, INFO[2][playerid],0xffffffff);
PlayerTextDrawSetProportional(playerid, INFO[2][playerid],1);
PlayerTextDrawSetShadow(playerid, INFO[2][playerid],0);
return 1;
}
PHP код:
public OnPlayerSpawn(playerid)
{
PlayerTextDrawShow(playerid, PlayerText:INFO[2][playerid]);
return 1;
}
PHP код:
forward info(playerid);
public info(playerid)
{
new STR[128];
format(STR, sizeof(STR), "~b~Matou: ~w~%d",DOF2::GetInt(String, "Matou"));
PlayerTextDrawSetString(playerid, INFO[2][playerid], STR);
return 1;
}