Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement a way for activities to have requirements before they can start #3

Open
xetra11 opened this issue Aug 7, 2022 · 0 comments
Assignees
Labels

Comments

@xetra11
Copy link
Collaborator

xetra11 commented Aug 7, 2022

For now the system works like that:

  • An urge arises and becomes top priority for an actor
  • The activity that matches that urge is being executed for the specified duration

So for now it works like that an activity is immediately executed. However we want some kind of requirement to be fulfilled before that can happen.

Imagine the following:

  • Actor Foo wants to wants to eat something urge(eat) == 100
  • The eating activity requires food to be available. Either in reach or in an inventory. How this implemented is not important.
  • Unless something satisfies the requirement for eating nothing happens.
  • There should be a give_up countdown to avert the case where an activity runs forever if the requirement is never fulfilled.
  • Now it is possible to fullfill that requirement by simply "remove" it from the requirements list.

So the Goulash consumer would for example read from the engine API that an actor's activity is requiring "food". The consumer's logic can then, for instance move the actor to a food resource. As soon as the food resource is reached, the API consumer can remove the requirement which finally starts the activity as intended.

@xetra11 xetra11 moved this to 🆕 New in Release 1.0 Aug 7, 2022
@xetra11 xetra11 self-assigned this Aug 9, 2022
@xetra11 xetra11 moved this from 🆕 New to 🔖 Ready in Release 1.0 Aug 9, 2022
@xetra11 xetra11 removed their assignment Aug 9, 2022
@xetra11 xetra11 self-assigned this Aug 24, 2022
@xetra11 xetra11 moved this from 🔖 Ready to 🏗 In progress in Release 1.0 Aug 24, 2022
xetra11 added a commit that referenced this issue Aug 24, 2022
xetra11 added a commit that referenced this issue Aug 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: 🏗 In progress
Development

No branches or pull requests

1 participant