Move to Point in Screen Coordinates Flawed/Broken/Wrong



  • If you have the camera/view/screen set to follow an object, Move to Point Screen Coordinates fixates on the position the target point was in world coordinates at the moment it's called.

    It should be using Screen Coordinates, all the time, not just a virtualisation of world coordinates at the moment of evocation.


  • Admin

    What do you mean? Can you post some screenshots?



  • @Hamed

    I don't think screen shots can help, because you can't see anything, which is the problem.

    When moving an object according to Screen Space, it should move to the position of the screen that it's being told to move towards. For this example, let's imagine the upper middle of the screen, in hyperPad units. Let's say that's x: 16, y 20 (4 units below the top edge, middle of the x range).

    If I tell an object from within the game world to move to this location, over a duration of 2 seconds, it should. Whilst the object is making this transition in location, regardless of where the Screen View moves within the game world, it should always be aiming for this position in the Screen View.

    This is not what's happening.

    Instead, at the moment the Move To Screen Coordinates Behaviour is called, the behaviour checks for the world location of that Screen location, and then uses that world location as the target destination. So if the Screen view moves, the moving object is no longer heading to the determined Screen Position, it's heading for where that Screen Position previously was in the world coordinate space.

    Assumes:

    Screen space is that space we can see on the iPad, it's the view's bounds, expressed in units (or percentages) from the left edge of the device's screen, to the right, and up and down.

    When using a Screen Follow "behaviour" on an object, it's acting like a camera in the world, moving the view of the Screen through the world with its subject, the target object.

    Move To Screen Coordinates is not respecting this, it's determining the world position of the targeted screen location at the time of command issuance.