Posts: 596
Threads: 75
Joined: Nov 2015
Quote:
Originally Posted by Sjn
When you create a player array, you cannot use () to wrap the playerid.
You need to do
Код:
if (Instafix[playerid] == true/false)
Also, you must assign true or false before checking for either one of it's state.
|
Pawn will detect "if(Instafix[playerid])" as
true
And "if(!Instafix[playerid])" as
false
No need to add extra info there.
Quote:
Originally Posted by Sjn
Obviously...
|
Nop,he can use other editors too.
Код:
if (Instafix[playerid])
{
RepairVehicle(GetPlayerVehicleID(playerid));
return 1;
}
Posts: 57
Threads: 26
Joined: Jul 2016
Reputation:
0
D:\SampSever\iPLEOMAX's TextDraw Editor\SAMP 0.3e Server\gamemodes\Untitled.pwn(159) : error 001: expected token: ";", but found "]"
Posts: 596
Threads: 75
Joined: Nov 2015
Quote:
Originally Posted by Maheerali
D:\SampSever\iPLEOMAX's TextDraw Editor\SAMP 0.3e Server\gamemodes\Untitled.pwn(159) : error 001: expected token: ";", but found "]"
|
Show some previous lines
Posts: 57
Threads: 26
Joined: Jul 2016
Reputation:
0
CMD:armor(playerid, params[])
{
SetPlayerArmour(playerid, 100.00);
return 1;
}
CMD:fix(playerid, params[])
{
if (Instafix[playerid] == true)
{
RepairVehicle(GetPlayerVehicleID(playerid));
}
return 1;
}
Posts: 596
Threads: 75
Joined: Nov 2015
Код:
CMD:armor(playerid, params[])
{
SetPlayerArmour(playerid, 100.00);
return 1;
}
CMD:fix(playerid, params[])
{
if (Instafix[playerid] == true)
{
RepairVehicle(GetPlayerVehicleID(playerid));
return 1;
}
Posts: 1,939
Threads: 11
Joined: Oct 2015
Reputation:
0
brace is missing @ the end of 2nd cmd