Pythonw.exe Has Stopped Working

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
Googaboga
Eileen-Class Veteran
Posts: 1395
Joined: Wed Dec 12, 2012 1:37 pm
Completed: https://gbpatch.itch.io/
Projects: Floret Bond, XOXO Blood Droplets, Our Life
Organization: GB Patch Games
Tumblr: gb-patch
itch: gbpatch
Contact:

Pythonw.exe Has Stopped Working

#1 Post by Googaboga »

Hello! I'm trying to add DLC to the Steam release of one of my projects and attempted using a type of code mentioned at the bottom of this thread:
viewtopic.php?f=8&t=35886

The exact code I used is this-

Code: Select all

init -5 python:
    import _renpysteam
    _renpysteam.init()
    persistent.outfit_select_unlocked = _renpysteam.dlc_installed(12345)
With that in the script above the 'game start' label, the project either won't start at all (I click launch and nothing ever happens, if I remove the code it starts as it should) or I get a 'pythonw.exe has stopped working' crash.

I'm not sure if something's wrong with the code, my computer, my instillation of renpy or what. If anyone knows what kind of issue can cause a crash like that, I'd really appreciate the info.

Alternatively, if anyone has an idea for a different way to DLC, I'd be happy to try it out.

Thank you!
In-Progress:
Floret Bond, XOXO Blood Droplets, Our Life
Released:
A Foretold Affair, My Magical Divorce Bureau, XOXO Droplets, Lake of Voices

User avatar
PyTom
Ren'Py Creator
Posts: 16096
Joined: Mon Feb 02, 2004 10:58 am
Completed: Moonlight Walks
Projects: Ren'Py
IRC Nick: renpytom
Github: renpytom
itch: renpytom
Location: Kings Park, NY
Contact:

Re: Pythonw.exe Has Stopped Working

#2 Post by PyTom »

You should be checking to see if _renpysteam.init() returns True before doing any other steam calls.
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom
Software > Drama • https://www.patreon.com/renpytom

User avatar
Googaboga
Eileen-Class Veteran
Posts: 1395
Joined: Wed Dec 12, 2012 1:37 pm
Completed: https://gbpatch.itch.io/
Projects: Floret Bond, XOXO Blood Droplets, Our Life
Organization: GB Patch Games
Tumblr: gb-patch
itch: gbpatch
Contact:

Re: Pythonw.exe Has Stopped Working

#3 Post by Googaboga »

Thank you for the answer! This is probably a silly question, but how do I format that? Like-

Code: Select all

if _renpysteam.init():
    #stuff
Or something else?
In-Progress:
Floret Bond, XOXO Blood Droplets, Our Life
Released:
A Foretold Affair, My Magical Divorce Bureau, XOXO Droplets, Lake of Voices

User avatar
PyTom
Ren'Py Creator
Posts: 16096
Joined: Mon Feb 02, 2004 10:58 am
Completed: Moonlight Walks
Projects: Ren'Py
IRC Nick: renpytom
Github: renpytom
itch: renpytom
Location: Kings Park, NY
Contact:

Re: Pythonw.exe Has Stopped Working

#4 Post by PyTom »

That's the right way to do it.
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom
Software > Drama • https://www.patreon.com/renpytom

User avatar
Googaboga
Eileen-Class Veteran
Posts: 1395
Joined: Wed Dec 12, 2012 1:37 pm
Completed: https://gbpatch.itch.io/
Projects: Floret Bond, XOXO Blood Droplets, Our Life
Organization: GB Patch Games
Tumblr: gb-patch
itch: gbpatch
Contact:

Re: Pythonw.exe Has Stopped Working

#5 Post by Googaboga »

Thank you. I've added that to the code and unfortunately the issue with the game not launching is still there. When I make a mistake and there's an error in how the code is written the game does launch and point that out, so that's not the problem.

I'll see if I can try things out on someone else's computer. Maybe it's just a problem with how things are on on my end.
In-Progress:
Floret Bond, XOXO Blood Droplets, Our Life
Released:
A Foretold Affair, My Magical Divorce Bureau, XOXO Droplets, Lake of Voices

User avatar
PyTom
Ren'Py Creator
Posts: 16096
Joined: Mon Feb 02, 2004 10:58 am
Completed: Moonlight Walks
Projects: Ren'Py
IRC Nick: renpytom
Github: renpytom
itch: renpytom
Location: Kings Park, NY
Contact:

Re: Pythonw.exe Has Stopped Working

#6 Post by PyTom »

Sure. You should also check the Steam API documentation to make sure you're calling the function the right way.
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom
Software > Drama • https://www.patreon.com/renpytom

Post Reply

Who is online

Users browsing this forum: No registered users