Soegoez
(Soegoez)
May 7, 2024, 5:05pm
1
Hey, so I made an array list, and I want to check if the index will have the same value or not
So for example, if the index(0) value is indeed DoubleJump, then I want to do this Double Jump Skill function
So basically i want the foreach loop to search for an index that have the specific value I wanted and if it’s true then it will do the funciton
1 Like
You don’t even need a loop. Arrays have the ‘contains’ and ‘find’ nodes, which do exactly this.
1 Like
Soegoez
(Soegoez)
May 7, 2024, 5:12pm
3
Oh LOL, found it. Turns out it was as simple as that. Thanks!
1 Like
Soegoez
(Soegoez)
May 7, 2024, 5:27pm
4
hey, another quick question, how do i add only one item in the array?
I did this, and I think the Skill Row Name ID just fill up all the array list
Because I tried to print the find Array value, and when it doesn’t find it it’s result in -1 (which is correct)
but somehow when it finds the value, it prints in 5 (the total index of my array)
system
(system)
Closed
June 6, 2024, 6:38pm
6
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.