15.02.2011, 17:28
As soon as i connect the server.exe just closes, i checked the logs just says Player Joined the server and thats it.What is this?
public OnGameModeInit()
{
mysql_init();
if(!mysql_connect("localhost", "rayyan","k","rayyan_westside"))
{
print("\n MySQL Connection Failed, Now on Offline Mode\n");
Offline = 1;
}
else
{
Offline = 0;
}
SetTimer("ServerUpdate",120000, true);
SetGameModeText("WS-RPG2");
for(new i = 0; i < MAX_PLAYERS; i++)
{
BankTimer = SetTimerEx("BankCheck", 1000, true, "i", i);
timetimer = SetTimerEx("TimeUpdate", 60000, true, "i", i);
//SetTimer("LoadCars", 2500, false);
//SetTimerEx("IsAtGasStation",2000,1,"i",i);
}
for(new i=0;i<MAX_VEHICLES;i++) {
fuel[i] = 100; //sets every car's fuel to 100 in a loop
}
SetTimer("timer_fuel_lower",4200,true); //sets the timer to drop the fuel
print("[ ! ] Fuel Bar Loaded");
LimitGlobalChatRadius(30);
SetWorldTime(5);
ghour = 5;
gminute = 0;
gsecond = 1;
public OnPlayerConnect(playerid)
{
if(Offline == 1)
{
OfflineLogin(playerid);
return 0;
}