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

New Feature: Is Active and Is Inactive commands for game objects #1006

Open
wants to merge 3 commits into
base: develop
Choose a base branch
from

Conversation

Arylos07
Copy link
Contributor

Description

Really simple. Added Is Active and Is Inactive commands that checks if a game object is active/inactive. Also has additional parameters on if it will ignore the parent (default) or not.

If the parent can be ignored, these commands use gameObject.activeSelf.
If the parent is included (ignoreParent = false), these commands use gameObject.activeInHierarchy instead.

What is the current behavior?

Currently, there is no way to check if an object is active/inactive in Fungus. You can only set its state.

What is the new behavior?

  • Add the necessary command.
  • If you want to check if an object is inactive, you can set the state to false and the command will return true if the object is disabled
  • Define your flow depending on what you want. They are conditional checks so they will return true/false and follow the flow afterwards.

Important Notes

  • My change require modifcations or additions to documentation
  • My change modifies the workflow/editing of flowcharts/blocks/commands etc.

Other information

Finally, a pull request that does not reference that accursed audio lerp fix.

Screenshot_40

This checks if a target object is active with additional checks of if the object is inactive if the parent is as well.

Debated on using 2 different commands, but I think one with a toggle is good. Someone clean up the tooltips if they are not clear enough.
Decided to separate Is Active so now there's Is Active and Is Inactive.
@stevehalliwell stevehalliwell added this to the 3.14 milestone Aug 21, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants