14.10.2012, 02:50
The Rcon Control Panel version of RomAdmin would be release this month.
But in different thread.
But in different thread.
if(fexist(Path(playerid)))
{
if(ServerInfo[AutoLog] == 1)
{
if((!strcmp(ip, PlayerAcc[playerid][Ip], true)) && (ServerInfo[AutoLog] == 1))
{
INI_ParseFile(Path(playerid),"loadaccount_user", .bExtra = true, .extra = playerid);
if(ServerInfo[ScoreSaving] == 1)
{
SetPlayerScore(playerid, PlayerAcc[playerid][Score]);
}
GivePlayerMoney(playerid, PlayerAcc[playerid][Money]);
SendClientMessage(playerid, COLOR_YELLOW, "Success: You've automatically successfully login to your account");
PlayerAcc[playerid][Log] = 1;
return 1;
}
}
ShowPlayerDialog(playerid, LOGIN, DIALOG_STYLE_PASSWORD, ""white"RomAdmin - Login", "Welcome Back,\nPlease login first by\nPutting your password below", "Login", "Exit");
}
else
{
ShowPlayerDialog(playerid, REGISTER, DIALOG_STYLE_PASSWORD, ""white"RomAdmin - Register", "Welcome to the Server,\nPlease register first by\nPutting your password below", "Register", "Exit");
}
new bool:HasIt[MAX_PLAYERS];
public OnPlayerConnect(playerid)
{
HasIt[playerid] = false;
return 1;
}
public OnPlayerDisconnect(playerid, reason)
{
HasIt[playerid] = false;
return 1;
}
public OnPlayerSpawn(playerid)
{
if(HasIt[playerid] == false)
{
HasIt[playerid] = true;
if(fexist(Path(playerid)))
{
if(ServerInfo[AutoLog] == 1)
{
if((!strcmp(ip, PlayerAcc[playerid][Ip], true)) && (ServerInfo[AutoLog] == 1))
{
INI_ParseFile(Path(playerid),"loadaccount_user", .bExtra = true, .extra = playerid);
if(ServerInfo[ScoreSaving] == 1)
{
SetPlayerScore(playerid, PlayerAcc[playerid][Score]);
}
GivePlayerMoney(playerid, PlayerAcc[playerid][Money]);
SendClientMessage(playerid, COLOR_YELLOW, "Success: You've automatically successfully login to your account");
PlayerAcc[playerid][Log] = 1;
return 1;
}
}
ShowPlayerDialog(playerid, LOGIN, DIALOG_STYLE_PASSWORD, ""white"RomAdmin - Login", "Welcome Back,\nPlease login first by\nPutting your password below", "Login", "Exit");
}
else
{
ShowPlayerDialog(playerid, REGISTER, DIALOG_STYLE_PASSWORD, ""white"RomAdmin - Register", "Welcome to the Server,\nPlease register first by\nPutting your password below", "Register", "Exit");
}
}
return 1;
}
|
Code:
public OnPlayerSpawn(playerid)
{
#if VipTag == true
if(PlayerAcc[playerid][Vip] >= 1)
{
new Text3D:VIPtag = Create3DTextLabel("VIP", COLOR_ORANGE, 30.0, 40.0, 50.0, 40.0, 0);
Attach3DTextLabelToPlayer(VIPtag, playerid, 0.0, 0.0, 0.7);
SetPlayerColor(playerid, COLOR_ORANGE);
}
#endif
if(PlayerAcc[playerid][UseSkin] == 1)
{
SetPlayerSkin(playerid, PlayerAcc[playerid][SaveSkin]);
SendClientMessage(playerid, COLOR_LIME, "Saved Skin successfully loaded!");
SendClientMessage(playerid, COLOR_RED, "RomAdmin: /dontuseskin to disable using your save skin!");
}
if(IsSpecing[playerid] == 1)
{
SetPlayerPos(playerid, SpecX[playerid], SpecY[playerid], SpecZ[playerid]);
SetPlayerInterior(playerid, Inter[playerid]);
SetPlayerVirtualWorld(playerid, vWorld[playerid]);
IsSpecing[playerid] = 0;
IsBeingSpeced[spectatorid[playerid]] = 0;
}
if(PlayerAcc[playerid][Jail] == 1)
{
ResetPlayerWeapons(playerid);
SetPlayerPos(playerid, 197.6661,173.8179,1003.0234);
SetPlayerInterior(playerid, 3);
SendClientMessage(playerid, COLOR_RED, "You've been bought back to jail, You've not finish your punishment yet!");
}
if(PlayerAcc[playerid][Mute] == 1)
{
MuteTimer[playerid] = SetTimerEx("OnPlayerUnmute", PlayerAcc[playerid][MuteTime], false, "d", playerid);
SendClientMessage(playerid, COLOR_RED, "You've been muted, You've not finish your punishment");
}
if(HasIt[playerid] == false)
{
HasIt[playerid] = true;
if(fexist(Path(playerid)))
{
if(ServerInfo[AutoLog] == 1)
{
if((!strcmp(ip, PlayerAcc[playerid][Ip], true)) && (ServerInfo[AutoLog] == 1))
{
INI_ParseFile(Path(playerid),"loadaccount_user", .bExtra = true, .extra = playerid);
if(ServerInfo[ScoreSaving] == 1)
{
SetPlayerScore(playerid, PlayerAcc[playerid][Score]);
}
GivePlayerMoney(playerid, PlayerAcc[playerid][Money]);
SendClientMessage(playerid, COLOR_YELLOW, "Success: You've automatically successfully login to your account");
PlayerAcc[playerid][Log] = 1;
return 1;
}
}
ShowPlayerDialog(playerid, LOGIN, DIALOG_STYLE_PASSWORD, ""white"RomAdmin - Login", "Welcome Back,\nPlease login first by\nPutting your password below", "Login", "Exit");
}
else
{
ShowPlayerDialog(playerid, REGISTER, DIALOG_STYLE_PASSWORD, ""white"RomAdmin - Register", "Welcome to the Server,\nPlease register first by\nPutting your password below", "Register", "Exit");
}
}
return 1;
}
|
|
C:\Users\sofie's\Desktop\SKCNRV3\filterscripts\Rom Admin.pwn(1173) : warning 204: symbol is assigned a value that is never used: "str2"
C:\Users\sofie's\Desktop\SKCNRV3\filterscripts\Rom Admin.pwn(1390) : error 017: undefined symbol "ip" C:\Users\sofie's\Desktop\SKCNRV3\filterscripts\Rom Admin.pwn(6140) : warning 203: symbol is never used: "Forbidden" C:\Users\sofie's\Desktop\SKCNRV3\filterscripts\Rom Admin.pwn(6140) : warning 203: symbol is never used: "Name" C:\Users\sofie's\Desktop\SKCNRV3\filterscripts\Rom Admin.pwn(6140) : warning 203: symbol is never used: "botIDs" Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 1 Error. the error comes from this line : if((!strcmp(ip, PlayerAcc[playerid][Ip], true)) && (ServerInfo[AutoLog] == 1)) |
new ip[16];
new ip[16];
GetPlayerIp(playerid, ip, sizeof(ip));
new ip[16];
|
It works, thank you the command works but a "Invalid command..blablalblab" text appears (i think it conflicts my gamemode)
|