Works on windows, issues on Linux?
#1

Hey there,

My script which is pretty basic(only 700 lines or so) runs perfectly on Windows but in Linux it connects fine, but when you spawn the whole server crashes. In the log there is no record of this it just says Incoming Connection and then that's the last line in the log before the server restarts itself. I believe the issue to be within OnPlayerSpawn, but I could be wrong.

Here's the code:
Код:
public OnPlayerSpawn(playerid)
{
  SetPlayerInterior(playerid, 0);
  GangZoneShowForPlayer(playerid, PD, 0xFFFF0096);
  GangZoneShowForPlayer(playerid, GANG, 0x00000096);
  	PICKUPGUN = CreatePickup(361, 23,	1294.2100,2797.0854,10.8220); //Flamethrower in the centre
 	PICKUPHEALTH2 = CreatePickup(1240, 23,	1186.7932,2757.8452,10.8281); //Health for team 1
 	PICKUPHEALTH1 = CreatePickup(1240, 23,	1354.1555,2781.8418,10.8203); //Health for team 2
  SetPlayerArmour(playerid, 100.0);
  	new s[120];
  format(s,10,"Team 2: %d",greenscore);
  TextDrawSetString(ScoreGreen,s);
  format(s,20,"Team 1: %d",redscore);
  TextDrawSetString(ScoreRed,s);
  //////////////////////////////////
  if(gTeam[playerid] == TEAM_GANG) {
	SetPlayerColor(playerid,COLOR_GREEN); //
	DisablePlayerCheckpoint(playerid);
	PICKUPP = CreatePickup(1210, 23, 1378.8456,2752.9397,10.2196); //FLAG
	PICKUPA = CreatePickup(1210, 23, 1141.4272,2741.7739,10.8197); //FLAG2
	GameTextForPlayer(playerid, "Capture the enemies flag and return it to our base", 6000, 0);
  playerarmy[playerid]=0;
  playerpolice[playerid]=0;
	SetPlayerCheckpoint(playerid,1378.8456,2752.9397,10.2196);
  //TextDrawHideForPlayer(playerid,Textdraw0);
  }
  if(gTeam[playerid] == TEAM_GANG2) {
	SetPlayerColor(playerid,COLOR_BLUE); //
	DisablePlayerCheckpoint(playerid);
	PICKUPP = CreatePickup(1210, 23, 1378.8456,2752.9397,10.2196); //FLAG
	PICKUPA = CreatePickup(1210, 23, 1141.4272,2741.7739,10.8197); //FLAG2
	GameTextForPlayer(playerid, "Capture the enemies flag and return it to our base", 6000, 0);
  playerarmy[playerid]=0;
  playerpolice[playerid]=0;
  SetPlayerCheckpoint(playerid,1141.4272,2741.7739,10.8197);
  //TextDrawHideForPlayer(playerid,Textdraw0);
	}
	return 1;
}
Any help on what's the issue here is appreciated.

Regards
Reply


Messages In This Thread
Works on windows, issues on Linux? - by Acoole - 07.06.2009, 09:41
Re: Works on windows, issues on Linux? - by MenaceX^ - 07.06.2009, 11:02
Re: Works on windows, issues on Linux? - by Etthan - 07.06.2009, 11:41
Re: Works on windows, issues on Linux? - by Remis93 - 07.06.2009, 12:15
Re: Works on windows, issues on Linux? - by Acoole - 07.06.2009, 13:30
Re: Works on windows, issues on Linux? - by Etthan - 07.06.2009, 16:30
Re: Works on windows, issues on Linux? - by RobertGraham - 07.06.2009, 16:35
Re: Works on windows, issues on Linux? - by Burridge - 07.06.2009, 16:43
Re: Works on windows, issues on Linux? - by Etthan - 07.06.2009, 18:10

Forum Jump:


Users browsing this thread: 1 Guest(s)