Image sprite sizes returning to default image size when website is closed

86 views
Skip to first unread message

mrtreeface1

unread,
Aug 26, 2015, 2:51:36 AM8/26/15
to MIT App Inventor Forum
As said in the title, i am changing the size of my image sprites to create a wall/maze effect however each time i close the website the sprites all return to the original size o of the image, any solutions?

Lieven Van Parys

unread,
Aug 26, 2015, 5:43:10 AM8/26/15
to MIT App Inventor Forum
I have this problem too...

SteveJG

unread,
Aug 26, 2015, 7:58:25 AM8/26/15
to MIT App Inventor Forum
Neither of you showed an image of your sprites.   How did you size the sprites?    Did you set the H and W by dragging on the sprite or did you set the H and W using blocks or the Properties of the sprite on the Designer screen.

How large are the original sprite images  H and W in pixels (stored probably in Media)?     and what dimensions are you using on your Canvas screen?

To get help with this issue, you need to provide more information.  A screen capture of your Designer and settings or an aia would help to understand the issue you are describing.


@  mrtreeface1    You say " each time i close the website " ...what does this mean?   If you are using sprites, you are using them on the Canvas surely.  Do you mean change screens  or something else?

Regards,
Steve

Lieven Van Parys

unread,
Aug 27, 2015, 4:22:24 AM8/27/15
to MIT App Inventor Forum
Here you see an example in the designer. The H and W are placed in the properties. You see the original 'boy Arthur' and a rectangle in stead of the smaller 'Arthur'.
Greetings, Lieven
Knipsel.JPG

SteveJG

unread,
Aug 27, 2015, 8:35:42 AM8/27/15
to mitappinv...@googlegroups.com
@ Lieven   You have a H of  16  and   a W of 20 .    How large is the arthurkleinr.png image that is in Media?     If the dimensions of arthurkleinr.png are significantly different from 16x20 App Inventor might be having trouble shrinking the image to the smaller size.   

I suggest two things:   1) make the arthurkleiner.png image that is in Media closer to 16x20    and test.  If resizing arthurkleiner.png does not  fix the issue, then
in your Screen1.Initialize        set arthur.Width to  20     and    set arthur.Height to 20  .

What happens?

You might look at this thread     https://groups.google.com/forum/#!category-topic/mitappinventortest/jLy5sE0BpMI                       which seems to be a similar issue.

Regards,
Steve

Lieven Van Parys

unread,
Aug 27, 2015, 10:07:44 AM8/27/15
to MIT App Inventor Forum
Hello Steve,
The original size of the image was (only)50x60 and it worked during months. Only the last week(s?) I had this problem. Now I made the  original 'Arthur' image smaller 25x30. Than I changed H and W. But when I close and reopen App Inventor it becomes bigger (25x30)than the 16H and 20W. 
greetings,
Lieven
Knipsel2.JPG

SteveJG

unread,
Aug 27, 2015, 10:18:24 AM8/27/15
to mitappinv...@googlegroups.com
Change the 'original' image to 16 x 20 ..   I understand what you used to do worked, however you are now working with App Inventor 145 which works differently and has some bugs related to images.   Please try using an exact size arthur image with proportions of compatible with 16 x 20 ... your revised 'original' is 25 x 30 so to fit into yur 16 x 20 rectangle, the original has to be 32 x 40   or better yet, exactly  16 x 20.         Using those proportions should fill the rectangle box.  You may have to use Paint to resize the boy's image.

Try again.

... and let us know what happens please  :)

Lieven Van Parys

unread,
Aug 27, 2015, 11:00:33 AM8/27/15
to MIT App Inventor Forum
I tried with 32x40 and it did not work. It worked with 16x20. (I use Gimp ;-))
Greetings,
Lieven
Knipsel3.JPG
Reply all
Reply to author
Forward
0 new messages