Search found 2 matches

by RoadhammerGaming
Mon Feb 19, 2018 1:48 pm
Forum: Support and Development
Topic: dual for loop instance error
Replies: 2
Views: 1931

Re: dual for loop instance error

Hi, I am trying to compare the x and y positions of 2 instances to check for a collision, in my project I may have any number of instances of object enemy and object weapon, so I thought I could check for this by using a nested for loop, this is my code: There is no nested loop in the code you post...
by RoadhammerGaming
Mon Feb 19, 2018 5:16 am
Forum: Support and Development
Topic: dual for loop instance error
Replies: 2
Views: 1931

dual for loop instance error

Hi, I am trying to compare the x and y positions of 2 instances to check for a collision, in my project I may have any number of instances of object enemy and object weapon, so I thought I could check for this by using a nested for loop, this is my code: for j = #enemy, 1, -1 do local oE = enemy[j] ...