The PokéCommunity Forums  

Go Back   The PokéCommunity Forums > Creative Discussions > Game Development > Scripts & Tutorials
Sign Up Rules/FAQ Live Battle Blogs Mark Forums Read

Notices

Scripts & Tutorials This forum is for scripts and code, as well as all kinds of tutorials, software, tools and so forth. Remember to give credit!
The thread revival limit does not apply here.


Reply
 
Thread Tools
  #1    
Old December 6th, 2010, 04:37 PM
KitsuneKouta's Avatar
KitsuneKouta
狐 康太
 
Join Date: Mar 2010
Age: 23
Gender: Male
By default, Essentials only allows you to create 4 selectable characters (labeled A-D, and numbered 0-3). This tutorial will allow you to increase this number to include as many as you want. As a disclaimer, I cannot guarantee consistent results. I have used this method twice, with someone else using it once, and each time the results were different. In an unedited kit, the results were perfect, but in existing projects it's sort of hit and miss, so beware.

First, in PokemonEditor, find

GLOBALMETADATA=[

(it should be on line 2743) and right below it you should see entries for players A - D that look like this:

["PlayerA",PlayerProperty,
_INTL("Specifies player A.")],

Add identical entries starting right below the entry for "PlayerD," but change the letters (it should go up to F if you want 6 characters, Z if you want 26, etc. You could arbitrarily name more if you wanted such as PlayerAA, or AZ, etc., but you probably won't need that many).

In PokemonUtilities there are 3 small edits to make. Look for these lines (around line 1493):

return false if id<0||id>=4
return "" if id<0||id>=4
return 0 if id<0||id>=4

They're not right together, but pretty close. Change the 4s to the number of characters you want (i.e. change the 4s to 6s for 6 characters, 4 to 26 for 26 characters, etc.).Next, in PokemonMap, starting on line 275, there will be some metadata items that look like this:

Code:
MetadataHome=1
 MetadataPlayerA=2
 MetadataPlayerB=3
 MetadataPlayerC=4
 MetadataPlayerD=5
 MetadataStorageCreator=6
 MetadataWildBattleBGM=7
 MetadataTrainerBattleBGM=8
 MetadataWildVictoryME=9
 MetadataTrainerVictoryME=10
 MetadataTextSkin=11
 MetadataSurfBGM=12
 MetadataBicycleBGM=13
Add more entries for the number of characters you want, such as "MetadataPlayerE" or "MetadataPlayerF." Here's an example of how it'd look if you have 6 characters:
Code:
MetadataHome=1
 MetadataPlayerA=2
 MetadataPlayerB=3
 MetadataPlayerC=4
 MetadataPlayerD=5
 MetadataPlayerE=6
 MetadataPlayerF=7
 MetadataStorageCreator=8
 MetadataWildBattleBGM=9
 MetadataTrainerBattleBGM=10
 MetadataWildVictoryME=11
 MetadataTrainerVictoryME=12
 MetadataTextSkin=13
 MetadataSurfBGM=14
 MetadataBicycleBGM=15
Then a little below it find this:
Code:
GlobalTypes={
  "Home"=>[1,"uuuu"],
  "PlayerA"=>[2,"essssss",:PBTrainers],
  "PlayerB"=>[3,"essssss",:PBTrainers],
  "PlayerC"=>[4,"essssss",:PBTrainers],
  "PlayerD"=>[5,"essssss",:PBTrainers],
  "StorageCreator"=>[6,"s"],
  "WildBattleBGM"=>[7,"s"],
  "TrainerBattleBGM"=>[8,"s"],
  "WildVictoryME"=>[9,"s"],
  "TrainerVictoryME"=>[10,"s"],
  "TextSkin"=>[11,"s"],
  "SurfBGM"=>[12,"s"],
  "BicycleBGM"=>[13,"s"]
 }
Then, once again, add more entries according the desired number of characters. An example:
Code:
GlobalTypes={
   "Home"=>[1,"uuuu"],
  "PlayerA"=>[2,"essssss",:PBTrainers],
  "PlayerB"=>[3,"essssss",:PBTrainers],
  "PlayerC"=>[4,"essssss",:PBTrainers],
  "PlayerD"=>[5,"essssss",:PBTrainers],
  "PlayerE"=>[6,"essssss",:PBTrainers],
   "PlayerF"=>[7,"essssss",:PBTrainers],
  "StorageCreator"=>[8,"s"],
  "WildBattleBGM"=>[9,"s"],
  "TrainerBattleBGM"=>[10,"s"],
  "WildVictoryME"=>[11,"s"],
  "TrainerVictoryME"=>[12,"s"],
  "TextSkin"=>[13,"s"],
  "SurfBGM"=>[14,"s"],
  "BicycleBGM"=>[15,"s"]
 } 
Make absolutely sure that you renumber the entries when you add in new ones. (i.e. "BicycleBGM" starts at 13, but in the examples ends up at 15)

It is important to note that only the in-game editor will be able to edit the newly added characters (This is where the results of using these steps varies somewhat. Sometimes they show up, other times they don't. Either way, the new entries are still usable). The external editor that it packaged with Essentials will not work for this, as the new entries won't show up and the old ones will appear to be incorrect, since the values will look like they're in the wrong place. This doesn't effect whether or not it actually works. Also, the external editor's other functions should still be perfectly usable. Just don't use it to edit global metadata entries.

It is recommended to create the new characters in the metadata.txt file, in the event that they don't show up in the in-game editor anyways. To do so, simply copy/paste existing entries and change the values. Example:
Copy the entry
PlayerD=PkMnTRAINER_Female,Crystal,onbike,,Crystal,Crystal,Crystal
and add these directly below it in the txt file with necessary modifications:
PlayerE=PkMnTRAINER_Male,Green,onbike,,Green,Green,Green
PlayerF=PkMnTRAINER_Female,Blue,onbike,,Blue,Blue,Blue


To change the player to one of these new characters, do it just the same as usual with the pbChangePlayer(x) command, using numbers the correspond to characters you added (it starts with 0, so take the alphabetical letters corresponding number and subtract 1, so A is 0, M is 12, and Z is 25).

If you have any problems, let me know, unless it's just the entries not showing up in the in-game editor. There nothing I can do about that, except recommend that you retry the steps, but the new characters should work regardless.
__________________
Creator of the Harvest Moon Tool Kit (HMTK).

Anime/Manga fans can find me on MyAnimeList.net, as KitsuneKouta.
Reply With Quote
  #2    
Old December 9th, 2010, 05:44 PM
zingzags's Avatar
zingzags
Creator or Pokemon Serenity
 
Join Date: Jan 2009
Location: Boston
Age: 20
Nature: Adamant
Dude, can I kiss you?, I was looking for this...
I was having problems before because I was getting a fixum error....
__________________
Pokemon Serenity is my fangame name.
name decided 12/15/09
Currently helping:
Pokemon ebony
and
Xenotime:
Reply With Quote
  #3    
Old December 9th, 2010, 06:00 PM
chriskid198's Avatar
chriskid198
Happy New Year!
 
Join Date: Jul 2010
Location: Australia
Age: 17
Gender: Male
Nature: Relaxed
What are the selectable players?
__________________
Looking for Team Members for my game! PM me if your interested.
VDex:
GPX+:
Reply With Quote
  #4    
Old December 9th, 2010, 07:32 PM
KitsuneKouta's Avatar
KitsuneKouta
狐 康太
 
Join Date: Mar 2010
Age: 23
Gender: Male
Quote:
Originally Posted by chriskid198 View Post
What are the selectable players?
Is this what you're talking about?
Quote:
Originally Posted by KitsuneKouta View Post
To change the player to one of these new characters, do it just the same as usual with the pbChangePlayer(x) command, using numbers the correspond to characters you added (it starts with 0, so take the alphabetical letters corresponding number and subtract 1, so A is 0, M is 12, and Z is 25).
@zingzags: I don't know about the kiss but...I'm glad you liked the tutorial.
__________________
Creator of the Harvest Moon Tool Kit (HMTK).

Anime/Manga fans can find me on MyAnimeList.net, as KitsuneKouta.
Reply With Quote
  #5    
Old December 10th, 2010, 01:04 PM
Pia Carrot's Avatar
Pia Carrot
Owner of Desu Soft
 
Join Date: Aug 2010
Age: 18
Gender: Male
Nature: Adamant
wow, great tutorial KitsuneKouta-sempai. Now I can finally add the outfits to my game ^.^
__________________

Reply With Quote
  #6    
Old December 11th, 2010, 09:29 AM
IceGod64's Avatar
IceGod64
My imagination.
 
Join Date: Oct 2008
Location: Castelia City
Age: 26
Gender: Male
Nature: Naive
This tutorial might be handy, even though I'm only using two characters. I guess alternate sprites aren't a bad idea.

Mainly though, I wanted to comment on the external editor; I myself added map specific MetaData to allow running in a map without having to set Outdoor to true (For running in buildings, for example), and now I CAN edit this using the in-game editor. Not the external editor though, as you said, the external editor doesn't handle that very well.
__________________

Reply With Quote
  #7    
Old December 11th, 2010, 09:55 AM
KitsuneKouta's Avatar
KitsuneKouta
狐 康太
 
Join Date: Mar 2010
Age: 23
Gender: Male
Quote:
Originally Posted by IceGod64 View Post
This tutorial might be handy, even though I'm only using two characters. I guess alternate sprites aren't a bad idea.

Mainly though, I wanted to comment on the external editor; I myself added map specific MetaData to allow running in a map without having to set Outdoor to true (For running in buildings, for example), and now I CAN edit this using the in-game editor. Not the external editor though, as you said, the external editor doesn't handle that very well.
Logically, that's what should happen. However, Essentials isn't always logical, with the random errors and bugs. And as I mentioned, I had mixed success (which I still can't figure out why), but it works, so that's the main thing. On a side note, it'd be nice if I could figure out how to edit the external editor, that way it could be upgraded with new changes. But I've heard it's somewhat buggy too, so that might just be an extra headache.
__________________
Creator of the Harvest Moon Tool Kit (HMTK).

Anime/Manga fans can find me on MyAnimeList.net, as KitsuneKouta.
Reply With Quote
  #8    
Old December 12th, 2010, 08:11 PM
IceGod64's Avatar
IceGod64
My imagination.
 
Join Date: Oct 2008
Location: Castelia City
Age: 26
Gender: Male
Nature: Naive
Quote:
Originally Posted by KitsuneKouta View Post
On a side note, it'd be nice if I could figure out how to edit the external editor, that way it could be upgraded with new changes. But I've heard it's somewhat buggy too, so that might just be an extra headache.
It theoretically wouldn't be that much harder, as it's a normal set of RPGMakerXP scriptes that make it work. I just renamed "EditorScripts.rxdata" after backing up my original scripts and I'm able to edit it(Surprisingly).
__________________

Reply With Quote
  #9    
Old December 12th, 2010, 09:25 PM
KitsuneKouta's Avatar
KitsuneKouta
狐 康太
 
Join Date: Mar 2010
Age: 23
Gender: Male
Quote:
Originally Posted by IceGod64 View Post
It theoretically wouldn't be that much harder, as it's a normal set of RPGMakerXP scriptes that make it work. I just renamed "EditorScripts.rxdata" after backing up my original scripts and I'm able to edit it(Surprisingly).
So how do you edit it (or what do you open it with)?
__________________
Creator of the Harvest Moon Tool Kit (HMTK).

Anime/Manga fans can find me on MyAnimeList.net, as KitsuneKouta.
Reply With Quote
  #10    
Old December 13th, 2010, 09:06 AM
IceGod64's Avatar
IceGod64
My imagination.
 
Join Date: Oct 2008
Location: Castelia City
Age: 26
Gender: Male
Nature: Naive
Quote:
Originally Posted by KitsuneKouta View Post
So how do you edit it (or what do you open it with)?
Check your Project/Data folder
Rename the "scripts.rxdata" file in your current project to something easy to find, such as "scripts2.rxdata".
Rename "EditorScripts.rxdata" to just "scripts.rxdata".
In the main folder for your project, just open up "game.rxproj" on RPGmakerXP as you usually would, and your game will have the editors scripts. You can even compile the EXE to test and it works fine.
Once you got everything you wanted done, just rename the two files I told you to rename back to their original names.
__________________

Reply With Quote
  #11    
Old December 13th, 2010, 02:19 PM
KitsuneKouta's Avatar
KitsuneKouta
狐 康太
 
Join Date: Mar 2010
Age: 23
Gender: Male
Quote:
Originally Posted by IceGod64 View Post
Check your Project/Data folder
Rename the "scripts.rxdata" file in your current project to something easy to find, such as "scripts2.rxdata".
Rename "EditorScripts.rxdata" to just "scripts.rxdata".
In the main folder for your project, just open up "game.rxproj" on RPGmakerXP as you usually would, and your game will have the editors scripts. You can even compile the EXE to test and it works fine.
Once you got everything you wanted done, just rename the two files I told you to rename back to their original names.
Huh, that was surprisingly simple. Thanks for the tip.
__________________
Creator of the Harvest Moon Tool Kit (HMTK).

Anime/Manga fans can find me on MyAnimeList.net, as KitsuneKouta.
Reply With Quote
  #12    
Old December 13th, 2010, 03:12 PM
IceGod64's Avatar
IceGod64
My imagination.
 
Join Date: Oct 2008
Location: Castelia City
Age: 26
Gender: Male
Nature: Naive
Quote:
Originally Posted by KitsuneKouta View Post
Huh, that was surprisingly simple. Thanks for the tip.
Oh, it was what you said about editing the EXE in the first place that made me even experiment. I had no idea it was that easy. I was pretty sure it would require hex editing to do.

Anyway, editing the editor to reflect your changes shouldn't be hard at all now. Good luck with that.
__________________

Reply With Quote
  #13    
Old December 13th, 2010, 05:13 PM
KitsuneKouta's Avatar
KitsuneKouta
狐 康太
 
Join Date: Mar 2010
Age: 23
Gender: Male
Quote:
Originally Posted by IceGod64 View Post
Oh, it was what you said about editing the EXE in the first place that made me even experiment. I had no idea it was that easy. I was pretty sure it would require hex editing to do.

Anyway, editing the editor to reflect your changes shouldn't be hard at all now. Good luck with that.
That's what I thought at first too. But if you think about it, the exe doesn't actually contain the data, it's in the .rxdata file. Same as with any RMXP project, the game.exe doesn't actually hold the data, it just reads what's in the data files and finds graphics and audio from sub folders. It was pretty clever on Poccil's part.
__________________
Creator of the Harvest Moon Tool Kit (HMTK).

Anime/Manga fans can find me on MyAnimeList.net, as KitsuneKouta.
Reply With Quote
  #14    
Old December 17th, 2010, 09:13 AM
IceGod64's Avatar
IceGod64
My imagination.
 
Join Date: Oct 2008
Location: Castelia City
Age: 26
Gender: Male
Nature: Naive
Quote:
Originally Posted by KitsuneKouta View Post
Quote:
Originally Posted by zingzangs
Dude, can I kiss you?, I was looking for this...
I was having problems before because I was getting a fixum error....
@zingzags: I don't know about the kiss but...I'm glad you liked the tutorial.

He's got to be kidding!

Sorry about the very delayed response, and the rather needless post, but I felt this was necessary for those of you that get the joke.

Quote:
That's what I thought at first too. But if you think about it, the exe doesn't actually contain the data, it's in the .rxdata file. Same as with any RMXP project, the game.exe doesn't actually hold the data, it just reads what's in the data files and finds graphics and audio from sub folders. It was pretty clever on Poccil's part.
Actually, I just thought of another fix for why this trick might not work in edited projects. It's possible that one fix may be starting a new save file. That's fixed certain types of bugs in my own project before.
__________________

Reply With Quote
  #15    
Old December 17th, 2010, 10:52 AM
KitsuneKouta's Avatar
KitsuneKouta
狐 康太
 
Join Date: Mar 2010
Age: 23
Gender: Male
Quote:
Originally Posted by IceGod64 View Post
He's got to be kidding!

Sorry about the very delayed response, and the rather needless post, but I felt this was necessary for those of you that get the joke.

Actually, I just thought of another fix for why this trick might not work in edited projects. It's possible that one fix may be starting a new save file. That's fixed certain types of bugs in my own project before.
Lol. That's part of why I'm so averted to playing the older zeldas.

Anyways, I suppose what you mentioned might be possible, but I don't know if it's really a bug. It's almost like Essentials looks for places to throw wrenches into, hoping to make your game developing experience a little harder. Also, it should work in edited kits, but other edits to the editor scripts may interfere. Or maybe Essentials isn't in the mood to cooperate on that day. Who knows. Really though, it's probably because of the compiler. Compiling the game should fix it, but then again it may not be designed to be flexible enough for various mods.
__________________
Creator of the Harvest Moon Tool Kit (HMTK).

Anime/Manga fans can find me on MyAnimeList.net, as KitsuneKouta.
Reply With Quote
Reply
Quick Reply

Sponsored Links


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Minimum Characters Per Post: 25



All times are UTC -8. The time now is 05:55 PM.


Style by Nymphadora, artwork by Sa-Dui.
Like our Facebook Page Follow us on Twitter © 2002 - 2014 The PokéCommunity™, pokecommunity.com.
Pokémon characters and images belong to The Pokémon Company International and Nintendo. This website is in no way affiliated with or endorsed by Nintendo, Creatures, GAMEFREAK, The Pokémon Company or The Pokémon Company International. We just love Pokémon.
All forum styles, their images (unless noted otherwise) and site designs are © 2002 - 2014 The PokéCommunity / PokéCommunity.com.
PokéCommunity™ is a trademark of The PokéCommunity. All rights reserved. Sponsor advertisements do not imply our endorsement of that product or service. User generated content remains the property of its creator.