1
Room Resolution and Background Stretching in GameMaker
Post Flair (click to view more posts with a particular flair)
Post Body
Hello, my issue is as follows: (GameMaker 1.4.9999 Studio)
Basically I'm to prevent stretching of the background image in lesser resolution rooms, the first room limits the display resolution to 960x240 and the second room limits the display resolution to 320x240, however it happens like this no matter what I do. The background image of the lesser resolution room stretches.
I have tried with if statements to check the room we're in(in an object and placed the object in the room), but to no avail, I've even tried views but they do the same thing(stretching the second background image) and I still had to use an object to make the game fullscreen.
// This reads the variables stored in the config file.
ini_open("config.ini");
set = ini_read_real("resolution","set",0);
width = ini_read_real("resolution","width",1280);
height = ini_read_real("resolution","height",720);
full = ini_read_real("resolution","full",0);
ini_close();
// Declare the maximum resolution you want to allow.
if(room==village) {
max_width = 960;
max_height = 240;
}
if(room==hospital_entrance) {
max_width = 320;
max_height = 240;
}
window_set_fullscreen(true);
Thanks in advance for any attempts to help.
Author
Account Strength
100%
Account Age
12 years
Verified Email
Yes
Verified Flair
No
Total Karma
23,887
Link Karma
5,605
Comment Karma
17,565
Profile updated: 3 days ago
Posts updated: 8 months ago
Subreddit
Post Details
We try to extract some basic information from the post title. This is not
always successful or accurate, please use your best judgement and compare
these values to the post title and body for confirmation.
- Posted
- 6 years ago
- Reddit URL
- View post on reddit.com
- External URL
- reddit.com/r/gamemaker/c...