Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Studio Chat / [SOLVED] AGK stretches the sprites

Author
Message
Parzival
2
Years of Service
User Offline
Joined: 1st May 2021
Playing: AppGameKit Studio
Posted: 27th Dec 2021 03:50
hello friends!
I have a problem. AGk is stretching the sprites, which causes the collision box to not fit the sprite on the screen.
my original sprite, the one on the left. And on the right side, the sprite that is seen on the screen when I press play.

the code I use for the screen is:


how can I fix it?

The author of this post has marked a post as an answer.

Go to answer

Scraggle
Moderator
20
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 27th Dec 2021 08:35
That isn't enough code to see what you're doing wrong. You'll need to provide the sprite creation and display if we are going to be able to help
Parzival
2
Years of Service
User Offline
Joined: 1st May 2021
Playing: AppGameKit Studio
Posted: 28th Dec 2021 03:31
This post has been marked by the post author as the answer.
this is the code in player.agc



then , I create the player in main.agc

Scraggle
Moderator
20
Years of Service
User Offline
Joined: 10th Jul 2003
Location: Yorkshire
Posted: 28th Dec 2021 12:06 Edited at: 28th Dec 2021 12:07
There's a very simple solution to your problem:
You are creating the sprite before setting the virtual resolution. Setting the resolution needs to be one of the first things you do - certainly before creating any sprites.

Login to post a reply

Server time is: 2024-04-18 16:36:35
Your offset time is: 2024-04-18 16:36:35