Welcome Guest ( Log In | Register )

[ Big| Medium| Small] -



Post new topic Reply to topic  [ 40 posts ]  Go to page 1, 2  Next
BlueScope
  Sun Apr 29, 2007 2:59 am
The Third Man
[ranting about everything]
User avatar

Location: Germany
Custom Resolution Script
v0.82


Another script of mine... some screens of other people's games, ideas, and of course, the work on my Lufia graphic set got me to this...


Introduction

Most of us know that RMXP's default resolution is 640x480, and we all know that this doesn't fit every game... Some games need lesser resolution, some games need more than the little default space. Regardless what's the case, Selwyn's script does it, right? Well, not quite... with Selwyn's nice script, you can change your game's aspects, but not the tile size. It's also a pain in the ass to adjust the character's movement settings, and of course, getting all this set up well together is impossible for non-experienced scripters.
My intention with this script was to provide you guys with a plug-and-play tool to change the game's resolution, and the outcome is a very powerful script in my honest opinion... along with the screen resolution and the tileset size, it changes the character's movement speed, the step distance to keep the movement aspects, and a few more things.


Features
  • In theory any resolution you want (only hardware-limited)
  • Easy Setup - You name the resolution, the script does anything else for you
  • Changes the tile size relative to the resolution
  • Changes the character movement speed and step distance relative to the resolution
  • The Player's x and y coordinates are adjusted to the resolution

Screenshots

http://img80.imageshack.us/img80/5390/resolution1wg0.th.png[/img] http://img106.imageshack.us/img106/9762/reslufiaho9.th.png[/img]


Demo

Custom Resolution Script Demo v0.82
Hosted on Box.net, 0.46MB


Script and Resources

Tilemap Class Rewrite & Window Resolution Script
Selwyn's Window Resolution Script
[/spoiler]
Custom Resolution Script
Plug-Ins
[/spoiler]

Instructions

First, you need to get both required, external scripts ready, which are SephirothSpawn's Tilemap Class Rewrite and Selwyn's Resolution Script.
While you can simply copy Seph's script in a new script above Main and below Game_Map, you need some more steps to integrate Selwyn's script. Refer to the instructions in his thread for that.
If you have both scripts integrated, insert another script above Main, below the two required one and Game_Player, and copy the Custom Resolution Script into it. Well, designed to be plug-and-play, that's basically it, though you of course have to choose your desired resolution. Refer to the top of the Custiom Resolution Script for the Setup module, where you can find the following line:
Expand to see the code.

Note the two bolded numbers that equal RMXP's half default screen width (320) and height (240). You may change these two numbers to whatever resolution you desire, but make sure you don't try creepy stuff. I'm not responsible for anything bad resulting from resolutions other than 320x240, 640x480, 800x600, 1024x768, or anything bad resulting from the named resolutions because of your computer settings. Other resolutions should be fine, too, but I didn't test them, so I won't guarantee for them.


Glitchfinder's AddOn

If you experience problems with my basic version or the two priority layers aren't enough, you might check out Glitch's post, which includes an edited version of my script, plus a modified version of Selwyn's RPG::Cache module.

The easiest way is to remove what you put in from my post and insert everything from his into your project. Remember that you don't need the Display.dll anymore, which you should remove from your project then.

Also, please be aware that though i believe in Glitch and his statements, I haven't tested the script by myself. If you're in need of support, please also contact Glitchfinder, not me.


Frequently Asked Questions

Q: How do I use smaller or bigger tiles?
A: You use normal 32x32 tiles on normal 256x[32] tilesets, the script resizes these tiles for you. Custom tile size is planned for future versions.

Q: Is this script intended for a specific resolution?
A: Yes, 320x240 is the resolution this script works best with and was originally intended to be used with.

Q: What're the half trees doing there?
A: This bug occurs for tile priority settings above 2, so all tiles with priority 3, 4, or 5 won't be drawn. It's an error caused by Seph's Tilemap rewrite. Note that his script is only v0.9, and therefore not complete. I think it'll be fixed in the final version.

Q: Where can I get the display.dll? The link in Selwyn's thread is broken...
A: arevulopapo re-hosted the file, you can find this link further down in his thread.

Q: Why don't the charactersets get resized?
A: As you can use any characterset sizes you want to without any relation to the screen resolution or the tiles, such a feature is quite redundant.

Q: Who should I give credit for this?
A: Without SephirothSpawn's and Selwyn's scripts, this script wouldn't exist, so you need to give all three of us credit if you use this script. If you use any plugins, make sure you credit the authors of those, too.

Q: What are those Plugins?
A: It's simply a name I made up for the spoiler, it's unrelated to what a real 'plugin' would be for a game. Instead, it's just a script you place below the Custom Resolution Script to modify some defaults. For example, the Scene_Title plugin I provided centers the command window, regardless of the resolution you use.

Q: What do I have to do if I want to make my own plugin?
A: Just make sure you don't modify any of the three default scripts (Tilemap Rewrite, Window Resolution Script, or Custom Resolution Script) and only use the methods defined in the Setup module in your plugin. You should also alias as much as possible, as the plugin's purposes are to increase compatibility, at least.


ToDo-List

Until v1.0
  • Support for custom tile and tileset size (i.e. using smaller or larger tilesets instead of having the program resize the tiles)
Further Versions
  • Adjustable step distance (can be used for pixel movement, for example)

Compatibility
  • The Tilemap Class Rewrite modifies a method of Game_Map (aliased)
  • The Custom Resolution Script modifies several methods of Sprite_Character (aliased), Spriteset_Map (aliased), Game_Map, Game_Character, and Game_Player.
  • The Scene_Title Support Script modifies a method of Scene_Title.


Conclusion

So, this script is out in the open... now what to do with it? How about grabbing some sprites (like my newly submitted Lufia 2 graphics, which'll work great with a 320x240 resolution) and make a game with this script? Why not open up your desired script editor and write custom systems for this? And of course, why not help me with my To-Do list XD It's up to you, as long as you put it in good use! I hope you can work with this.


Credits

BlueScope ^_^
SephirothSpawn for the Tilemap Class Rewrite
Selwyn for the Window Resolution Script or the RPG::Cache module
Glitchfinder, if you're using his AddOn

_________________
Image

If you have a slightly positive memory of my Power Shift contest game,
you might be interested in this development screenshot...
More info about that soon!


Last edited by Guest on Wed Jul 23, 2008 1:23 pm, edited 1 time in total.

Top Top
 Profile  
 

Unrivaledneo
  Sun Apr 29, 2007 3:07 am
User avatar
Member

Location: The Sand Box...Agian
Think you could host the Display.dll file the link at his post is no longer there.
Edit Found it, was on the 2nd page, good script To bad does not work with my game.

_________________


Last edited by Unrivaledneo on Sun Apr 29, 2007 3:57 am, edited 1 time in total.

Top Top
 Profile  
 

Me(tm)
  Sun Apr 29, 2007 3:35 pm
User avatar
Member

Location: Delft, The Netherlands
I guess the Update Trandition Rectangle is not enlarged on a bigger resolution, right?

_________________
Image


Top Top
 Profile  
 

BlueScope
  Sun Apr 29, 2007 5:32 pm
The Third Man
[ranting about everything]
User avatar

Location: Germany
Well, the viewport's parts above the default 640x480 are shown in black no matter what, I don't have an idea why (the viewports are shown correctly). You can draw windows on the empty space without a problem, nevertheless, though, of course, this isn't what I'm going for...
If you have an idea on how I can fix that, please tell me... I haven't checked if the same occurs for Selwyn's script, though, which'd mean that this bug is caused by his resolution fix.

_________________
Image

If you have a slightly positive memory of my Power Shift contest game,
you might be interested in this development screenshot...
More info about that soon!


Top Top
 Profile  
 

Me(tm)
  Sun Apr 29, 2007 5:44 pm
User avatar
Member

Location: Delft, The Netherlands
Erm, Because the Graphics class' Viewport is in c coded? So you can't just fix it. Each time I see a new resolution script, I hope people have done it...

_________________
Image


Top Top
 Profile  
 

BlueScope
  Sun Apr 29, 2007 5:57 pm
The Third Man
[ranting about everything]
User avatar

Location: Germany
I see... I thought you couldn't do it the 'normal way'... mainly because I tried everything I could XD Thanks anyway, too bad there is no easy solution...

EDIT: Updated the script to v0.81... the only change is another aliased method, but no functionality added yet...

_________________
Image

If you have a slightly positive memory of my Power Shift contest game,
you might be interested in this development screenshot...
More info about that soon!


Last edited by BlueScope on Sun Apr 29, 2007 11:08 pm, edited 1 time in total.

Top Top
 Profile  
 

Taylor
  Sun Apr 29, 2007 11:42 pm
User avatar
So this script brings back the F5 function from RM2k/2k3? Press F5 to switch between double size/normal size.

I suppose it doesn't actually do the button toggling it, but the rest is the same?

...I would use this but then I'd need to reposition EVERY non-Scene_Map item. D: And back with older versions when I was going for 480x320 it was quite tedious. And a right pain. And did I mention tedious?
Battle elements were easy, it was the menu that was hard (and now that I'm using MOG Menus? x_x)

Yeah... too bad thier isn't a script that could half all graphic sizes and x and y positions (or similar e.g cx, cy) unless labled otherwise.

_________________
Image


Top Top
 Profile  
 

BlueScope
  Mon Apr 30, 2007 12:26 am
The Third Man
[ranting about everything]
User avatar

Location: Germany
Even if you would half all graphic's size, windows and other by-script drawn objects still wouldn't be halfed. I know it's a tedious process to script any scenes you need, but I'm not a fan of the default menus anyway... XD Well, maybe, since this script is out now, someone will do some menues for this... we have some very talented CMS guys in here, right?

_________________
Image

If you have a slightly positive memory of my Power Shift contest game,
you might be interested in this development screenshot...
More info about that soon!


Top Top
 Profile  
 

MysticTrunks
  Wed May 02, 2007 10:33 pm
User avatar
Member
Nice, but my resolution isn't changing well the game window anyway, any suggestions?

A screen
http://img177.imageshack.us/img177/1339/111to9.png[/IMG]


Last edited by MysticTrunks on Wed May 02, 2007 10:43 pm, edited 1 time in total.

Top Top
 Profile  
 

BlueScope
  Wed May 02, 2007 11:18 pm
The Third Man
[ranting about everything]
User avatar

Location: Germany
Looks like you disabled the auto-fullscreen... I'm unsure about what this script does if it's set to windowed mode, but I guess this is what happens... well, maybe you forgot the display.dll and included some kind of rescue method in Main... or there's another script interfering with it. It might also be hardware-caused, so best try it in a new project with no other scripts applied and see what happens there. Of course, make sure you follow the instructions correctly, especially Selwyn's, as his require the most work.

_________________
Image

If you have a slightly positive memory of my Power Shift contest game,
you might be interested in this development screenshot...
More info about that soon!


Top Top
 Profile  
 

BlueScope
  Wed May 16, 2007 12:57 am
The Third Man
[ranting about everything]
User avatar

Location: Germany
Let me bump this because of the simple reason that I added a demo of v0.82 for you to grab. Note that it includes a fix on the message window (which I also included in the script you can get from the first post) and and old man talking weird stuff ;) I think it's worth taking a look at.

_________________
Image

If you have a slightly positive memory of my Power Shift contest game,
you might be interested in this development screenshot...
More info about that soon!


Top Top
 Profile  
 

shadowfox
  Wed May 16, 2007 5:21 am
User avatar
Member
lol .. i like'd the little "break from reading all this text" xD

very nice script as well.

_________________
http://img354.imageshack.us/img354/1537/arasoibanneroz1.png[/img]


Top Top
 Profile  
 

arctrooper48
  Wed Jun 20, 2007 4:21 am
Still have December Santa Avatar.
User avatar
Member
Necro-bump-yeah

Hey Bluescope, do you have a copy of the display.dll file? The link to it is broken =[

EDIT: Problem Solved, read the FAQ.

_________________
Image

Content Hidden


Last edited by arctrooper48 on Wed Jun 20, 2007 4:38 am, edited 1 time in total.

Top Top
 Profile  
 

OmegaGroudon
  Wed Jun 20, 2007 4:39 am
Member
Hey...I downloaded the demo but it was just full screen!


Top Top
 Profile  
 

BlueScope
  Wed Jun 20, 2007 9:23 am
The Third Man
[ranting about everything]
User avatar

Location: Germany
Um, it definately wasn't... use PrintScreen (the key) while the game's running, and enter some drawing program to paste the screenshot. You can check the resolution there.

_________________
Image

If you have a slightly positive memory of my Power Shift contest game,
you might be interested in this development screenshot...
More info about that soon!


Top Top
 Profile  
 

Sovereign
  Thu Aug 09, 2007 5:14 am
Member
I have the same problem MysticTrunks has, and I'm confident that I followed Selwyn's instructions to the letter. In addition, I get an error after I try to start the game by selecting "New Game" from the title screen. Line 237 of your script, an "ArgumentError," then it says "bad value for size." Here's the line:

self.contents.font.size = Font.default_size * -Setup.variance

Any idea what's causing this?

EDIT: I've tried this with numerous resolutions, from 800x600 up to my native 1680x1050 (Not necessarily expecting it to work, but I get the same error regardless of the resolution I pick :P)

_________________
"Who the hell do they think they are? I report to the Prime Minister and even he's smart enough not to ask me what we do. Have you ever seen such a bunch of self-righteous, ass-covering prigs? They don't care what we do; they care what we get photographed doing. And how the hell could Bond be so stupid? I give him double-O status and he celebrates by shooting up an embassy. Is the man deranged? And where the hell is he? In the old days if an agent did something that embarrassing he'd have a good sense to defect. Christ, I miss the Cold War." ~M, Casino Royale


Top Top
 Profile  
 

BlueScope
  Thu Aug 09, 2007 11:19 pm
The Third Man
[ranting about everything]
User avatar

Location: Germany
I wonder if you tried out the demo... if it works there, it's a problem with your game... for example a script that changes the Font module (very unlikely), or version issues... you need v1.02 upwards to use this.

Also, for larger resolutions then 640x480, the screen will be black outside this area... noone's been able to fix this by now.

_________________
Image

If you have a slightly positive memory of my Power Shift contest game,
you might be interested in this development screenshot...
More info about that soon!


Top Top
 Profile  
 

MysticTrunks
  Fri Aug 17, 2007 8:43 am
User avatar
Member
This is great, all that needs to be fixed is the menu and font issues.


Top Top
 Profile  
 

gadula4
  Sun Sep 23, 2007 1:59 pm
Member
When I enter a building, it ocures error :(


Last edited by gadula4 on Sun Sep 23, 2007 2:05 pm, edited 1 time in total.

Top Top
 Profile  
 

Pyroxic
  Mon Sep 24, 2007 7:06 pm
Member
Could someone please explain those instructions better, I could not understand them really....I'm trying to set up the resolution to fit with gameboy advance's (240x160) and anything I try just messes my game up and I want the tiles to be 16x16 also o_O


Top Top
 Profile  
 

BlueScope
  Wed Sep 26, 2007 6:12 pm
The Third Man
[ranting about everything]
User avatar

Location: Germany
@gadula: Sorry for the late reply, didn't see your post... either way, if you could tell me what error you encounter, it'd be easier to tell you what you need to do to fix it...

@Pyro: Just download the demo and try it there... depending on what you mean with "messes your game up", there might not even be a problem, just you figuring there is one because the characters don'T get resized, but the characters do.

_________________
Image

If you have a slightly positive memory of my Power Shift contest game,
you might be interested in this development screenshot...
More info about that soon!


Top Top
 Profile  
 

Bunktown207
  Wed Nov 07, 2007 2:43 am
Member
I get an error on line 228 for window selectable....in the custom resolution script itself....i have the Display.dll extension in the same folder as the game extension itself, Selwyn's script was working prior, Seph's script was put in above Main and Below Game_Map and _PLayer.....

any thoughts?

*FIXED*
It wasn't underneath the window selectable folder =P

I am having issues with 'no implicit conversion to float from nil' in seph's script...going to try to relocate that as well....
here are the lines>

def initialize(viewport, map = $game_map.map)
@layers = []
for l in 0...3
layer = ($game_map.tilemap_plane ?
Plane.new(viewport) : Sprite.new(viewport))
layer.bitmap = Bitmap.new(map.width * 32, map.height * 32)
layer.z = l * 150

error line>>>>>>>>>>> layer.zoom_x = $game_map.tilemap_zoom_x

layer.zoom_y = $game_map.tilemap_zoom_y
if (tone = $game_map.tilemap_tone).is_a?(Tone)
layer.tone = tone
end
@layers << layer
end

_________________
.
.
.
http://www.ff-fan.com/chartest/banners/auron.jpg[/IMG]
Which Final Fantasy Character Are You?
Final Fantasy 7


Last edited by Bunktown207 on Wed Nov 07, 2007 3:22 am, edited 1 time in total.

Top Top
 Profile  
 

Bunktown207
  Wed Nov 07, 2007 3:29 am
Member
mt

_________________
.
.
.
http://www.ff-fan.com/chartest/banners/auron.jpg[/IMG]
Which Final Fantasy Character Are You?
Final Fantasy 7


Last edited by Bunktown207 on Wed Nov 07, 2007 4:17 am, edited 1 time in total.

Top Top
 Profile  
 

Cpt. Dane Elkard
  Mon Dec 17, 2007 12:11 am
User avatar
Member

Location: Portland, OR
Alright, I'll admit I'm kind of ignorant in regards to scripting. I kinda know how it works, but the errors perplex me.

I did everything that was said with Selwyn's script and Sephiroth's, and it says:

Quote:
'Custom_Resolution' line 352: NoMethodError occurred.
private method 'initialize' called for Resolution:Module


Can anybody tell me what happened? Also I don't know if this means anything, but Selwyn said to put Resolution.update after Input.update in all the Scene_ scripts. But Input.update isn't in 7 of those scenes ("Scene_Save" through "Scene_Battle 4"). Could that be any source of the problem?

EDIT: I fixed my own problem...I can't believe I'm this dumb. I simply forgot one of the key scripts :) Thought I had them all.

_________________
http://i49.photobucket.com/albums/f254/ ... nature.jpg[/img]
Click here for Sloperama Productions. This site has wonderful guidance and advice for aspiring game designers


Last edited by Cpt. Dane Elkard on Mon Dec 17, 2007 12:27 am, edited 1 time in total.

Top Top
 Profile  
 

MysticTrunks
  Sun Feb 03, 2008 12:12 am
User avatar
Member
I just got back into scripting, but the only thing that'd make this perfect is if you kept the window, instead of the screen going to the top left of your computer screen.


Top Top
 Profile  
 

GoldenGriffon
  Mon Jul 21, 2008 10:31 pm
Member
Excuse me for the necropost. (covers head) XD

I'm having the same problem as mentioned before with this script, the game window gets pushed to the upper left of the screen. When I put it into fullscreen it's still centered wrong. (This happens even with the demo.)
I just bought RPG Maker XP and downloaded the RGSS runtime environment, so I haven't included any scripts that might be interfering. My goal is to make the resolution look like RM2K3 (320 x 240), which the demo did except it was centered wrong.
My computer is running at 1024 x 768 resolution, by the way.

Does of you know how to solve this?


Top Top
 Profile  
 

Glitchfinder
  Mon Jul 21, 2008 11:59 pm
BEWARE: Glitchfinder's sense of humor sucks.
User avatar
Awesome Bro

Location: Approximately 93 million miles from Sol.
This is an edit of the original scripts posted in this thread, made so that it no longer requires Display.dll, and so that it starts in the center. I'll reformatg it later.

Content Hidden


With this, you no longer need Selwyn's Script, or the dll. Instead, there is and addition by Squall, which I have edited. Also, here is the updated version of SephirothSpawn's Rewritten Tilemap, also edited by me. (So that it no longer requires the SDK) You might want this version, because it can display tiles of all priorities. (Unlike the version posted at the top of this thread, which doesn't display tiles with a priority of 3, 4, or 5.)

Content Hidden

_________________

Image
Play it now!

You! Yes, you, the one reading this post!
Join me, the Head Librarian of the Coalition of Knowledge, in my quest to spread Learning and Wisdom to the unfortunate masses of Europe!
(We're rebooting the old RISK thread in forum games! Join us in our fun and revelry!)

Just call me Glitch.


Last edited by Glitchfinder on Wed Jul 23, 2008 1:31 am, edited 1 time in total.

Top Top
 Profile  
 

GoldenGriffon
  Tue Jul 22, 2008 5:30 am
Member
Awesome, thanks! ...But unfortunately, I am extremely new to scripting and don't quite know what to do with this. -_- I pasted the first bunch of code you gave me over the previous "Custom Resolution Script" code, and I'm not sure what to do with the rest of it. When I test played the game, the window was in the middle of the screen (hooray!) but I got an error message saying "Script 'Window Resolution Script' line 50: NoMethodError occurred. undefined method 'call' for nil:NilClass."

These are lines 49 - 52:
(49)def trigger?(key)
(50)    return @gaks.call(key) & 0x01 == 1
(51)  end

What now? =0


Top Top
 Profile  
 

Glitchfinder
  Tue Jul 22, 2008 6:53 am
BEWARE: Glitchfinder's sense of humor sucks.
User avatar
Awesome Bro

Location: Approximately 93 million miles from Sol.
GoldenGriffon wrote:
Awesome, thanks! ...But unfortunately, I am extremely new to scripting and don't quite know what to do with this. -_- I pasted the first bunch of code you gave me over the previous "Custom Resolution Script" code, and I'm not sure what to do with the rest of it. When I test played the game, the window was in the middle of the screen (hooray!) but I got an error message saying "Script 'Window Resolution Script' line 50: NoMethodError occurred. undefined method 'call' for nil:NilClass."

These are lines 49 - 52:
(49)def trigger?(key)
(50)    return @gaks.call(key) & 0x01 == 1
(51)  end

What now? =0


I already said, with my script, you don't need Selwyn's. (The Window Resolution Script). You can also delete the .dll file that is in the project as well. (As in, delete Display.dll)

_________________

Image
Play it now!

You! Yes, you, the one reading this post!
Join me, the Head Librarian of the Coalition of Knowledge, in my quest to spread Learning and Wisdom to the unfortunate masses of Europe!
(We're rebooting the old RISK thread in forum games! Join us in our fun and revelry!)

Just call me Glitch.


Top Top
 Profile  
 

BlueScope
  Tue Jul 22, 2008 11:40 am
The Third Man
[ranting about everything]
User avatar

Location: Germany
@Glitch: Haven't tested what you stated yet, but it definately sounds like it'd eradicate some of the more major problems of the initial script... what bugs me is that the implementation of Selwyns script (if I'm not mistaken, Selwyn's the more recent nick of "Squall")... what I'll definately do is including a reference to your additions - credited, of course - in the initial post... unless you desire otherwise, in which case just leave me a message and I'll delete it again...

_________________
Image

If you have a slightly positive memory of my Power Shift contest game,
you might be interested in this development screenshot...
More info about that soon!


Top Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 40 posts ]  Go to page 1, 2  Next


Who is online

Users browsing this forum: game_guy and 12 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Jump to:  

Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
Hosted By: