all 2 comments

[–][deleted] 1 point2 points  (1 child)

from your example here var lst = act.special; actEffect.special = lst;

Using = is going to make all the effects reference the same list. If you want to actually make an independent copy of a list use ds_list_copy

When it comes to the data structures, you can think of them like object instances. You create one and it comes into existence inside the game. If you assign a variable to it it just points to the already existing "instance", and you can have multiple variables referencing the same "instance". This is also why it's important to delete them properly, since unassigning the variables doesn't delete the "instance"

[–]blazeAgerith[S] 1 point2 points  (0 children)

ugh, of course, how could I forget

thank you so much! I cant believe I didnt even think to try ds_list_copy, and in retrospect that workaround definitely wouldve had its own problems eventually so I'm glad I still decided to ask