Weird hotspot problem

Bugs will be moved here once resolved.

Post » Thu Feb 07, 2013 10:19 pm

Link to .capx file (required!):
https://dl.dropbox.com/u/7765312/Hotspotglitch/Hotspotglitch.capx

Steps to reproduce:
1. Go into the .capx
2. Check out the objects animations that's in the .capx
3. Notice the hotspot X value is 25 on both frames (which are both the same frames, just recoloured), BUT the hotspot ICON on the image is different for each frame!

Here's the first frame
https://dl.dropbox.com/u/7765312/Hotspotglitch/gl1.png

Here's the second, recoloured frame
https://dl.dropbox.com/u/7765312/Hotspotglitch/gl2.png

Here's the previous two images blended together to show the difference of the hotspot.
https://dl.dropbox.com/u/7765312/Hotspotglitch/gl3.png

Observed result:
Hotspot is lying to me!

Expected result:
Hotspot to be placed correctly according to the number given.

Operating system & service pack:
Windows 7 Home Edition 64 bit

Construct 2 version:
[R117]

Not quite sure how this happened, was loading images in and they are all same size and I typed in numbers for the hotspots and I noticed ingame that one of the images was mis-aligned. I checked the images hotspots and they were all the same, so I just tested the game again and still this random frame was incorrectly aligned. So I checked again and realised the actual image of the hotspot icon in the editor is actually a pixel along EVEN THOUGH the Hotspots X position is the same! I bet you a fiver that it's something to do with float numbers and it's getting rounded.
Thank you for your time!

Edit: I should also note that this has happened to me twice before with different sized images. I notice that the numbers are correct but the character is a pixel out of place... iirc just moving the hotspot fixes it's alignment I think.Jase002013-02-07 22:21:43
B
45
S
19
G
10
Posts: 562
Reputation: 9,543

Post » Fri Feb 08, 2013 1:48 pm

Your .capx only has one animation frame; I tried duplicating that frame, but the origin displayed correctly and the same on both frames. Can you provide a .capx that reproduces this issue?
Scirra Founder
B
359
S
214
G
72
Posts: 22,949
Reputation: 178,544

Post » Sat Feb 09, 2013 1:47 am

Oh woops. I wasn't very specific with the instructions :O
I've tidied the .capx up a bit. I had the two seperate animations inside a folder, I should have pointed out that each frame is actually in a different animation each, but now it should be more apparent when looking in the .capx.
I also quickly added events to show that it actually affects the objects hotspot ingame (Running the capx will show it going between each animation and you can notice it shifts a pixel sideways) And still, the hotspot values are both 25 even though the image of the hotspot icon shows otherwise ;o

https://dl.dropbox.com/u/7765312/Hotspotglitch/Hotspotglitch.capxJase002013-02-09 01:47:42
B
45
S
19
G
10
Posts: 562
Reputation: 9,543

Post » Mon Feb 11, 2013 6:48 pm

Should be fixed in the next build. The second image really has its origin at an X position something like 25.99998. The problem was just that the origin was drawn at a position rounded to nearest, but the controls at the top would display it rounded down. So it was only a visual error with what the position controls at the top displayed.
Scirra Founder
B
359
S
214
G
72
Posts: 22,949
Reputation: 178,544


Return to Closed bugs

Who is online

Users browsing this forum: No registered users and 4 guests