Terv

Veteran
Veteran
Joined
Feb 18, 2013
Messages
36
Reaction score
11
Primarily Uses
[IMG]http://www.aluxes-loves-eric.tk/images/head.png[/IMG]​
How to use the VX Ace engine in your XP games
in no more than 10 minutes - keep it simple, stupid!​

[IMG]http://www.aluxes-loves-eric.tk/images/de-icon.png[/IMG] Auf theutsch bitte
1. Introduction

In the following I am going to explain you how to use the engine of VX Ace (RGSS301.dll + Game.exe) in combination with your XP games which I fully entrust to everybody, for several reasons:
  • Lag no more: The new Ruby Version 1.9.2 is about 5 times faster than ancient 1.8.1 and will give your game an enormous performance boost, especially if you're an avid eventer.
  • Hyperliquid rendering: The XP engine is well-known for its stuttering scrolling and the associated tearing (graphics being cut). The image is lacking in calm, particularly in window mode. However after you have seen how beautifully soft and silky smooth your game looks with the new engine you're not going to want to miss it anymore.
  • Improved font rendering: The VX and VX Ace engine implemented an improved font rendering which makes your character more refined and a pleasure to read.
  • 60-120fps: While XP's standard frame rate is at a punny 40fps you can set the frame rate in Ace's engine up to 120fps with a single script call.
  • Up to 1024x768 in fullscreen: in combination with a suitable script you can easily more than double your resolution from 640x480 to 1024x768 - in fullscreen too.
2. Required Files and Licences

Even though you can get all the files either from the Ace RTP (dll) or any game (Exe), you officially need a valid VX Ace maker licence in order to use them in your own game. A trial licence is in no way inferior to a bought one. You can't tell whether the creator of an XP game using the Ace engine had or has a valid licence or not from looking at it.

For convenience reasons all for this tutorial required files and scripts are contained in my [IMG]http://www.aluxes-loves-eric.tk/images/pack.png[/IMG] XP Ace Upgrade Kit.


3. Step-by-step instructions
  • 3.1 Remove RTP dependency
Copy all used ressources from the XP RTP into your game folder. The RTP is usually located at C:\Program Files (x86)\Common Files\Enterbrain\RGSS\Standard or C:\Program Files\Common Files\Enterbrain\RGSS\Standard.
  • 3.2 Insert the Engine
Copy Game folder files\Game.exe and RGSS301.dll from the kit into your game folder.
Copy the folder Fonts into your game folder. Game.exe always checks whether these font files are present there if they're not already installed on the system. It's irrelevant whether they are used in your game at all.
RMXP version 1.02 or 1.04: Open your Game.ini and see what is written behind Library=. Rename the file RGSS301.dll accordingly (in most cases to RGSS102E.dll).
RMXP version 1.05: Refer to the solution of this report.
  • 3.3 Paste Scripts
Paste Scripts\RPG Module.txt above all other scripts in your project.
Paste Window Padding Fix.txt above Main.
Replace Main with Main.txt.
Optional: If you're using print in your game, paste Print.txt above Main.

The Tilemap class is unalterably compiled in the RGSS dll and its task is to read map files and build maps as we know them. Since VX and Ace are using a different mapping system and thus a different tilemap class, you need a replacement that knows how to deal with your XP maps.

At the moment there are 6 alternatives (=rewrites) in Ruby and 1 in C++ (WhiteFlute):
Pros | Cons
  • WhiteFlute [Recommended]: Extremely stable, rather efficient | May require small edits to Tilesets and scripts
  • me [Recommended]: Fluid rendering and highly stable, also at higher resolutions | Incompatible with smooth scrolling scripts
  • ForeverZer0 [Recommended]: Great performance, especially at higher resolutions | Occasional display bugs
  • The King [Recommended]: Very liquid rendering, many additional features | High RAM consumption, possibly long map loading times
  • poccil: Decent for small and mid-size maps | Micro stutters on large maps
  • SephirothSpawn: Absolutely fluid and stable rendering | Requires SDK Part I+II and parts of MACL Complete, Bugs
  • RTH: Okay for small maps | Heavy stutters on large maps
Paste the script of your choice below the standard scripts and above your own scripts. If you're using Sephiroth's rewrite please note that SDK and MACL have to be above the tilemap script.
  • 3.4 Adopt Windowskin
Either edit your windowskin so that the elements match those on an Ace windowskin or use Scripts\Windowskin Converter\Windowskin Converter.txt.
  • 3.5 Optional: Encrypt Project
Download the VX Ace trial and install it. Create a new project, delete all files in your new Ace project folder without closing the maker, then paste all XP game files into the Ace game folder. Now select File -> Compress Game Data... -> (Create Encrypted Archive) OK. An self-extracting archive will then be created, containing a .rgss3a file instead of Data and Graphics folders.
Keep in mind that the rgss3a encryption has been cracked and released 5th of June 2012.


4. Bag of tricks
  • In order to use a resolution beyond 640x480 use Game folder files\(optional)\RGSS300.dll and a script supporting custom resolutions (e.g. me's or ForeverZer0's rewrite). Furthermore change Graphics.resize_screen(640, 480) in Main accordingly.
  • To slow down in-game graphics to XP speed again use the script call Graphics.frame_rate = 40. This also decreases CPU load en passant. You can set the wanted fps to anything between 10 and 120.
  • All differences between RGSS v3 and v1 can be listed in the [IMG]http://www.aluxes-loves-eric.tk/images/page.png[/IMG] VX and [IMG]http://www.aluxes-loves-eric.tk/images/page.png[/IMG] Ace help file by searching for (RGSS2) respectively (RGSS3).
5. Credits

Dargor - XP->VX tutorial
ForeverZer0, LiTTleDRAgo, me, PK8, poccil, RTH, SephirothSpawn, The King, WHITE-FLUTE - scripts in the kit
Terv - everything else


6. Appendix: Error messages, known incompatibilities & solutions

It's quite likely that the first thing you will see from your tuned XP game is a mysterious error caused by a script that used to never make any trouble. In most cases it's just a small thing and can be easily fixed in minutes. However if you know as much about Ruby as the man in the moon, or encounter a more persistent error, there's a dedicated bugtracker now! Presenting you

I hope you liked my petty tutorial. Feel free to ask if you got questions or correct me when something is phrased cloudy :)
 
 
Last edited by a moderator:

Jens of Zanicuud

"A rose, a rose... my sanity for a rose!"
Member
Joined
Feb 19, 2013
Messages
8
Reaction score
0
First Language
Italian
Primarily Uses
I was actually trying to use VX engine on RMXP and I succeeded in making everything compatible but the Tilemap, so this comes like an unexpected thunderbolt...

It looks like you actually succeeded in doing what I was to do ;)

Very nice tutorial and idea, this is surely amazing.

Using RMXP's Maps Editor combined with RGSS3 could really help creating amazing things.

Jens
 

Terv

Veteran
Veteran
Joined
Feb 18, 2013
Messages
36
Reaction score
11
Primarily Uses
XP/RGSS3 bugtracker is up and running, feel free to post there if you have problems, or already solved them and want to tell us how you did it :D
 
Last edited by a moderator:

Jens of Zanicuud

"A rose, a rose... my sanity for a rose!"
Member
Joined
Feb 19, 2013
Messages
8
Reaction score
0
First Language
Italian
Primarily Uses
Just a question... in practice, you haven't replaces RGSS scripts with RGSS3, but you ported VACE player on RMXP?

In case this isn't true, how have you managed to configure RMXP database to be compatible with RGSS3?

For VX to XP conversion, I had to manually add functions like the dual weapon option and to translate each instance of the database into a new form which could be read by the new script set. VXACE comes with a lot of new features which can't be translated in a simple and useable manner...

That's different from what I thought before, but it's still a great idea ;)

Mine was different: I worked on a RMXP project in order to use RMVX scripts on it... and I almost succeeded in doing that.

I'll keep on following this topic, it looks interesting.

Jens
 

Terv

Veteran
Veteran
Joined
Feb 18, 2013
Messages
36
Reaction score
11
Primarily Uses
Just a question... in practice, you haven't replaces RGSS scripts with RGSS3, but you ported VACE player on RMXP?

In case this isn't true, how have you managed to configure RMXP database to be compatible with RGSS3?
This is not about using RGSS3 with XP maps (it would also break RGSS1 script compatibility), it's about implementing the new ruby version as well as other improvements (rendering etc.). Database files are read by the RGSS1 standard scripts which remain untouched. That's why this tutorial can be done in a couple minutes and that's why you cannot use RGSS3 scripts (but still use all your old RGSS1 ones).

Trying to combine the Ace engine, RGSS3 scripts/databases and XP maps will probably result in a horrible workflow as you'd need to use two makers simultaneously. And still being able to benefit from all the great XP scripts is a huge advantage. There's no point in willingly doing without them.
 
Last edited by a moderator:

Allerka

Veteran
Veteran
Joined
Dec 31, 2012
Messages
289
Reaction score
74
First Language
English
Primarily Uses
I want your babies. No, seriously. This is awesome and amazing and I love you for it.

Already run into a couple bugs, though, which I've posted to the tracker. Hopefully they can be ironed out quickly. I'm quite excited by this!
 

Terv

Veteran
Veteran
Joined
Feb 18, 2013
Messages
36
Reaction score
11
Primarily Uses
I have posted answers for both your reports, check them out :)
 

Allerka

Veteran
Veteran
Joined
Dec 31, 2012
Messages
289
Reaction score
74
First Language
English
Primarily Uses
Awesome! Looks like the game.ini issue is fixed, but the SDK is still plaguing me. Methinks I need to work on dumping that whole thing. It's been handy for some parts, but others have been nothing but headaches.
 

Sailerius

Engineer
Veteran
Joined
Mar 17, 2012
Messages
605
Reaction score
140
First Language
English
Primarily Uses
This is fantastic. Very well-presented. So, just to clarify, our custom RGSS1 scripts still work fine?
 
Last edited by a moderator:

Terv

Veteran
Veteran
Joined
Feb 18, 2013
Messages
36
Reaction score
11
Primarily Uses
Yep, most of your RGSS1 scripts will work right away. However about 1 out of 15 will throw up errors due to incompatibilities caused by either the change to Ruby 1.9 or RGSS3's hidden classes. These errors are usually rather easy to fix. Often it's just one or two lines. For every more obstinate error there's the bugtracker.
 

Allerka

Veteran
Veteran
Joined
Dec 31, 2012
Messages
289
Reaction score
74
First Language
English
Primarily Uses
So, I've noticed you CAN set your resolution higher, however altering the numbers in the relevant scripts (I'm using the one by me™) doesn't seem to have any actual effect on the game. Am I missing something?
 

Terv

Veteran
Veteran
Joined
Feb 18, 2013
Messages
36
Reaction score
11
Primarily Uses
What resolution are you trying to use? Is the window itself getting resized, but the map not extended?

Did you replace your dll with the one from Game folder files/(Optional)? Did you also change both the resolution in the tilemap rewrite and Main?
 
Last edited by a moderator:

Allerka

Veteran
Veteran
Joined
Dec 31, 2012
Messages
289
Reaction score
74
First Language
English
Primarily Uses
I tried bumping it up to 1024 x 768. The window and map are the same size as if I have it set for 640 x 480. I replaced the DLL with RGSS300.dll. I changed the resolution in both the tilemap rewrite on both lines and Main.
 

TMS

Guy with Mask
Veteran
Joined
Apr 17, 2012
Messages
320
Reaction score
62
First Language
English
Primarily Uses
N/A
I know nothing about programming, but I wanted to know if I could make use of this. Is it basically just a way to get games made with XP to run better, or is there more? Like, can I use types of events that were introduced in VX but were absent from XP (assuming there are any)?
 

Terv

Veteran
Veteran
Joined
Feb 18, 2013
Messages
36
Reaction score
11
Primarily Uses
@Allerka: Now that's really wierd, could you please check if it doesn't work for you in the project template neither? Maybe it's related to your other custom scripts or PC setup, but that's unlikely.

I know nothing about programming, but I wanted to know if I could make use of this. Is it basically just a way to get games made with XP to run better, or is there more?
You probably won't need any specific scripting knowledge yourself.

The biggest advantage of this is the poweful and improved new engine which makes games look and run better. Besides that there are some nice Ace features available, e.g. fullscreen video playback without having to install anything beforehand.

However it doesn't bring you features that are included either in Ace's editor (database, autotile features, whatever) or in the base RGSS3 scripts you can edit. It's just a quick way to brush up your game.

Best give it a try for your own one, it's easy and can be done in minutes.
 
Last edited by a moderator:

ShinGamix

DS Style 4Ever!
Veteran
Joined
Mar 18, 2012
Messages
3,937
Reaction score
503
First Language
April Fools
Primarily Uses
N/A
I was wondering if you can still open the game in the xp editor once you do this to the project?
 

Allerka

Veteran
Veteran
Joined
Dec 31, 2012
Messages
289
Reaction score
74
First Language
English
Primarily Uses
Yep, that all still works fine!

@Terv: Well, I feel dumb. I actually DIDN'T give it the proper DLL. I fixed that, and now the window is resizing itself and everything. However, it's only filling part of the window, ala:

resolution error.png

In the tilemap processor, the relevant lines regarding window size have been edited to read:

WindowRect = Rect.new(0,0,1024, 768) BitmapRect = Rect.new(0,0,1024 + 64, 768 + 64) # Recommended BitmapWindowOffset = (BitmapRect.height-WindowRect.height)/2/32
And then the line in Main reads:

Graphics.resize_screen(1024, 768)

resolution error.png
 

Terv

Veteran
Veteran
Joined
Feb 18, 2013
Messages
36
Reaction score
11
Primarily Uses
I was able to recreate the described behaviour, which is strange as people have been reporting that their higher resolution worked just fine with this script. Also tested it on some VMs (XP, Vista) and it's the same there.

I will look into it and update this post as soon as there's news.

If the feature should really be broken (dang, I remember running my game in 1024x768 as a test!) you can always use F0's rewrite, it's even a whit better when it comes to fluid scrolling.
 
Last edited by a moderator:

Fomar0153

Arkz
Restaff
Joined
Mar 13, 2012
Messages
1,330
Reaction score
517
First Language
English
Primarily Uses
RMMZ
In Spriteset map make the viewports:

@viewport1 = Viewport.new(0, 0, 800, 600) @viewport2 = Viewport.new(0, 0, 800, 600) @viewport3 = Viewport.new(0, 0, 800, 600)Next in Game_Player

 CENTER_X = (400 - 16) * 4   # Center screen x-coordinate * 4  CENTER_Y = (300 - 16) * 4   # Center screen y-coordinate * 4And finally in Game_Map

#-------------------------------------------------------------------------- # * Scroll Down # distance : scroll distance #-------------------------------------------------------------------------- def scroll_down(distance) @display_y = [@display_y + distance, (self.height - 19) * 128].min end #-------------------------------------------------------------------------- # * Scroll Right # distance : scroll distance #-------------------------------------------------------------------------- def scroll_right(distance) @display_x = [@display_x + distance, (self.width - 25) * 128].min end
The 19 and 25 are the max number of tiles on screen at any one time:

800/32=25

600/32=18.75 (round to 19)

Edit:

Ooh test battles also don't like me.

Add this to the rpg module:

Code:
module RPG  class System    class TestBattler      def initialize        @actor_id = 1        @level = 1        @weapon_id = 0        @armor1_id = 0        @armor2_id = 0        @armor3_id = 0        @armor4_id = 0      end      attr_accessor :actor_id      attr_accessor :level      attr_accessor :weapon_id      attr_accessor :armor1_id      attr_accessor :armor2_id      attr_accessor :armor3_id      attr_accessor :armor4_id    end  endend
 
Last edited by a moderator:

Vanitas

Sora's Worst Nightmare
Veteran
Joined
Jun 9, 2012
Messages
165
Reaction score
55
First Language
English
Hm, does anyone know why I'm getting a 'the specified procedure could not be found' error? It's got nothing to do with RGSS or anything it seems, it's an actual windows error...I'll run through the instructions again and see what I might've done wrong, but I was pretty sure I followed them correctly! OTL

edit: Figured out what I did! Mistook the instruction about renaming the .dll for changing it in the .ini ^^; 

and I got a bug of course~ (this'll take a while to get working I suspect). 
 
Last edited by a moderator:

Latest Threads

Latest Profile Posts

Am I the only one that thinks diablo 4's werebear form is atrocious o.0
Back from my short, self-imposed timeout with another picture of my collection of Snorlax mascots for my class. Another class starts on Friday.
Mascots.jpg

Forum statistics

Threads
131,607
Messages
1,221,528
Members
173,323
Latest member
Ishan
Top