Stack level too deep error when calling common event from battle

musicalgenocide

Villager
Member
Joined
Jun 8, 2014
Messages
12
Reaction score
1
First Language
English
Primarily Uses
The title is the gist of it, I'm trying to make (what I thought would be) a relatively simple event that causes a random skill to be chosen and used when a certain skill is used. The idea is that there is a "microphone" weapon which contains the skill "Melody." When the player uses "Melody" it would call one of 8 or 9 skills, based on a random variable. Instead, it just crashes the game. I guess my melody wasn't very good.

The exact error is:

-----------------------------------------

|    SystemStackError occured.   |

|                                                  |

|    stack level too deep               |

|_________________________|

I tried to accomplish this with Yanfly's Random Invoke script, but I couldn't get the script to do anything. I tried positioning the notetags every way I could think of, but no matter what I did, it would just use the "base" skill and nothing else. It did not produce the error, just didn't do anything.

I'm using 8,000,000 scripts (give or take,) but most of them are part of GubiD's tactical battle system, which seems to have a lot of potential to break things.

I have a feeling I'm doing something really simple wrong, and I'm okay with that, as long as someone tells me what it is. Thanks.

Screenshot 2014-07-28 02.24.26.png

scripts.png
 

Shaz

Global Moderators
Global Mod
Joined
Mar 2, 2012
Messages
41,284
Reaction score
14,274
First Language
English
Primarily Uses
RMMV
I've moved this thread to RGSSx Script Support. Please be sure to post your threads in the correct forum next time. Thank you.


A Stack Level too deep error is usually caused by either having the same script inserted into your project twice (check that none of the 'blank' slots actually has a script in it, and that none of your scripts are copied twice into the same slot, one below the other), or by having two scripts that use the same alias or method name.
 

TheGreenHorse

Veteran
Veteran
Joined
Mar 31, 2014
Messages
177
Reaction score
26
First Language
English
Primarily Uses
RMMV
This, purely does mean that you posted two scripts twice i.e it recognized two scripts installed having the same name.

Well it's pretty rare for you to have two scripts with the same name twice, so please try to tell us if you're using any other script. Sometimes script sites entirely different may name their scripts same.

Or first, just check up if your scripts are installed twice.
 

whitesphere

Veteran
Veteran
Joined
Mar 14, 2014
Messages
1,688
Reaction score
784
First Language
English
Could this also happen if a Common Event or script happened to call another which ended up calling the first one through some chain?

When I saw the "Stack Level Too Deep," that's what I assumed happened.  
 

musicalgenocide

Villager
Member
Joined
Jun 8, 2014
Messages
12
Reaction score
1
First Language
English
Primarily Uses
A Stack Level too deep error is usually caused by either having the same script inserted into your project twice (check that none of the 'blank' slots actually has a script in it, and that none of your scripts are copied twice into the same slot, one below the other), or by having two scripts that use the same alias or method name.
I went down the list for every script, checked all the blanks, there are no duplicates in the same page or a different one.

The error message doesn't even list a line or script; but it does highlight line 1 of GTBS Sprite_Battler_2 when I reopen the script menu.

1 class Sprite_Battler_GTBS < Sprite_Character

2  #--------------------------------------------------------------------------

3   # Imported Sprite_Battler methods (since I again, cannot modify the inheritance

4   #--------------------------------------------------------------------------

5   def update_whiten

6     self.color.set(255, 255, 255, 0)

7     self.color.alpha = 128 - (16 - @effect_duration) * 10

8   end

 

 

Also, I figured this was not a script issue (or at least not a new one) as I had not changed or modified any scripts before creating the event, with the lone exception of removing Yanfly's Random Skill Invoke, as again it was doing nothing, probably because something else is broken. I can only assume because of the massive reach of the GTBS script that it conflicts with several others unintentionally, but I'm not a scripter so I'm clueless.

 

Well it's pretty rare for you to have two scripts with the same name twice, so please try to tell us if you're using any other script. Sometimes script sites entirely different may name their scripts same.
I don't have any scripts that are duplicates, but I may have some that conflict with each other. Again, anything that tries to change something battle related is probably going to fight with the GTBS script, but I really don't know what as I'm not a scripter. I'm just a guy that likes shiny tactical battle systems in his RPG. My previous post has an attachment that shows every script that I have, excluding the exhaustive list of all the GTBS scripts. 

These screenshots contain all of the GTBS ones. I removed the LayyMeta Engine, otherwise, aside from the setup options, they are exactly as packaged in the demo

Screenshot 2014-07-28 11.51.28.png

Screenshot 2014-07-28 11.51.40.png

Screenshot 2014-07-28 11.51.50.png
 

musicalgenocide

Villager
Member
Joined
Jun 8, 2014
Messages
12
Reaction score
1
First Language
English
Primarily Uses
I downloaded both scripts and added them, this error log is all that I get.

I tried the    TH.trace_system_stack on line 1 and 712, doesn't change anything, it still produces the same error.

Screenshot 2014-07-28 13.38.03.png 

error_log.txt
 

Attachments

  • error_log.txt
    323 bytes · Views: 1

Tsukihime

Veteran
Veteran
Joined
Jun 30, 2012
Messages
8,564
Reaction score
3,862
First Language
English
Have you tried adding that line above line 172?


At least this is more informative than before.
 
Last edited by a moderator:

Latest Threads

Latest Posts

Latest Profile Posts

Interesting week. Lots of stress and anxiety especially on Tuesday but still got thru it. How is everyone doing?
I was pleased with how the little ... whatever those square bits like upside-down turrets on the skirt are? I like how they turned out. Here's a little ranger/bandit/archery enthusiast to model it:

TestChara-08.gif


I'm calling her Robin because obviously.
Just downloaded the demo and boy howdy are my arms tired (???) :kaohi:
I just watched a trailer for the upcoming 2021 JRPG Fantasian. They demonstrated an interesting mechanic where random encounters can be sent to a stockpile instead of fighting them right away, which can be emptied in a single battle string at the player's choice of timing.
"The pleasure from the senses seems like nectar at first, but it is sour as the toxin in the end." -Kirshna

Forum statistics

Threads
109,156
Messages
1,042,600
Members
141,656
Latest member
drackdragon113
Top