createpump crashes my game random reason?
#1

everytime i do createpump it crashes my game with op codes.

Код:
CMD:createpump(playerid, params[])
{
	static id, bizid = -1;
    if (PlayerData[playerid][pAdmin] < 5)
	    return SendErrorMessage(playerid, "You don't have permission to use this command.");

	if (sscanf(params, "d", bizid))
	    return SendSyntaxMessage(playerid, "/createpump [business id]");

	if ((bizid < 0 || bizid >= MAX_BUSINESSES) || !BusinessData[bizid][bizExists])
	    return SendErrorMessage(playerid, "You have specified an invalid business ID.");

	if (BusinessData[bizid][bizType] != 6)
	    return SendErrorMessage(playerid, "This business is not a gas station!");

    if (GetPlayerInterior(playerid) > 0 || GetPlayerVirtualWorld(playerid) > 0)
		return SendErrorMessage(playerid, "You can only create gas pumps outside interiors.");

	id = Pump_Create(playerid, bizid);

	if (id == -1)
	    return SendErrorMessage(playerid, "The business has reached the limit for gas pumps.");

	SendServerMessage(playerid, "You have successfully created gas pump ID: %d.", id);
	EditDynamicObject(playerid, PumpData[id][pumpObject]);
	PlayerData[playerid][pEditPump] = id;
	return 1;
}
Reply
#2

Stop asking for help regarding the South Central script directly. Ask in that thread. No need to make it's own thread.
Reply
#3

Quote:
Originally Posted by Abagail
Посмотреть сообщение
Stop asking for help regarding the South Central script directly. Ask in that thread. No need to make it's own thread.
if you don't like it don't comment simple as the thread itself is called (scripting help) if i need help with something i will post here not on the gamemode release.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)