Changing Object to blank text causes size to be infinity

Use this template to make awesome bug reports:

Your username: Awesome_E

What kind of device are you using?: iPad Air 4, Hopscotch 3.49.0, Player 2.0.2

1 sentence description of the problem: The title – I changed an object from a character to a text, and set text and image wouldn’t work because the size was zero.

Steps that the Hopscotch team can take to reproduce my problem every time:

  1. Create project with an object
  2. Change that object to a blank text
  3. Set text to “test” on game start (might work better if you set text to size as a %, so you can see that it’s Infinity)
  4. Play project

I expected this to happen: It says “test”

But instead this happened: It doesn’t show because size is Infinity (though HS treats it like zero)

if you set text to a trait at the beginning, it shows: width = 0, height = 99, size % = infinity
https://files.catbox.moe/fmt66j.mp4

13 Likes

This happens to me when I use my custom glitch block
It makes the text look glitchy, it works normally, but not for when the original object is an image

4 Likes

Use this template to make awesome bug reports:

**Your username: bobinny

What kind of device are you using?: IPhone 12,8

1 sentence description of the problem (I was doing adding set text to my blank text, and then the text object was invisible happened):

Steps that the Hopscotch team can take to reproduce my problem every time:
1.Create a sprite, make it a blank text object
2. Add a set text block. Make the set text block to anything but blank

I expected this to happen:
Be in the center of the screen
But instead this happened:
No text.
Here’s a sweet screenshot:
image

5 Likes

Thanks for reporting these. It looks like this might be a bug in the app.

  • I did a test, and when I look in the project file (json), a default text object has width = 73.5, height = 55.
  • The text object that was formerly a default character (Gorilla) had width = 0, height = 110.
  • Gorilla has default width = 150, height = 150.
1 Like

It sounds to me like it had some division by zero in the code of hopscotch and ended up at invenaty.

1 Like

I just made a video showing this bug in detail.

1 Like

width=0, in blank text
100÷width = apparently Infinity

2 Likes