Author Topic: General Discussion  (Read 3821449 times)

0 Members and 41 Guests are viewing this topic.

Offline Xela

  • Global Moderator
  • *****
  • Posts: 6893
  • "It's like hunting cows"
Re: General Discussion
« Reply #6660 on: February 03, 2016, 02:28:21 PM »
I need to access character inside def __init__(self), where you set self.disposition_threshold, in order to run checks there. Looks like normal means like char of self.worker don't work.

You can't do that, it's a constructor. You can write a separate method for checking and call it inside of a func instead of using threshold directly.
Like what we're doing?

Offline DarkTl

  • Hero Member
  • *****
  • Posts: 4737
Re: General Discussion
« Reply #6661 on: February 04, 2016, 01:43:08 AM »
Ohhkey, for testing I did it like
Quote
def __init__(self):
...
    self.disposition_threshold = self.determine_disposition_level
....
def determine_disposition_level(self):
      disposition = 300
      return disposition
And it never appears in the job list regardless of disposition.

Seriously though, I mentioned that there will be checks, not just plain disposition level. And yet you code it in a way that gives me troubles with checks -_-
« Last Edit: February 04, 2016, 01:44:53 AM by DarkTl »

Offline Xela

  • Global Moderator
  • *****
  • Posts: 6893
  • "It's like hunting cows"
Re: General Discussion
« Reply #6662 on: February 04, 2016, 05:09:19 AM »
Seriously though, I mentioned that there will be checks, not just plain disposition level. And yet you code it in a way that gives me troubles with checks -_-

You misunderstood my proposal. I'll make a better code skeleton tonight.
Like what we're doing?

Offline DarkTl

  • Hero Member
  • *****
  • Posts: 4737
Re: General Discussion
« Reply #6663 on: February 06, 2016, 02:33:43 AM »
Well?  :)

Offline Xela

  • Global Moderator
  • *****
  • Posts: 6893
  • "It's like hunting cows"
Re: General Discussion
« Reply #6664 on: February 06, 2016, 06:25:27 AM »
Well?  :)

My birthday party on Thursday turned out to be more fun than expected :) I am still recovering so I can't manage more than a couple of lines per day. You'll have a setup to work with tomorrow.
Like what we're doing?

Offline DarkTl

  • Hero Member
  • *****
  • Posts: 4737
Re: General Discussion
« Reply #6665 on: February 06, 2016, 07:05:29 AM »
Happy birthday then!  :)

Mine is January 2, so I kinda kill two birds with one stone during the New Year.

Offline Xela

  • Global Moderator
  • *****
  • Posts: 6893
  • "It's like hunting cows"
Re: General Discussion
« Reply #6666 on: February 07, 2016, 01:51:24 PM »
Thanks :)

Setup is done, you can now either edit the general method for all jobs or add new specific method for individual jobs like:

Code: [Select]
class StripJob(...):
    bla bla bla...

    def is_valid_for(self, char):
        # bla bla bla
Like what we're doing?

Offline DarkTl

  • Hero Member
  • *****
  • Posts: 4737
Re: General Discussion
« Reply #6667 on: February 08, 2016, 11:08:29 AM »
Yeah, looks like it works. Awesome.

Offline Xela

  • Global Moderator
  • *****
  • Posts: 6893
  • "It's like hunting cows"
Re: General Discussion
« Reply #6668 on: February 08, 2016, 12:28:49 PM »
I'll keep hacking at interface and it's functionality. Once that is done, we'll have a working system and I'll add guard and cleaning jobs which will be a lot simpler with SimPy (loads of complexity was added to those because we never had proper loops/order to work with before). After that is done, job events can be restored and we'll work towards improving that until we get sick of it and switch to SE/Arena/BE (again).

For me, main area of motivation atm is SE, I have loads of ideas for it and code should be a lot clearer and more awesome with Ren'Py.
Like what we're doing?

Offline DarkTl

  • Hero Member
  • *****
  • Posts: 4737
Re: General Discussion
« Reply #6669 on: February 08, 2016, 12:39:42 PM »
What about free characters leaving with low disposition?

Offline Xela

  • Global Moderator
  • *****
  • Posts: 6893
  • "It's like hunting cows"
Re: General Discussion
« Reply #6670 on: February 08, 2016, 01:03:36 PM »
What about free characters leaving with low disposition?

I think that happens in the Char.next_day() method.
Like what we're doing?

Offline DarkTl

  • Hero Member
  • *****
  • Posts: 4737
Re: General Discussion
« Reply #6671 on: February 10, 2016, 02:14:04 AM »
For some reason I don't see stripper job available, even for slaves which don't have any restrictions.

Offline DarkTl

  • Hero Member
  • *****
  • Posts: 4737
Re: General Discussion
« Reply #6672 on: February 10, 2016, 04:50:28 AM »
Service jobs are less ready for my lines than I thought. For a start some of them have their own check_occupation, and some don't. At the same time we have
Quote
    class ServiceJob(NewStyleJob):
        """The class that solves Bartending, Waitressing and Cleaning.
       
        TODO: Rewrite to work with SimPy! *Or this actually should prolly be split into three Jobs...
        """
        def __init__(self):
            """
            This is meant to pick a job that makes most sense out if Cleaning, Service and Bartending
            """
which has its own check_occupation.

Looks like you will need to clean service jobs a bit to make it as understandable and clear as whore and stripper parts.

Offline Xela

  • Global Moderator
  • *****
  • Posts: 6893
  • "It's like hunting cows"
Re: General Discussion
« Reply #6673 on: February 10, 2016, 08:50:39 AM »
For some reason I don't see stripper job available, even for slaves which don't have any restrictions.

I'll take a look...

Service jobs are less ready for my lines than I thought. For a start some of them have their own check_occupation, and some don't. At the same time we have which has its own check_occupation.

Looks like you will need to clean service jobs a bit to make it as understandable and clear as whore and stripper parts.

It will require new code practices, I'll prolly structure it as a SimPy Resource Process on request. They would have to be split I think, we'll see how it pens out...

===>>
We need to think about meaningful upgrades/matron mods/events for all jobs.

I am still hacking the interface one frame at a time due to lack of time but it is slowly moving forwards, I'll push a number of small fixes tonight/tomorrow.
Like what we're doing?

Offline DarkTl

  • Hero Member
  • *****
  • Posts: 4737
Re: General Discussion
« Reply #6674 on: February 10, 2016, 11:59:24 AM »
We used to have upgrades. Not the best ones, but not the worst ones either, they would be a good food for thought. Atm I don't even see their tracks in the code.