[FilterScript] Turf Wars v1.0 (GTA Online)
#5

Quote:
Originally Posted by Scripter18
View Post
TIP: Few improvements!

:- Line 43 till 49

Code:
new TurfInfo[Turf];
new TurfStarted=0;
new turftimer;
new turfvehicles;
new Points[4];
new TurfVehicle[MAX_PLAYERS];
new Text:TurfRes[8];
- Also could be optimized as

Code:
new TurfInfo[Turf], TurfStarted = 0,  turftimer, turfvehicles,  Points[4], Text:TurfRes[8],  TurfVehicle[MAX_PLAYERS];
- You should use "GetPlayerPoolSize" for looping, it get's the highest userid that's playing!



Code:
CMD:turfhelp(playerid,params[])
{
    new info[700];
    if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid,-1,""RED"ERROR | "GRAY"You need to be Rcon!");
    strcat(info, ""RED"Turf Help\n\n", sizeof(info));
    strcat(info, "Create/Edit objects\n", sizeof(info));
    strcat(info, ""GRAY"/createobject-Spawn object which can be edited\n", sizeof(info));
    strcat(info, " /removeobject-Remove object with that ID\n", sizeof(info));
    strcat(info, " /eobject-Edit position of object\n", sizeof(info));
    strcat(info, " /duplicateobject-Duplicate object with that ID\n", sizeof(info));
    strcat(info, " /turfspawn-Set spawn location for 4 teams\n", sizeof(info));
    strcat(info, " /portobject-Port to location of object\n", sizeof(info));
    strcat(info, ""RED"Start/Stop Turf Wars\n", sizeof(info));
    strcat(info, ""GRAY"/turfinvite-Invite players in 1 of 4 teams\n", sizeof(info));
    strcat(info, "/turfstart-Start Turf Wars\n", sizeof(info));
    strcat(info, "/turfstop-Stop Turf Wars\n", sizeof(info));
    ShowPlayerDialog(playerid, 31999, DIALOG_STYLE_MSGBOX, "Turf Wars Help", info, "Ok", "");
    return 1;
}
- Move to SQL/MYSQL & EasyDialog
how the hell is that optmised? reducing number of lines is not optmising.if you got some valid points regarding optimising tell it not such a bull shit.
Reply


Messages In This Thread
Turf Wars v1.0 (GTA Online) - by TonyVk - 16.03.2017, 23:53
Re: Turf Wars v1.0 (GTA Online) - by Sebz - 17.03.2017, 02:28
Re: Turf Wars v1.0 (GTA Online) - by TonyVk - 17.03.2017, 10:05
Re: Turf Wars v1.0 (GTA Online) - by Bolex_ - 17.03.2017, 10:07
Re: Turf Wars v1.0 (GTA Online) - by SyS - 17.03.2017, 10:10
Re: Turf Wars v1.0 (GTA Online) - by Bolex_ - 17.03.2017, 10:13
Re: Turf Wars v1.0 (GTA Online) - by SyS - 17.03.2017, 10:15
Re: Turf Wars v1.0 (GTA Online) - by TonyVk - 17.03.2017, 11:07

Forum Jump:


Users browsing this thread: 1 Guest(s)