Making a Being a DIK mod & havin a code error - have traceback info

May 3, 2022
80
86
I made a mod for Being a DIK. While playing I have zero issues. However just recently if Ive played for a while when I go do a manual load (not Quick Load) this error will crop up typically. It happens at any point in the game so long as Ive been playing for a while & then do a manual load of a previous save.

If I quit the game, restart the game & load multiple saves, the save in question, or any save around it I do not get this error ever. All of the saves in question were made while usin the mod I made.

Ive not modified any of the .py files, header.rpy, or screens.rpy.

I have modified ep7_freeroam_hots.rpy but the line in question, line 120, Ive not touched.

And every time this crops up it references some line of code Ive not changed like in the below ex. I dont know what to do. Can someone help? It looks like its always related to a name not being defined but I dont know where to look to find the problem.

I can provide a dl link to the mod in its current form if that helps. I just didnt know if that would be ok since the postin of mods to F95 have pretty stringent rules.


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



Full traceback:

File "game/season2/scripts/freeroam/episode7/ep7_freeroam_hots.rpy", line 120, in script

menu:

File "renpy/ast.py", line 1688, in execute

choice = (choices, self.set, args, kwargs, item_arguments)

File "game/header.rpy", line 284, in menu_override

File "renpy/exports.py", line 1062, in menu

rv = (new_items)

File "renpy/exports.py", line 1298, in display_menu

rv = renpy.ui.interact(mouse='menu', type=type, roll_forward=roll_forward)

File "renpy/ui.py", line 298, in interact

rv = renpy.game.interface.interact(roll_forward=roll_forward, **kwargs)

File "renpy/display/core.py", line 3315, in interact

repeat, rv = self.interact_core(preloads=preloads, trans_pause=trans_pause, pause=pause, pause_start=pause_start, **kwargs)

File "renpy/display/core.py", line 3735, in interact_core

root_widget.visit_all(lambda i : i.per_interact())

File "renpy/display/core.py", line 568, in visit_all

d.visit_all(callback, seen)

File "renpy/display/core.py", line 568, in visit_all

d.visit_all(callback, seen)

File "renpy/display/core.py", line 568, in visit_all

d.visit_all(callback, seen)

File "renpy/display/screen.py", line 436, in visit_all

callback(self)

File "renpy/display/core.py", line 3735, in <lambda>

root_widget.visit_all(lambda i : i.per_interact())

File "renpy/display/screen.py", line 447, in per_interact

self.update()

File "renpy/display/screen.py", line 637, in update

self.screen.function(**self.scope)

File "game/screens.rpy", line 339, in execute

File "game/screens.rpy", line 339, in execute

File "game/screens.rpy", line 343, in execute

File "game/screens.rpy", line 343, in <module>

NameError: name 'phone_opened' is not defined



A 2nd example of the problem:

While running game code:

File "game/season2/scripts/update7.rpy", line 7047, in script

if minigames and not mTask_2f_state_list[7]:

File "game/season2/scripts/update7.rpy", line 7047, in <module>

if minigames and not mTask_2f_state_list[7]:

NameError: name 'minigames' is not defined



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



Full traceback:

File "game/season2/scripts/update7.rpy", line 7047, in script

if minigames and not mTask_2f_state_list[7]:

File "renpy/ast.py", line 1898, in execute

if renpy.python.py_eval(condition):

File "renpy/python.py", line 2276, in py_eval

return py_eval_bytecode(code, globals, locals)

File "renpy/python.py", line 2269, in py_eval_bytecode

return eval(bytecode, globals, locals)

File "game/season2/scripts/update7.rpy", line 7047, in <module>

if minigames and not mTask_2f_state_list[7]:

NameError: name 'minigames' is not defined



Windows-10-10.0.19041

Ren'Py 7.4.10.2178

Being a DIK 0.8.3

Fri Dec 9 21:04:39 2022
 

Madeddy

Active Member
Dec 17, 2017
814
470
I have modified ep7_freeroam_hots.rpy but the line in question, line 120, Ive not touched.
It is irrelevant whether the line where the error occurs has been changed. Happens all the time that you break somewhere code and and in a entirely different place, pops a error up. Thais can move across files.
You changed something else in a wrong way and this has a effect on the object names, which are cited in the error: phone_opened and minigames are for some reason not initialized, which should not happen. Part of their code is skipped because of one of your changes.

I think this will be ok, if not we hear it: Attach here simply your mods script files(no images or stuff) and pack the same set of unchanged original files to it. (I dont have the current DIK version)

Greets
 
Last edited:
May 3, 2022
80
86
It edits 151 files in total so it wont let me upload the mod here on site. I kept the original mod I since decided that I likely fucked up like you said.

Yesterday I went through & started over from scratch findin a surprisingly large amount of sloppy mistakes I made in the code. This is my 1st time ever doin this so I guess its to be expected. Frustratin but I guess Im not surprised.

I made a new mod w/o the stupid mistakes usin the old one w/split diff to to make it go faster. It still took the entire day to finish it all. The DnG edits are below the standard Id like them at but I was pretty sure the ones I made there in the original mod were part of the problem. So I edited lightly in there for now. Between the eps6 DnG edits & an overuse of bad locations for DIK score updates I felt pretty confident the issue lay w/one or both of those. So I got rid of anythin touchin that shit that I couldnt be 100% sure of.

Its a WT mod w/o Cheats for Being a DIK. Its up to date for 8.3 but I see no reason why it wouldnt work w/previous versions. Originally I was makin it off of the 8.2 version. It avoids all current DPC mod detection I could identify.

Current mod rewritten from scratch:
Old mod w/errors:

Im about to start a run now but I am gonna take my time to enjoy it since I wasnt sure which saves were corrupted. So I deleted every save file I had to be safe. So in 24-48 hrs I should be finished & will have saves made at just about every scene change to ensure no errors like the one from before exist.

Thanks for respondin.
 
May 3, 2022
80
86
Since then I tracked down that I was havin an issue w/labels. Ive removed these issues & no longer generate any error or traceback txt filles. Ive also solved the error notifications that appeared in the log.txt so things are workin at 100% on my side now.

Well 99.99%. There appears to be some issue w/the playback of the DPC splash logo (paint + cake) w/guitar sound. Video/sound play back on start of the game. I ended up adding in a 2nd play of this to ensure it plays now but I didnt solve the problem.

If I reboot or boot up my PC & run the game it will now play the DPC logo/sound twice in a row. Thereafter the sequence it should play on restarting the game or launching the game a 2nd time wont so it only plays once due to the added code I put in. Rebooting or shutting the PC down will then cause this issue to repeat. Playin twice on the 1st load of the game & then not playin twice again until PC is restarted/shut down.

But like I also said this generates no errors, no error.txt, no traceback.txt, & no entries in log.txt. Its makin me wonder if there isnt somethin not 100% right w/BAD itself & somehow my mod exacerbatted the problem bringin it to light? Could be just my mod tho too. I dont know. All I feel sure of is that its not affectin anythin besides that playback on game start for some reason.