[SOLVED] IgnoreLayers error when exiting the game during custom screen

Discuss how to use the Ren'Py engine to create visual novels and story-based games. New releases are announced in this section.
Forum rules
This is the right place for Ren'Py help. Please ask one question per thread, use a descriptive subject like 'NotFound error in option.rpy' , and include all the relevant information - especially any relevant code and traceback messages. Use the code tag to format scripts.
Post Reply
Message
Author
User avatar
Verdelite
Newbie
Posts: 8
Joined: Tue May 08, 2018 8:41 am
Projects: Embers' Pyre, Adventurer's Guild
Deviantart: FadeLalique
Contact:

[SOLVED] IgnoreLayers error when exiting the game during custom screen

#1 Post by Verdelite »

Hello,
while my custom screen is active, I am encountering an error. Almost every time when I try to exit the game by clicking the exit button (triggering the "Are you sure you want to quit?" prompt), the game will crash.
However, this does not seem to happen every single time. And it seems that if I open the menu by right-clicking or by pressing esc while my custom screen is active, it doesn't throw this error anymore. The same goes for reloading the game after the error has already occured.

I have no idea what's happening here, so I'd highly appreciate your input.

This is the code for my custom screen:

Code: Select all

transform move_left:
    subpixel True
    xalign 0.9
    xanchor 0.0
    alpha 0.0 yalign 1.0 yanchor 1.0
    parallel:
        easein 0.75 alpha 1.0
    parallel:
        easein 0.75 xanchor 0.8

screen home_screen():

    vbox:
        at move_left
        $ style.image_button.hover_sound = "se/UI_Confirm2.mp3"
        $ style.image_button.activate_sound = "se/UI_Confirm1.mp3"
        imagebutton auto "buttons/button_home_status_%s.png":
            focus_mask True
            action Call("not_implemented_yet")
        imagebutton auto "buttons/button_home_schedule_%s.png":
            focus_mask True
            action Call("not_implemented_yet")
        imagebutton auto "buttons/button_home_inventory_%s.png":
            focus_mask True
            action Call("not_implemented_yet")
        imagebutton auto "buttons/button_home_goout_%s.png":
            focus_mask True
            action Call("not_implemented_yet")
This is the error log:

Code: Select all

I'm sorry, but an uncaught exception occurred.

While running game code:
  File "game/script.rpy", line 22, in script
    call screen home_screen()
  File "renpy/common/000statements.rpy", line 519, in execute_call_screen
    store._return = renpy.call_screen(name, *args, **kwargs)
IgnoreLayers: 

-- Full Traceback ------------------------------------------------------------

Full traceback:
  File "game/script.rpy", line 22, in script
    call screen home_screen()
  File "D:\Program Files\Renpy\renpy-6.99.14.3-sdk\renpy\ast.py", line 1828, in execute
    self.call("execute")
  File "D:\Program Files\Renpy\renpy-6.99.14.3-sdk\renpy\ast.py", line 1816, in call
    return renpy.statements.call(method, parsed, *args, **kwargs)
  File "D:\Program Files\Renpy\renpy-6.99.14.3-sdk\renpy\statements.py", line 177, in call
    return method(parsed, *args, **kwargs)
  File "renpy/common/000statements.rpy", line 519, in execute_call_screen
    store._return = renpy.call_screen(name, *args, **kwargs)
  File "D:\Program Files\Renpy\renpy-6.99.14.3-sdk\renpy\exports.py", line 2710, in call_screen
    rv = renpy.ui.interact(mouse="screen", type="screen", roll_forward=roll_forward)
  File "D:\Program Files\Renpy\renpy-6.99.14.3-sdk\renpy\ui.py", line 287, in interact
    rv = renpy.game.interface.interact(roll_forward=roll_forward, **kwargs)
  File "D:\Program Files\Renpy\renpy-6.99.14.3-sdk\renpy\display\core.py", line 2649, in interact
    repeat, rv = self.interact_core(preloads=preloads, trans_pause=trans_pause, **kwargs)
  File "D:\Program Files\Renpy\renpy-6.99.14.3-sdk\renpy\display\core.py", line 3451, in interact_core
    rv = root_widget.event(ev, x, y, 0)
  File "D:\Program Files\Renpy\renpy-6.99.14.3-sdk\renpy\display\layout.py", line 992, in event
    rv = i.event(ev, x - xo, y - yo, cst)
  File "D:\Program Files\Renpy\renpy-6.99.14.3-sdk\renpy\display\layout.py", line 992, in event
    rv = i.event(ev, x - xo, y - yo, cst)
  File "D:\Program Files\Renpy\renpy-6.99.14.3-sdk\renpy\display\layout.py", line 992, in event
    rv = i.event(ev, x - xo, y - yo, cst)
  File "D:\Program Files\Renpy\renpy-6.99.14.3-sdk\renpy\display\screen.py", line 705, in event
    raise renpy.display.layout.IgnoreLayers()
IgnoreLayers: 

Windows-8-6.2.9200
Ren'Py 7.0.0.196

Thank you in advance!

EDIT:
I forgot to mention that this error also occurs when I remove the transformation for the custom screen, so the transform is most likely not the issue.
Last edited by Verdelite on Mon Jun 18, 2018 6:00 am, edited 1 time in total.

User avatar
gas
Miko-Class Veteran
Posts: 842
Joined: Mon Jan 26, 2009 7:21 pm
Contact:

Re: IgnoreLayers error when exiting the game during custom screen

#2 Post by gas »

Style statements, my friend.

The way you're declaring them is wrong. They need to be at init level, not inside the screen definition.
If you want to debate on a reply I gave to your posts, please QUOTE ME or i'll not be notified about. << now red so probably you'll see it.

10 ? "RENPY"
20 GOTO 10

RUN

User avatar
Verdelite
Newbie
Posts: 8
Joined: Tue May 08, 2018 8:41 am
Projects: Embers' Pyre, Adventurer's Guild
Deviantart: FadeLalique
Contact:

Re: IgnoreLayers error when exiting the game during custom screen

#3 Post by Verdelite »

gas wrote: Sun Jun 17, 2018 8:17 am Style statements, my friend.

The way you're declaring them is wrong. They need to be at init level, not inside the screen definition.
Thank you!
I removed the two lines with the button-style statements and instead placed the following snippet into the script:

Code: Select all

init python:
    style.image_button.hover_sound = "se/UI_Confirm2.mp3"
    style.image_button.activate_sound = "se/UI_Confirm1.mp3"
However, I am still getting the same error :(

EDIT:
Nevermind, I'm dumb. I've had an unused screen that still included the style statements. It now works properly!
Thank you so much!!! ^///^

Post Reply

Who is online

Users browsing this forum: Belgerum