Raised This Month: $ Target: $400
 0% 

Run time error 3: stack error


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Diegorkable
Veteran Member
Join Date: Jun 2011
Old 12-04-2011 , 14:16   Run time error 3: stack error
Reply With Quote #1

Hey guys.

I have a problem with my plugin, that it logs errors on the error_logs files with a runtime error, stack error ( as you can see in the thread title ).

These are the errors I get:

Code:
L 12/04/2011 - 21:09:36: [AMXX] Displaying debug trace (plugin "pimpdr.amxx")
L 12/04/2011 - 21:09:36: [AMXX] Run time error 3: stack error 
L 12/04/2011 - 21:09:36: [AMXX]    [0] pimpdr.sma::free_round (line 549)
L 12/04/2011 - 21:09:36: [AMXX] Displaying debug trace (plugin "pimpdr.amxx")
L 12/04/2011 - 21:09:36: [AMXX] Run time error 3: stack error 
L 12/04/2011 - 21:09:36: [AMXX]    [0] ColorChat2.inc::ColorChat (line 63)
L 12/04/2011 - 21:09:36: [AMXX]    [1] pimpdr.sma::free_round (line 549)
L 12/04/2011 - 21:09:36: [AMXX] Displaying debug trace (plugin "pimpdr.amxx")
L 12/04/2011 - 21:09:36: [AMXX] Run time error 3: stack error 
L 12/04/2011 - 21:09:36: [AMXX]    [0] ColorChat2.inc::Team_Info (line 84)
L 12/04/2011 - 21:09:36: [AMXX]    [1] ColorChat2.inc::ColorSelection (line 98)
L 12/04/2011 - 21:09:36: [AMXX]    [2] ColorChat2.inc::ColorChat (line 64)
L 12/04/2011 - 21:09:36: [AMXX]    [3] pimpdr.sma::free_round (line 549)
And all the error logs are coming from my plugin, pimpdr.sma, on line 549. I tried to check, the server crashed once. I checked the time it crashed and compared it to the error log, it was the same time, meaning it must had made it crash.

This is the public free_round, all it does simply that when you pick up a weapon, it strips it (using client_cmd("weapon_knife") isnt efficient cuz ppl can bug it and still use the weapon) (Activated when someone activates a free round, I guess you know what a free round might be on DEATHRUN plugin)

PHP Code:
public plugin_init()
{
        
// ......

        
register_event("CurWeapon""free_round""be""1=1""2!29");
}

public 
free_round(id)
{
    if ( !
is_user_alive(id) || !is_user_connected(id) )
        return;
        
    else if ( 
g_FreeRound )
    {
        
strip_user_weapons(id)
        
give_item(id"weapon_knife");
        
ColorChat(idRED"%s ^3You can not ^4switch weapons^3 on a ^4Free Round^3!"PREFIX_COLOR)
    }

Is there something wrong with what I do?
__________________
My Projects:

Auto-Mix (Pug): 100%

Joined the Military (a soldier now) - Inactive
Diegorkable is offline
Bos93
Veteran Member
Join Date: Jul 2010
Old 12-04-2011 , 14:39   Re: Run time error 3: stack error
Reply With Quote #2

else if ( g_FreeRound )

-->

if ( g_FreeRound )


and Check is_user_alive contains check is_user_connected
Bos93 is offline
Send a message via ICQ to Bos93 Send a message via Skype™ to Bos93
Diegorkable
Veteran Member
Join Date: Jun 2011
Old 12-04-2011 , 16:15   Re: Run time error 3: stack error
Reply With Quote #3

So this is why I get the errors?
__________________
My Projects:

Auto-Mix (Pug): 100%

Joined the Military (a soldier now) - Inactive
Diegorkable is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 12-04-2011 , 20:35   Re: Run time error 3: stack error
Reply With Quote #4

Quote:
Originally Posted by Diegorkable View Post
So this is why I get the errors?
No. His suggestion changes nothing.

The errors you posted are strange (not consistent). If I had to guess, it's something entirely unrelated causing it. Maybe somebody else will know more about stack errors.
__________________

Last edited by fysiks; 12-04-2011 at 20:37.
fysiks is offline
jim_yang
Veteran Member
Join Date: Aug 2006
Old 12-04-2011 , 20:56   Re: Run time error 3: stack error
Reply With Quote #5

public free_round(id)
{
if ( g_FreeRound )
{
engclient_cmd(id, "weapon_knife");
}
}
__________________
Project : CSDM all in one - 99%
<team balancer#no round end#entity remover#quake sounds#fake full#maps management menu#players punishment menu#no team flash#colored flashbang#grenade trails#HE effect#spawn protection#weapon arena#weapon upgrade#auto join#no weapon drop#one name>
jim_yang is offline
Diegorkable
Veteran Member
Join Date: Jun 2011
Old 12-07-2011 , 09:29   Re: Run time error 3: stack error
Reply With Quote #6

Quote:
Originally Posted by jim_yang View Post
public free_round(id)
{
if ( g_FreeRound )
{
engclient_cmd(id, "weapon_knife");
}
}
can you read the fucking thread before you post...?
__________________
My Projects:

Auto-Mix (Pug): 100%

Joined the Military (a soldier now) - Inactive
Diegorkable is offline
Reply



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

Forum Jump


All times are GMT -4. The time now is 11:54.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode