I’m not sure what you mean, so here is the part from my script - nothing spectacular here:
What I did now was building an Obstacle along the left side of the screen (that the player sprite is not supposed to reach) and freeze the game the moment it is in collision with player. from this freeze I can go to debugger and look at my players variables, and they state (as far as I understand them) that there is no collision between player and my new box:
That’s the exact frame of the freeze
The right corner of the white line where the collision box ends is exactly at x=930px
And the debugger says:
{
“x”: 730,
“y”: 1510.815074496056,
[…]
“vertices”: [
[
730,
1510.815074496056
],
[
930,
1510.815074496056
],
[
930,
1710.815074496056
],
[
730,
1710.815074496056
]
],
“edges”: [
[
200,
0
],
[
0,
200
],
[
-200,
0
],
[
0,
-200
]
],
“center”: [
942.1735319894829,
1610.815074496056
]
}
],
“hitBoxesDirty”: false,
“aabb”: {
“min”: [
730,
1510.815074496056
],
“max”: [
930,
1710.815074496056
]
},
[…]
“owner”: “[Removed from the debugger]”,
“_activated”: true,
“name”: “Draggable”,
“type”: “DraggableBehavior::Draggable”,
“_nameId”: 2,
“_draggedByDraggableManager”: {
“_draggingSomething”: true,
“_draggableBehavior”: “[Circular ~.payload._sceneStack._stack.0._instances.items.Player.0._behaviors.0]”,
“_xOffset”: 96.79228746713409,
“_yOffset”: 82.73444347063969,
“leftPressedLastFrame”: true
}
},
{
“owner”: “[Removed from the debugger]”,
“_activated”: true,
“name”: “StayOnScreen”,
“type”: “StayOnScreen::StayOnScreen”,
“_nameId”: 3,
“_runtimeScene”: “[Removed from the debugger]”,
“_onceTriggers”: {
“_onceTriggers”: {},
“_lastFrameOnceTrigger”: {}
},
“_behaviorData”: {
“MarginTop”: 1500,
“MarginBottom”: 200,
“MarginLeft”: 190,
“MarginRight”: 350
}
}
],
“name”: “Player”,
“type”: “Sprite”,
“_nameId”: 1,
“id”: 1,
“_runtimeScene”: “[Removed from the debugger]”,
“hitBoxes”: [
{
“vertices”: [
[
730,
1510.815074496056
],
[
930,
1510.815074496056
],
[
930,
1710.815074496056
],
[
730,
1710.815074496056
]
],
“edges”: [
[
200,
0
],
[
0,
200
],
[
-200,
0
],
[
0,
-200
]
],
“center”: [
942.1735319894829,
1610.815074496056
]
}
],
[…]
I removed a lot of Data - still to much left, but there are the X-coordinates for my player readable. Everything seems fine, except the coordinates for “center” which say x=942. That is way left of what the image says. So for me it looks as if the center gets dragged onwards with the mouse.
Sorry for the long post…