Coming soon - Get a detailed view of why an account is flagged as spam!
view details

This post has been de-listed

It is no longer included in search results and normal feeds (front page, hot posts, subreddit posts, etc). It remains visible only via the author's post history.

4
Trying to create a list of assertions in the inspector. Feel like I'm going crazy.
Post Flair (click to view more posts with a particular flair)
Post Body

So, like the title says: I'm trying to create a list of conditions whereupon something happens. For example, I have a bool somewhere else for if the player is close to an enemy. I'd like to be able to pass that bool into this list, serialized in such a way that I can check it against an expected condition. I have a generic function that would check a list of passed bools against their respective expected condition, but I am having trouble of thinking of a way to add a collection of conditions to the List.

The reason I'm trying to do it this way is that the conditions may change from case to case. So for example, one may evaluate to true if the player is close and is mid attack. Another may evaluate to true only if the player is not jumping. Even if there's only one condition to check, I need to be able to check it against an expected value, and I'd like to be able to grab an existing bool that knows the state of that condition, and I'd like to be able to keep this class generic so that I can easily modify different instances of the object to evaluate different sets of conditions.

Any thoughts on how to approach this?

Author
Account Strength
100%
Account Age
8 years
Verified Email
Yes
Verified Flair
No
Total Karma
49,426
Link Karma
2,005
Comment Karma
47,076
Profile updated: 2 days ago
Posts updated: 4 months ago

Subreddit

Post Details

We try to extract some basic information from the post title. This is not always successful or accurate, please use your best judgement and compare these values to the post title and body for confirmation.
Posted
2 years ago