Playmaker Forum
PlayMaker Help & Tips => PlayMaker Help => Topic started by: nightcorelv on June 08, 2019, 10:01:15 AM
-
Arraylist Get Next index value seems broken at 2019.1.5, any fix?
-
Hi,
what is the error or wrong behaviour you get?
Bye,
Jean
-
Hi,
what is the error or wrong behaviour you get?
Bye,
Jean
here is my setup
(https://i.imgur.com/u7MGoEA.png)
i loop through a list, get the index, then store the index into a variable, but it seems not works at all
-
Hi.
Maybe add a variable ;)
On type add type and in result add a variable to receive whats in the array :)
if you don't need a variable, only a index to loop.
Then you should use Iterate action (on Ecosystem (https://hutonggames.fogbugz.com/default.asp?W1181)) instead
-
Hi,
- can you show me the gameobject 'BlendManager" and its arrayList component?
- you are not implementing the failure event, this should always be set, so that when something goes wrong, you know about it.
- if you are using this action more than once in your fsm lifetime, you need to use the Reset property, which accepts a boolean variable that you set to true before entering the state for the first time, it reset the internal counters.
Bye,
Jean
-
Hi,
- can you show me the gameobject 'BlendManager" and its arrayList component?
- you are not implementing the failure event, this should always be set, so that when something goes wrong, you know about it.
- if you are using this action more than once in your fsm lifetime, you need to use the Reset property, which accepts a boolean variable that you set to true before entering the state for the first time, it reset the internal counters.
Bye,
Jean
The problem has been solved, thanks djaydino.
it works fine when i add a variable to store the value
but if i remove it and let it null, the action will skip looping through and jump to finnished event
in my opinion, this is more like a bug
it’s not always necessary need to get value from list, sometimes people just want to
loop through and get index from list
-
Hi.
If you do not need data from an array its might be better to use Iterate action instead.
if it needs to be the same length as array, you can get array length and use that value on the iterate.