#Multiple card effects *Unsolved*

6 messages · Page 1 of 1 (latest)

spring sapphire
#

Maybe each cards holds an array of their effects ex. [burn, shock]
Then instead of running the switch code once you for loop it the length of the array

ionic shore
#

I tried that but the loop never went through the array. I can try again but I’m not sure

ionic shore
#

tried making the effects into an array and looping through them but none of the effects are applying

ionic shore
#

my array length is saying 0. in the parent object for the cards i set the effects to an empty array and then set it to another array from my construct. is there a better way to do this?

ionic shore
#

Multiple card effects Unsolved

spring sapphire
#

You could also just copy paste the code 2 or 3 times and have 3 variables to store the effects if you just need it done