This function changes (or sets) the width of any room in your game except the current one.
room_set_width(index, w);
| Argument | Type | Description | 
|---|---|---|
| index | Room Asset | The room to set the width of. | 
| w | Real | The new width of the room in pixels. | 
N/A
global.myroom = room_add();
room_set_width(global.myroom, 640);
room_set_height(global.myroom, 480);
room_set_persistent(global.myroom, false);
This will create a new room and store its index in the variable global.myroom. It will then set its width to 640 pixels, its height to 480 pixels and its persistence to false.