News:

Please request registration email again and then check your "Spam" folder

Former www.henthighschool.com

v0.3 Test Version (Aug. 24 Update)

Started by Goldo, Aug 25, 2024, 10:58 PM

Previous topic - Next topic

GoldoTopic starter

New patch out: https://www.mediafire.com/file/1va1v7cq1psp53x/game+patch+0.3.zip/file

It should fix most problems except the 'save/load' issue. Evidently something has changed in the way Ren'py saves in later versions, but I can't put my finger on exactly what. It's linked to block_rollback() and such.

Original girls should now spawn as intended. As for traits, I have opted for a simpler solution that does not require running 'init_traits()' again. It should work, hopefully not breaking anything else in the process.
Maker of BK. Looking for the latest patch for BK 0.2? The link doesn't change, so bookmark it!

EvilPenguin

Quote from: Goldo on Aug 27, 2024, 10:01 AM
Quote from: EvilPenguin on Aug 27, 2024, 09:12 AMWith the new patch, fire in the brothel:

I'm sorry, but an uncaught exception occurred.

While running game code:
  File "game/BKmain.rpy", line 905, in script
    show expression room at top
Exception: Image 'bg strip club' does not accept attributes 'dusty'.

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

Full traceback:
  File "game/BKmain.rpy", line 905, in script
    show expression room at top
  File "E:\0 TEST play\Brothel_King-pc-0.3t 24ver\Brothel_King-pc\renpy\ast.py", line 1113, in execute
    show_imspec(self.imspec, atl=getattr(self, "atl", None))
  File "E:\0 TEST play\Brothel_King-pc-0.3t 24ver\Brothel_King-pc\renpy\ast.py", line 1076, in show_imspec
    renpy.config.show(name,
  File "E:\0 TEST play\Brothel_King-pc-0.3t 24ver\Brothel_King-pc\renpy\exports.py", line 749, in show
    img = i(child=img)
  File "E:\0 TEST play\Brothel_King-pc-0.3t 24ver\Brothel_King-pc\renpy\atl.py", line 623, in __call__
    child = child._duplicate(_args)
  File "E:\0 TEST play\Brothel_King-pc-0.3t 24ver\Brothel_King-pc\renpy\display\image.py", line 459, in _duplicate
    rv.find_target()
  File "E:\0 TEST play\Brothel_King-pc-0.3t 24ver\Brothel_King-pc\renpy\display\image.py", line 421, in find_target
    self.target = target._duplicate(a)
  File "E:\0 TEST play\Brothel_King-pc-0.3t 24ver\Brothel_King-pc\renpy\display\displayable.py", line 246, in _duplicate
    args.extraneous()
  File "E:\0 TEST play\Brothel_King-pc-0.3t 24ver\Brothel_King-pc\renpy\display\displayable.py", line 109, in extraneous
    raise Exception("Image '{}' does not accept attributes '{}'.".format(
Exception: Image 'bg strip club' does not accept attributes 'dusty'.

Windows-10-10.0.19045 AMD64
Ren'Py 8.2.0.24012702
Bro King 0.3t v240827
Tue Aug 27 11:10:01 2024


also loading and quick loading the game, for me loads a couple events back, not in the point where it was saved.
For example, I go to the city, do an action, go back to the brothel screen, save the game, load it and i'm loaded in the city.


I can't reproduce this. Did anything special happen before saving? Can you share steps to reproduce this on a new game?

My suspicions lie here.

Maybe try that line in the console on a botched game, save and see if it still happens?

With the newest pacth. I started a new game, got my 1st slave, went out to the city, talked to one girl, got back, saved at the brothel screen, then loaded and i was back in the city.

And for the line if you tell me what line should I use and where I will do it - i'm not a programmer so you would tell me step by step what to do.(if it would help you i could even record this whole thing).

Jman

#32
Well, I am sorry to report that I can still get a unique free girl to spawn once in the city and once more from the HH. Not for the third time, again, so I'd still say it's that '>1' line that's the culprit. At least they both show up now.

I am not sure why Goldo doesn't like my fix, unless there are plans to use the 'location' argument for more than just free girl cycling, or there's an intention to decouple free girl generation from cycling. It's actually a bit weird that the same function is used for two different purposes.



Sill is back! Perhaps I'm going too far here, but could we also get her as the icon for the actual executable? That one's still a regular Ren'Py icon. As I remember, you'd either have to compile the game throught the Ren'Py SDK to get that, or just use one of the icon replacer programs (which I used to do, since it was faster than getting the right SDK; not sure this doesn't alert some AV programs, though; never had that issue myself but it's possible, I think).



The mod activation/deactivation button has been secured and there's now enough space for the entire CJMT wall-of-text. Yay! ;D



Spicy food has turned bland in an attempt to cover up for the xianxia sellout. :P



I am seeing occasional instances of the dialogue window getting 'stuck' in a blank black state. Commonly when using the cheats menu, but occasionaly in other places, too.



@Malign Flightless Avian: console (Shift + O) the following every time just before you save:
renpy.retain_after_load()
Don't know if it'll help 100%, but it did for a few tests.
And with strange aeons even death may die...

EvilPenguin

Quote from: Jman on Aug 27, 2024, 06:11 PM@Malign Flightless Avian: console (Shift + O) the following every time just before you save:
renpy.retain_after_load()
Don't know if it'll help 100%, but it did for a few tests.

1st. The @name... Bruh... xD

2nd. The line works,

GoldoTopic starter

Quote from: EvilPenguin on Aug 27, 2024, 06:51 PM
Quote from: Jman on Aug 27, 2024, 06:11 PM@Malign Flightless Avian: console (Shift + O) the following every time just before you save:
renpy.retain_after_load()
Don't know if it'll help 100%, but it did for a few tests.

1st. The @name... Bruh... xD

2nd. The line works,

Could you try the following in the console, based on this documentation:
_greedy_rollback = False
You need to do it only once.
I suspect greedy rollback might be the culprit, as I think it's a new system. But it could very well be something else.

PS: When you go back to the main screen, do you right-click or use a shortcut?
Maker of BK. Looking for the latest patch for BK 0.2? The link doesn't change, so bookmark it!

GoldoTopic starter

Quote from: Jman on Aug 27, 2024, 06:11 PMWell, I am sorry to report that I can still get a unique free girl to spawn once in the city and once more from the HH. Not for the third time, again, so I'd still say it's that '>1' line that's the culprit. At least they both show up now.

I am not sure why Goldo doesn't like my fix, unless there are plans to use the 'location' argument for more than just free girl cycling, or there's an intention to decouple free girl generation from cycling. It's actually a bit weird that the same function is used for two different purposes.

I'm not sure what your fix does, but I don't see a link to the location at all. We need to make sure only one unique girl spawns, regardless if it's in the city or elsewhere (like the slavemarket).

My guess is that the girls generated at the headhunter are not included in the checked girl lists in the Girl class count_occurences() method. This can be tweaked by using the new 'add_list' argument in that method to include the HH girls.

But honestly I would rather rewrite 'can_generate' from scratch because it's not very readable and I'm not even clear on which parts of it I actually wrote (I included some code from DougTheC).
Maker of BK. Looking for the latest patch for BK 0.2? The link doesn't change, so bookmark it!

Jman

#36
I also didn't really get what 'can_generate' really does at a glance, so I just added a hack. :)

The hack checks if a free girl with a specified location is allowed to spawn there, and gives the green light regardless of uniqueness or anything. All the other checks will get skipped as long as a location is provided.

As long as only free girl cycling uses the optional 'location' parameter, this is fine. And I'm not really sure why cycling uses 'can_generate' in the first place. ???



Headhunter cannot generate a third girl, or a second one with '>=1', so I don't think that's a real problem with her. While HH girls are indeed in limbo (you could add [game.headhunter_girl] to the lists if the mod is enabled, I suppose; although that girl can be None, too), I think the no-repeat-templates thing in 'get_girls()' still disqualifies multiple uniques (since uniques are originals).


I only used her because the algorithm tries to spread out new girls across girl packs, and getting a second instance of the same girl is kinda hard to pull off naturally.



Edit: '_greedy_rollback = False' seems to fix the save rollback issue in the few tests I've done.
And with strange aeons even death may die...

EvilPenguin

Quote from: Goldo on Aug 27, 2024, 08:34 PM
Quote from: EvilPenguin on Aug 27, 2024, 06:51 PM
Quote from: Jman on Aug 27, 2024, 06:11 PM@Malign Flightless Avian: console (Shift + O) the following every time just before you save:
renpy.retain_after_load()
Don't know if it'll help 100%, but it did for a few tests.

1st. The @name... Bruh... xD

2nd. The line works,

Could you try the following in the console, based on this documentation:
_greedy_rollback = False
You need to do it only once.
I suspect greedy rollback might be the culprit, as I think it's a new system. But it could very well be something else.

PS: When you go back to the main screen, do you right-click or use a shortcut?

_greedy_rollback = False - this did the job

And i use right click to back.

EvilPenguin

A girl that came at level 1 with an unlocked class; when at level 4 I try do choose another one to unlock, she gets it but the level up button freezes and stays uo untill she gets next level up.

The girl is Hinata, save file if you need it: https://www.mediafire.com/file/mfeor9fsokor4n3/2-1-LT1.save/file

Jman

Not sure how she got that way, but it seems there should be a call to 'update_can_perk()' after level-up.
And with strange aeons even death may die...

EvilPenguin

#40
City girl, fetish option out of frame




EDIT:

After selecting a girl for the end of the month contract.

I'm sorry, but an uncaught exception occurred.

While running game code:
  File "game/BKendday.rpy", line 375, in script call
    call play_events(_type = "night") from _call_play_events
  File "game/BKevents.rpy", line 948, in script call
    call display_events(ev_list) from _call_display_events
  File "game/BKevents.rpy", line 960, in script call
    $ ev.play()
  File "game/BKevents.rpy", line 4550, in script call
    call dialogue(con.char, "contract greeting", con.type) from _call_dialogue
  File "game/BKdialogue.rpy", line 16, in script
    $ pick_dialogue(topic, key=key).say(char, nw=nw)
  File "game/BKdialogue.rpy", line 16, in <module>
    $ pick_dialogue(topic, key=key).say(char, nw=nw)
  File "game/BKdialogue.rpy", line 75, in say
    renpy.say(char, __(self.line))
TypeError: 'Population' object is not callable

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

Full traceback:
  File "game/BKendday.rpy", line 375, in script call
    call play_events(_type = "night") from _call_play_events
  File "game/BKevents.rpy", line 948, in script call
    call display_events(ev_list) from _call_display_events
  File "game/BKevents.rpy", line 960, in script call
    $ ev.play()
  File "game/BKevents.rpy", line 4550, in script call
    call dialogue(con.char, "contract greeting", con.type) from _call_dialogue
  File "game/BKdialogue.rpy", line 16, in script
    $ pick_dialogue(topic, key=key).say(char, nw=nw)
  File "E:\0 TEST play\Brothel_King-pc-0.3t 24ver\Brothel_King-pc\renpy\ast.py", line 823, in execute
    renpy.python.py_exec_bytecode(self.code.bytecode, self.hide, store=self.store)
  File "E:\0 TEST play\Brothel_King-pc-0.3t 24ver\Brothel_King-pc\renpy\python.py", line 1178, in py_exec_bytecode
    exec(bytecode, globals, locals)
  File "game/BKdialogue.rpy", line 16, in <module>
    $ pick_dialogue(topic, key=key).say(char, nw=nw)
  File "game/BKdialogue.rpy", line 75, in say
    renpy.say(char, __(self.line))
  File "E:\0 TEST play\Brothel_King-pc-0.3t 24ver\Brothel_King-pc\renpy\exports.py", line 1493, in say
    who(what, *args, **kwargs)
TypeError: 'Population' object is not callable

Windows-10-10.0.19045 AMD64
Ren'Py 8.2.0.24012702
Bro King 0.3t v240825
Thu Aug 29 00:14:08 2024

Hermenegild

#41
Quote from: Jman on Aug 28, 2024, 10:39 AMNot sure how she got that way, but it seems there should be a call to 'update_can_perk()' after level-up.
There is. What's missing is a call to update_can_perk() after unlocking a new perk tree. This way the icon stays even after you used your perk points.

@EvilPenguin, try consoling:

for g in MC.girls:
    g.update_can_perk()

GoldoTopic starter

New patch out.
https://www.mediafire.com/file/1va1v7cq1psp53x/game+patch+0.3.zip/file

Should fix everything. @Jman I redesigned the can_generate() function, not sure if it will solve your issue but at least it is clean now.
Maker of BK. Looking for the latest patch for BK 0.2? The link doesn't change, so bookmark it!

Toshiro

Just noticed that the text for some interactions with slaves is different from city girls and the sexual training text color.  The interactions are white, while the city girl and sex training one is a beige/yellow.  The old beige/yellow for slave interactions worked better since the greyed out options still look similar to the white text.  Not to mention the white text for slave interactions kind of blend in with the regular menu text.

Hermenegild

@Goldo, I have an issue with the save overwrite confirmation dialog (and probably any other confirmation dialog in the game, I haven't checked). Basically, the only way to accept is to click "Yes". My issue is, if you click anywhere but "Yes", it works as if you clicked "No", and you get no message about it. And it happens that you miss the button by a few pixels. Nothing happens then, and the only way you can check if the game was actually saved is to look at the saved game time, if it is this minute or two minutes ago.

Please make only the "Yes" and "No" buttons work, so that missing any of those buttons doesn't do anything.