Author Topic: General Discussion  (Read 3821649 times)

0 Members and 42 Guests are viewing this topic.

Offline DarkTl

  • Hero Member
  • *****
  • Posts: 4737
Re: General Discussion
« Reply #7200 on: April 26, 2016, 12:52:26 PM »
- Pretty much no matter the building there will be universal jobs. Like cleaners or/and guards. I suppose there could be cases when you don't need them, but we don't have them yet. They cannot clean/guard one business but don't clean/guard another one in the same building. Or rather, they can, but it makes no sense.

There could be upgrades for them of course, but still the game somehow should manage universal workers even without businesses upgrades.

- Living rooms. Even if you have zero businesses in the building, it can't prevent you from giving a place to live to your slaves. In fact it will help, since you'll have more free space for them  :)

- Independent activation and deactivation of any business in a building, without the need to demount upgrades (which btw should be  demountable for additional gold).

- Alkion aka Dungeon Keeper style of making rooms. I want to for MC house for sure. But perhaps it should be a part of any building.

Offline Xela

  • Global Moderator
  • *****
  • Posts: 6893
  • "It's like hunting cows"
Re: General Discussion
« Reply #7201 on: April 26, 2016, 01:46:02 PM »
Game already can manage "universal workers", but we also have "businesses" for those (what's one of the reasons I didn't really call them businesses in the code internally, apartment space, cleaners, guard quarters and etc. work/will work off the same logic).

Yeah, there will be slave quarters and apartment blocks as well.

Activation is easy, that will be in soon.

I don't really want to allow individual rooms, at first anyway but we'll have a house, mansion, apartments blocks which you can build at and settle MC in.
Like what we're doing?

Offline DarkTl

  • Hero Member
  • *****
  • Posts: 4737
Re: General Discussion
« Reply #7202 on: April 27, 2016, 05:33:06 AM »
When I added missing hits, I didn't know how to disable damage output and just made it 0, but in fact we don't really need to show dmg 0 all the time in battle logs.

Offline Xela

  • Global Moderator
  • *****
  • Posts: 6893
  • "It's like hunting cows"
Re: General Discussion
« Reply #7203 on: April 27, 2016, 06:17:11 AM »
Right, I've fixed it.
Like what we're doing?

Offline DarkTl

  • Hero Member
  • *****
  • Posts: 4737
Re: General Discussion
« Reply #7204 on: April 27, 2016, 06:46:07 AM »
My testing code.
Quote
init python:
    q = register_quest("Drunk Lady")
    register_event("drunk_lady1", quest="Drunk Lady", locations=["tavern_inside"], dice=100)
   
label drunk_lady1(event):
    hero.say "Huh?"
    menu:
        "Yes":
            $ pytfall.world_quests.get(event.quest).next_in_label("Test.", "piece1")
            $ pytfall.world_events.kill_event("drunk_lady1")
            $ register_event_in_label("drunk_lady2", quest=event.quest, locations=["tavern_inside"], dice=100, max_runs=2, restore_priority=1)
        "No":
            "'K"
    return
The idea is to ask player if he wants to be engaged in event/quest, and allow to return later if he doesn't want to. The first event has no max_runs, and nothing happens if you answer No, so in theory you can answer No and return later. But for some reason it doesn't work like that.

Offline Xela

  • Global Moderator
  • *****
  • Posts: 6893
  • "It's like hunting cows"
Re: General Discussion
« Reply #7205 on: April 27, 2016, 07:18:26 AM »
Did you try to add max_runs value to the first event? You add it to the second event that you register in the label but not to the first...

If not, quest might be deleting it, I don't remember that system too well but it would be weird if it did.
Like what we're doing?

Offline DarkTl

  • Hero Member
  • *****
  • Posts: 4737
Re: General Discussion
« Reply #7206 on: April 27, 2016, 08:30:26 AM »
Aaah, found it. Repeatable events by default take 5 days to be repeated again, it should be changed manually.

Offline DarkTl

  • Hero Member
  • *****
  • Posts: 4737
Re: General Discussion
« Reply #7207 on: April 27, 2016, 02:47:27 PM »
Great. Looks like pytfall.world_events.kill_event function doesn't work instantly too, you need to go to the next day or the event it killed still will be fully available. I pushed my code for tavern and its events.

Also, from time to time in tavern I get
Quote
  File "game/library/screens/locations/tavern_inside.rpy", line 82, in script
    $ result = ui.interact()
  File "game/library/screens/locations/tavern_inside.rpy", line 82, in <module>
    $ result = ui.interact()
  File "renpy/common/00action_other.rpy", line 443, in __call__
    rv = self.callable(*self.args, **self.kwargs)
  File "game/library/events/classes - events.rpy", line 82, in run_events
    if event.check_conditions():
  File "game/library/events/classes - events.rpy", line 246, in check_conditions
    elif self.run_conditions and all(list(bool(eval(c)) for c in self.run_conditions)): return True
  File "game/library/events/classes - events.rpy", line 246, in <genexpr>
    elif self.run_conditions and all(list(bool(eval(c)) for c in self.run_conditions)): return True
TypeError: eval() arg 1 must be a string or code object
When I use look around option. No idea why.

Offline Xela

  • Global Moderator
  • *****
  • Posts: 6893
  • "It's like hunting cows"
Re: General Discussion
« Reply #7208 on: April 27, 2016, 03:32:52 PM »
I've pushed two fixes:

- Error was due to you not using a string as a condition.
- You had to add cache=True to the kill_event method to remove it from active cache.
Like what we're doing?

Offline DarkTl

  • Hero Member
  • *****
  • Posts: 4737
Re: General Discussion
« Reply #7209 on: April 27, 2016, 03:57:47 PM »
I recall you coded long time ago temporary buttons or something like that to be used for events. Not inside interactions.
I suspect it was before we moved the repo, don't see anything like that in commits.
« Last Edit: April 27, 2016, 04:12:37 PM by DarkTl »

Offline Xela

  • Global Moderator
  • *****
  • Posts: 6893
  • "It's like hunting cows"
Re: General Discussion
« Reply #7210 on: April 27, 2016, 04:36:43 PM »
I recall you coded long time ago temporary buttons or something like that to be used for events. Not inside interactions.
I suspect it was before we moved the repo, don't see anything like that in commits.

More or less. I've added two systems:

1) Menu extension system, you can see how it works in the frog/witch quests.
2) Plainly showing screens. I think there are setups of that in that unfinished Nami quests and the frog initial meeting as well. Both are just buttons... you can place any button the same way.
Like what we're doing?

Offline lamoli

  • Hero Member
  • *****
  • Posts: 553
Re: General Discussion
« Reply #7211 on: April 27, 2016, 07:42:21 PM »
V2 face update ( body diffuse on hair need fixing and some other minor adjustments ) but finaly got cheeks/jaw close to the base anime i wanted.. next step would be to lower the bottom of the eyes/top of nose/cheeks/ears to get the larger eyes type





Making clothing next..
« Last Edit: April 28, 2016, 01:16:14 AM by lamoli »

Offline DarkTl

  • Hero Member
  • *****
  • Posts: 4737
Re: General Discussion
« Reply #7212 on: April 28, 2016, 03:44:43 AM »
I wonder if it's possible somehow to run the next event in the chain right after finishing previous event, without doing anything...
I mean something like
Quote
                        $ register_event_in_label("drunk_lady3", quest=event.quest, locations=["tavern_inside"], dice=100, restore_priority=0)
                        $ pytfall.world_events.force_event("drunk_lady3")
                        $ pytfall.world_events.force_run("drunk_lady3")

Basically, I have two events chains (#1 and #2) that lead to the very same event scene (#3). So my options are:
- insert #3 code into both #1 and #2 by copypasting the same code. Will work flawlessly, but will be messy in terms of code.
- add a new location where #3 will run by itself. Will work, but it will be weird that you have to go to some location manually to continue the event.
- force #3 run after either #1 or #2 (they are independent) will be finished, or at least jump to some label right after either one will be finished. Not sure if possible.
« Last Edit: April 28, 2016, 03:48:24 AM by DarkTl »

Offline Xela

  • Global Moderator
  • *****
  • Posts: 6893
  • "It's like hunting cows"
Re: General Discussion
« Reply #7213 on: April 28, 2016, 05:33:43 AM »
I wonder if it's possible somehow to run the next event in the chain right after finishing previous event, without doing anything...
I mean something like

Code: [Select]
                        $ register_event_in_label("drunk_lady3", quest=event.quest, locations=["tavern_inside"], dice=100, restore_priority=0)
                        $ pytfall.world_events.force_event("drunk_lady3")
                        $ pytfall.world_events.force_run("drunk_lady3")

Basically, I have two events chains (#1 and #2) that lead to the very same event scene (#3). So my options are:
- insert #3 code into both #1 and #2 by copypasting the same code. Will work flawlessly, but will be messy in terms of code.
- add a new location where #3 will run by itself. Will work, but it will be weird that you have to go to some location manually to continue the event.
- force #3 run after either #1 or #2 (they are independent) will be finished, or at least jump to some label right after either one will be finished. Not sure if possible.

Why does it have to be an event? You can just jump to a label after one or two, if there is a "do on another day" option for the event three, you can create a new event when player picks such an option.

I can add "force run" if you like, you already can do that if you can get to the event object, which should not be hard.
Like what we're doing?

Offline Xela

  • Global Moderator
  • *****
  • Posts: 6893
  • "It's like hunting cows"
Re: General Discussion
« Reply #7214 on: April 28, 2016, 05:35:37 AM »
V2 face update ( body diffuse on hair need fixing and some other minor adjustments ) but finaly got cheeks/jaw close to the base anime i wanted.. next step would be to lower the bottom of the eyes/top of nose/cheeks/ears to get the larger eyes type

Making clothing next..

Your previously sprites were just fine! Stop trying to improve upon greatness and just make the damn pack :D
Like what we're doing?