i do really struggle with my homing missiles. but by whole project is quite complicated.
i have a family called all_chars with the four players in it p1_ship, p2_ship, p3... they all have an instance variable stored called "player" and the value of their player.
i now have a power up which should spawn a homing missile. i tried every f*** thing and didn't get it to work.
i stored the UID of the player who spawned the missile and let it chase the family all_chars for target which members dont have the same instance variable.
i tried to do it with the UID. something like
missile has target
missile.turret.targetUID not equals missile.originUID -> unacquire target.
i even tried it with for-loops, checked every player if he has the same instance variable as the missile and then acquired/unacquired the target.
how can i except players out of a family from the target objects.
problem is, my missile keeps chasing the wrong players and keeps exploding the wrong players.
I'd be veeeeeery happy about a sample capx of an advanced sample capx of a good working homing missile.
im afraid i can't share a capx because the scirra site is blocked from the content filter due to "games"
cheers!
phil