Is there a way to output an obj list with value filter?

This forum is the place to learn about and discuss ADRIFT 5. Feel free to mention any bugs you find here, but please also add these to the Bugs & Enhancements list.

Please also refer to the ADRIFT 5 Wiki for more information.
Post Reply
User avatar
DazaKiwi
Posts: 780
Joined: Thu Oct 21, 2010 10:05 am
Points: 61
Location: New Zealand

Is there a way to output an obj list with value filter?

Post by DazaKiwi »

What i want to do is output/list all objects that has a property with its integer value = 0

The line below doesn't work of course but gives you an idea of what i want to be able to do;
%Player%.Location.Objects.Property(0).List

If this is not possible i can think of a work around using selected property type but for what i want but it would be good to know if it is possible if the property is an integer and you can somehow specify that as a filter?
saabie
Posts: 1024
Joined: Fri Aug 12, 2011 3:07 am
Points: 50
Location: Adelaide, South Australia

Re: Is there a way to output an obj list with value filter?

Post by saabie »

I tried several different methods of filtering by an integer property but I couldn't even get it to list the values, the only thing that works is 'Sum'.
You will need to use another method such as sending the %Player%.Location.Objects list to an executed task %object% parameter and checking each one with a restriction.
If the property value ever changes then you will need a separate state rather than not selecting it when it should be zero.
The state must be set to 'Zero' or 'NotZero' whenever the value changes.

An easier method would be to add each object to a group whenever the property is set to 0, and remove it if set to another value.
This would be much easier to list as you only need to do "ZeroGroup.List".
User avatar
DazaKiwi
Posts: 780
Joined: Thu Oct 21, 2010 10:05 am
Points: 61
Location: New Zealand

Re: Is there a way to output an obj list with value filter?

Post by DazaKiwi »

Okay thanks for the suggestions, its amazing what work arounds can make something work with Adrift.
Post Reply