23.07.2016, 13:39
#include <a_samp>
#define NPCInfo
#define GetNPCID
//============================================//
//=====[ ACC USAGE SECTION ]=====//
//============================================//
forward OnPlayerRequestClass(playerid, classid);
public OnPlayerRequestClass(playerid, classid)
{
SetPVarInt(playerid, "BeingBanned", 0);
if(IsPlayerNPC(playerid))
{
new i = -1;
i = GetNPCID(playerid);
if(i != -1);
}
{
NPCInfo[i] = 1;
SetSpawnInfo(playerid, %d, NPCInfo[i][nModel], NPCInfo[i][n_X], NPCInfo[i][n_Y], NPCInfo[i][n_Z], NPCInfo[i][n_A], -1,-1,-1,-1,-1,-1);
SetPlayerFacingAngle(playerid, NPCInfo[i][n_A]);
SetPlayerInterior(playerid, NPCInfo[i][nInt]);
SetPlayerVirtualWorld(playerid, NPCInfo[i][nWorld]);
//=====//
switch(NPCInfo[i][nType]);
{
case NPC_TYPE_BUS_1: {
PutPlayerInVehicle(playerid, BotBus, 0);
}
case NPC_TYPE_BUS_2: {
PutPlayerInVehicle(playerid, BotBus2, 0);
}
case NPC_TYPE_TRAIN: {
PutPlayerInVehicle(playerid, BotTrain, 0);
}
}
}
}
else
{
SpawnPlayer(playerid);
if(GetPVarInt(playerid, "PlayerLogged") == 1) return SpawnPlayer(playerid);
ClearChatbox(playerid, 50);
CheckIfBanned(playerid);
//==============================//
TogglePlayerSpectating(playerid, 1);
//==============================//
TextDrawShowForPlayer(playerid, SideBar1);
TextDrawShowForPlayer(playerid, SideBar2);
//==============================//
CheckAccount(playerid, 1);
//==============================//
SetTimerEx("LoginCamera", 500, false, "i", playerid);
//==============================//
}
return 1;
}
ERRORS :
C:\Users\roni\Desktop\LSSRP\gamemodes\AccountSetup .pwn(15) : error 036: empty statement
C:\Users\roni\Desktop\LSSRP\gamemodes\AccountSetup .pwn(17) : warning 217: loose indentation
C:\Users\roni\Desktop\LSSRP\gamemodes\AccountSetup .pwn(1 : error 029: invalid expression, assumed zero
C:\Users\roni\Desktop\LSSRP\gamemodes\AccountSetup .pwn(1 : error 017: undefined symbol "i"
C:\Users\roni\Desktop\LSSRP\gamemodes\AccountSetup .pwn(1 : error 029: invalid expression, assumed zero
C:\Users\roni\Desktop\LSSRP\gamemodes\AccountSetup .pwn(1 : fatal error 107: too many error messages on one line
#define NPCInfo
#define GetNPCID
//============================================//
//=====[ ACC USAGE SECTION ]=====//
//============================================//
forward OnPlayerRequestClass(playerid, classid);
public OnPlayerRequestClass(playerid, classid)
{
SetPVarInt(playerid, "BeingBanned", 0);
if(IsPlayerNPC(playerid))
{
new i = -1;
i = GetNPCID(playerid);
if(i != -1);
}
{
NPCInfo[i] = 1;
SetSpawnInfo(playerid, %d, NPCInfo[i][nModel], NPCInfo[i][n_X], NPCInfo[i][n_Y], NPCInfo[i][n_Z], NPCInfo[i][n_A], -1,-1,-1,-1,-1,-1);
SetPlayerFacingAngle(playerid, NPCInfo[i][n_A]);
SetPlayerInterior(playerid, NPCInfo[i][nInt]);
SetPlayerVirtualWorld(playerid, NPCInfo[i][nWorld]);
//=====//
switch(NPCInfo[i][nType]);
{
case NPC_TYPE_BUS_1: {
PutPlayerInVehicle(playerid, BotBus, 0);
}
case NPC_TYPE_BUS_2: {
PutPlayerInVehicle(playerid, BotBus2, 0);
}
case NPC_TYPE_TRAIN: {
PutPlayerInVehicle(playerid, BotTrain, 0);
}
}
}
}
else
{
SpawnPlayer(playerid);
if(GetPVarInt(playerid, "PlayerLogged") == 1) return SpawnPlayer(playerid);
ClearChatbox(playerid, 50);
CheckIfBanned(playerid);
//==============================//
TogglePlayerSpectating(playerid, 1);
//==============================//
TextDrawShowForPlayer(playerid, SideBar1);
TextDrawShowForPlayer(playerid, SideBar2);
//==============================//
CheckAccount(playerid, 1);
//==============================//
SetTimerEx("LoginCamera", 500, false, "i", playerid);
//==============================//
}
return 1;
}
ERRORS :
C:\Users\roni\Desktop\LSSRP\gamemodes\AccountSetup .pwn(15) : error 036: empty statement
C:\Users\roni\Desktop\LSSRP\gamemodes\AccountSetup .pwn(17) : warning 217: loose indentation
C:\Users\roni\Desktop\LSSRP\gamemodes\AccountSetup .pwn(1 : error 029: invalid expression, assumed zero
C:\Users\roni\Desktop\LSSRP\gamemodes\AccountSetup .pwn(1 : error 017: undefined symbol "i"
C:\Users\roni\Desktop\LSSRP\gamemodes\AccountSetup .pwn(1 : error 029: invalid expression, assumed zero
C:\Users\roni\Desktop\LSSRP\gamemodes\AccountSetup .pwn(1 : fatal error 107: too many error messages on one line