SA-MP Forums

Go Back   SA-MP Forums > SA-MP Server > Server Support

Reply
 
Thread Tools Display Modes
Old 02/09/2014, 01:04 PM   #1
Guest4390857394857
Guest
 
Posts: n/a
Question [HELP]Server Crash - Located crash line with CrashDETECT -

pawn Code:
forward scoretimer();
public scoretimer()
{
    for(new i; i<MAX_PLAYERS; i++)
    {
        if(!IsPlayerConnected(i)) continue;
        seconds[i] ++;
        if(seconds[i] == 3600)
        {
            SetPlayerScore(i, GetPlayerScore(i) + 1);
            seconds[i] = 0;
        }
    }
    return 1;
}
Why the above code crashes the server? Can anyone fix the code & also explain me why it crashes?
  Reply With Quote
Old 03/09/2014, 06:50 AM   #2
Marsss
Banned
 
Join Date: Dec 2013
Posts: 57
Reputation: 1
Default Re: [HELP]Server Crash - Located crash line with CrashDETECT -

Let's Fix the Line


forward scoretimer();
public scoretimer()


I think this line is problme becouse you doesn't made the score timer, with (1000,1)

Okay Thanks..

Please REP ME
Marsss is offline   Reply With Quote
Old 03/09/2014, 07:04 PM   #3
ALBJ
Big Clucker
 
ALBJ's Avatar
 
Join Date: Sep 2013
Posts: 47
Reputation: 3
Default Re: [HELP]Server Crash - Located crash line with CrashDETECT -

lol, nice mars.
ALBJ is offline   Reply With Quote
Old 04/09/2014, 10:00 PM   #4
Harry :)
Little Clucker
 
Join Date: Aug 2012
Location: Germany
Posts: 33
Reputation: 15
Default AW: [HELP]Server Crash - Located crash line with CrashDETECT -

I doubt any of those replies helped you, since it's a script-based problem you could expect more professional help and attention in the Scripting Help Section.
__________________
"Only two things are infinite, the universe and human stupidity, and I'm not sure about the former."
- Albert Einstein
Harry :) is offline   Reply With Quote
Old 05/09/2014, 04:37 AM   #5
Flake.
High-roller
 
Flake.'s Avatar
 
Join Date: Sep 2009
Location: 1400
Posts: 1,213
Reputation: 132
Default Re: [HELP]Server Crash - Located crash line with CrashDETECT -

Quote:
Originally Posted by Marsss View Post
Let's Fix the Line


forward scoretimer();
public scoretimer()


I think this line is problme becouse you doesn't made the score timer, with (1000,1)

Okay Thanks..

Please REP ME



Why are you doing this?
pawn Code:
if(!IsPlayerConnected(i)) continue;
If this player isn't connected then continue the loop?
Flake. is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Weird crashes. Used crashdetect.so to read out the crash thimo Scripting Help 9 25/07/2013 03:21 PM
Help with crash.. i can't understand what does crashdetect mean. Gaurav_Rawat Scripting Help 4 03/02/2013 03:11 AM
Crash || Crashdetect plugin logs inside Jaber_Brown Scripting Help 4 12/08/2012 04:48 PM
Server crash with crashdetect ArchBishop Server Support 1 06/06/2012 02:31 AM
Crash at address, using CrashDetect ikkentim Scripting Help 2 29/03/2012 02:43 PM


All times are GMT. The time now is 10:01 PM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.