How would one go about creating and maintaining a line between two objects on different layers with different parallax scrolling values?
Currently I'm using code:
System: Every tick -> LineSprite : Set position to Object1 (image point 0)
System : Every tick ->
LineSprite set width to distance(Object1.X, Object1.Y, Object2.X, Object2.Y)
LineSprite set angle to angle(Object1.X, Object1.Y, Object2.X, Object2.Y) degrees
Object 1 and LineSprite are on layer1 (parallax 100,100) while Object2 resides on layer0 (parallax 50,50) When the viewport scrolls the Object1 end of the line stays where supposed to but the Object2 end doesn't. Any ideas how to get this to work and how to adjust the line angle/width to get it to attach to correct Object2 position (even when the layout is scrolling)? Thanks!