Author Topic: I Have No Idea Why My Server Crash ???  (Read 3185 times)

0 Members and 1 Guest are viewing this topic.

Offline killvn1

  • Street Thug
  • *
  • Posts: 33
    • View Profile
I Have No Idea Why My Server Crash ???
« on: January 22, 2013, 05:50:45 pm »
I develop my server from Gup 1.16 . I Complier file pwn to amx with No error  ??? . But sometimes my server crash . Not always but sometime ... when player are playing ... The server suddenly crash .
I have No Idea why .

Is there any way to know exactly what is the error with my server ? Because my server now have more 20.000 sentence of scripts ! I Will goto crazy if i check each line  :-\

Offline sseebbyy

  • VC:MP Veteran
  • *****
  • Posts: 774
  • Immortal VC:MP Player
    • View Profile
    • Zombie Invasion => Server Forum [DEAD PROJECT]
Re: I Have No Idea Why My Server Crash ???
« Reply #1 on: January 22, 2013, 05:55:38 pm »
Sometimes some noob players can crash your server without a reason.

But sometimes the script makes your server to crash.

I think you should make an "Anti-Crash System" .

How to do that ?
You have to print in the RCON Console everything !

Everything ?
Yes ! Print in the RCON Console everything:
     - when a player join.
     - when a player enter in a vehicle
     - when a player request class
     - when a timer set by you is called (like an "pay-day" or everything)
     - etc.

Code: [Select]
To print a text in RCON Console, use "printf()" function.
http://thijn.vrocker-hosting.co.uk/VCWiki/index.php/Printf

I hope you got it. Good Luck !
« Last Edit: January 22, 2013, 05:57:43 pm by sseebbyy »

Quote
Painful/Noob scripters acts like: I Am The Best Scripter Because I Announce My Releases With Big Font Size Without Giving Too Much Info' In The Hope They All Will Download And Check It. I Ignore Bad Replies, Replies That I Could Learn From, And Replies With So Much Text.



Offline killvn1

  • Street Thug
  • *
  • Posts: 33
    • View Profile
Re: I Have No Idea Why My Server Crash ???
« Reply #2 on: January 23, 2013, 08:37:29 am »
Yeah I know about "printf()" function ... But please explain more clearly .
How can the "printf()" function show me the error of my scripts ?

Thank you for answer !

Offline sseebbyy

  • VC:MP Veteran
  • *****
  • Posts: 774
  • Immortal VC:MP Player
    • View Profile
    • Zombie Invasion => Server Forum [DEAD PROJECT]
Re: I Have No Idea Why My Server Crash ???
« Reply #3 on: January 23, 2013, 03:54:21 pm »
It will not show you the errors, but will tell you when the server stop.

For example, a player spawned. You have to use "printf()" to create a text by script sent to the console that shows that player spawned.

Code: [Select]
OnPlayerSpawn(playerid, classid)
{
     new gPlayers[MAX_PLAYERS][MAX_PLAYER_NAME+1]; //Use this if you don't have it already created.
     GetPlayerName(playerid,gPlayers[playerid],MAX_PLAYER_NAME); //Use this if you don't have it already created.

     printf("** pm >> [%d] %s spawned.",playerid,gPlayers[playerid]);
     return 1;
}

And when the server will get crash, you have to check the last message printed in console. In my example I used OnPlayerSpawn , so , if the server get crash and the last message was that "** pm >> [1] killvn1 spawned."  , you have to check the OnPlayerSpawn to see if there is any script mistake.
« Last Edit: January 23, 2013, 04:10:16 pm by sseebbyy »

Quote
Painful/Noob scripters acts like: I Am The Best Scripter Because I Announce My Releases With Big Font Size Without Giving Too Much Info' In The Hope They All Will Download And Check It. I Ignore Bad Replies, Replies That I Could Learn From, And Replies With So Much Text.



Offline killvn1

  • Street Thug
  • *
  • Posts: 33
    • View Profile
Re: I Have No Idea Why My Server Crash ???
« Reply #4 on: January 23, 2013, 04:10:15 pm »
Got it ... it's will take a little time but worth to do :))

Offline aledark24

  • Made Man
  • ***
  • Posts: 206
  • I am a scripter and you have celous of me....so you crashed my servers
    • View Profile
Re: I Have No Idea Why My Server Crash ???
« Reply #5 on: January 27, 2013, 03:36:39 am »
i have idea... i know gups and not contain anti-nickname example if the player use  #*-+(+&!:!:;
and register the server crashed
and if use !myprops server is crashed again
 ;D
I am a great scripter and you are celous of my works
.....

Vice City Life Multiplayer By Saint