for some reason, my range indicator does not appear even though when i look into the debugger it says it is not hidden and the coordinates are supposed to be correct as it’s supposed to follow the selected turretbase.
oh yeah, here’s game link:
Is there an indicator for each turret? Are you linking them. If they’re linked are you picking the one linked to the turret.
In your loop
You’re hiding all of the objects if the value is false and showing if true. So, if the last one is false it will hide them all. It might show it but then hide them.
nah, there’s supposed to only be one that gets moved to the selected turret when clicked. funny, cuz the placement availability works perfectly fine
If there’s only 1 selected TurretBase then I think the issue is it’s being hidden and shown and hidden again unless it was the last object in the list. Say there are 5 turretBase objects and the 3rd is set to selected = true
This is how the object visibility would be
Hide
Hide
Show
Hide
Hide
If there’s only 1 object that’s set to true then you wouldn’t need the for each object.
Hide indicator
selected of TurretBase is true
… Show indicator
I don’t know why you’re picking the nearest TuttetBase within the for each instance. Since only 1 object is picked at a time, it would always be the closest.
oh i figured out the problem so basically, i was setting the size of the range indicator to the range of the variable in each turret base divided by 32 to account for the unscaled size but it would divide before a turret base was even created, making it 0 (i think)




