[XP] Party Changer

I've never tried with the RTAB but this system was designed for the DBS, so I doubt any CBS would work with this script. Let me know if a CBS is compatible with this script! :thumb:
Dargor wrote:
Dargor wrote:
@RaijinRagnarok 
Ok, to fix the 'undefined method' error, go in the Party Arrange script, line 67, and replace
actor = $game_party.actors
Expand to see the code.
for
actor = $game_party.actors[i]
Expand to see the code.
. The second error should be fixed with version 4.0 (you have version 3.3). However, version 4.0 requires the RMXP SDK 2.3.

Take care!
-Dargor



Oh! O_O You told me already? I could have sworn I searched all the pages tons of times... @_@

Okay I'll try it out when my stupid access code FINALLY comes in the mail so I can get the trial version updated to the full version...


Also, weird thing happened to me. When I typed in an enemy's HP, I could only go to 99999. When I hit the up arrow, it goes to 100000. From there, if I keep hitting the up arrow, it goes up in 1s, but there's no way to just hit 999999. It makes that error sound if I hit the 9 again or any other number after five digits.

Any idea what's going on?
Dude i got an error.
class Scene_Battle < SDK::Scene_Base
Phoenix-Crest wrote:
Dude i got an error.
class Scene_Battle < SDK::Scene_Base


Print out the SDK scripts, group the papers together, then light them on fire in your toilet.  Made me realize what SDK was good for. 
Hey Dargor, I was wondering if you were going to put the thing I suggested before...if not I might just make a request of it in my thread. Thanks.
Can you help me with this? I receive an error message at line 1324 when I try using "Arrange" command, thanks
Umm was just wondering, how do I remove the switch party in battle?
Nightmare Omnizohar wrote:
Umm was just wondering, how do I remove the switch party in battle?


Just quit and reload the game.  It never sticks around for me when I save and reload, despite having saved after an event that turns it on. 

Or you could always set    @party_changer_in_battle = false
or something crazy like that. 
@BellGoRiiing
I've answered your PM.
Great avatar by the way! 😆

@B.E.W.D
Be more precise please.

@Nightmare Omnizohar
At the beginning of the script, look for
@party_changer_in_battle = true
Expand to see the code.

then set this variable to false.
I created an event and insert a script like this
Quote:
$scene = Scene_Party.new(2, 4, [], 0)
to change party member ( I only use large party and party change script ). In game, I use this event and while in the party change screen I try using the "Arrange" command and as soon as I choose the actor I receive an error message in line 1324. After that I try using the demo to creat this event but I have same problem, I think this command can only use in main menu or something like that. Please help me with this or can you help me to remove this command, I really needn't it but I like this script very much ( It is the best party change script I know)
And sorry about my English too
I found some problem with the script that causes problems with my events. On one of my event, my party fights some godlike demon, and if they lose the event should continue. Heres the event I setup:
@>Text: Words
@>Change BGM to Boss Music
@>Battle Processing: Boss
: If Win
   @>
: If Lose
   @>
: Branch End
@> Events Continue
Expand to see the code.

What I putted was either if I win or lose, result wont change. But this isn't happening because with the script in my game and when I lose a battle, it just goes to a Game Over screen instead of continuing event like I wanted. When I remove the script, the game runs the way I wanted it.
Anyway to make it so the main character is not able to be changed
There's already an option for that. Look at the script header, you'll find all the informations you need there.
I'm having a problem with the script. I read through the whole thread to find an answer, please forgive me I'm still new with all this. But I'm trying to lock the main hero on the first slot, meaning he's not even supposed to be moved from the first slot when arranging or when switching party members.

I'm using this code:
$scene = Scene_Party.new(max_members, forced_members, lock_leader?)

Edited to this:
$scene = Scene_Party.new(4, [1], true)

Though when I call the script I keep getting this error:
Script 'Party Changer' line 1032: NoMethodError occured.
undefined method 'each' for true:TrueClass

Please help.
@Kenihi34
It's probably because you're using an older version or an old method with a newer version.

Assuming you're using version 4.0, the new arguments for the Scene_Party class are:
(min_actors = 1, max_actors = 4, forced_members = [], lock_members = [], from_menu=false)

@B.E.W.D 
You said you were using only the large party script and the party changer script. But you also need  the Commands Manager script.

@Nightmare Omnizohar 
Interesting bug. I'll take a look at it.
All right, everything is working great. Thanks for the help. Great script too!
I have a question about the method in which members who are available, but not in the active party, obtain exp.  According to the script, you set @members_gain_exp to true, and then set the rate at which they gain exp with @members_exp_rate, am I correct? 

I set the @members_exp_rate to 40.  Checking lower in the script, there is a line (the number of the line differs because I added comment lines to include the call script commands that correspond with this script so that I don't need to hunt through a thirteen-page forum thread) which reads: 

member.exp += (exp/100) * $game_temp.members_exp_rate

According to this formula, it seems as though "exp" is the exp gained from a battle, and members_exp_rate is just what it sounds like, which in this case would be 40.  From a battle, the exp gain was 129.  Therefore, the formula would be ( 129 / 100 ) * 40 which according to a TI-83+ yields 51.6.  However, according to the game, an inactive member only gained 40 experience points. 

On the side, I also devised a method of making sure inactive members at least gained 1 experience point.  I simply placed parentheses around the formula and ended the line with a "+ 1" as follows:

member.exp += ((exp/100) * $game_temp.members_exp_rate) + 1

My main question is about the math discrepency.  The formula was entered correctly into the TI-83+, not that I need to mention that, seeing as it wouldn't make sense for me to make a post asking about a math discrepency if it was obvious I computed the formula incorrectly. 
It's because the formula only accepts Integers. Turning the results into Floats would probably fix the problem. Your TI-83+ automatically turns integers into Float if needed while Ruby rounds the Float to an Integer.
Hopefully this won't get me in trouble (I fear the huge red text) but I figured the best place to ask a question would be in the place I got the script.  Firstly, awesome script, secondly my question.

I tried to set it up so that the player can edit his party only in certain places (i.e. an inn).  I put all the scripts into the test project I was running and since scripts confuse the hell out of me I basically just edited the multi-party script from your demo.  However, I get an error

Quote:
Script 'Party Changer' line 1018: NoMethodError occurred

undefined method 'each' for 1:Fixnum


I'm sorry if this is a problem and understand if no one answers.
shadowmimiiru, I think I answered your question in the thread you made in General Support.  🙂
Dadevster wrote:
shadowmimiiru, I think I answered your question in the thread you made in General Support.  🙂


Yep!  you did, thanks!
Dadevster wrote:
shadowmimiiru, I think I answered your question in the thread you made in General Support.  🙂


Yep, it did, and as you asked I added Dargor to my .doc file with the credits to put at the end.

I'm still having some problems though.  For one the game crashes when the party dies with the message:

Script 'Party Changer' line 627: NoMethodError occurred.

Undefined method "members_all_dead?" for #
Hi.  I hope this question makes sense...does the party changing system keep track of who the lead actor is?  I know it updates the graphic on the map.

Why I need to know is, that I want to make it so certain events happen if and only if a certain actor is in the lead of the party (so for instance, if I want to open a locked door, I want the thief to be in the lead of the party, not just IN the party.  So, if someone else is in the lead of the party, a message like "Thief may be able to pick the lock", but if thief is leading, the door would open).

Also, is there a way to shuffle through the party order by pressing a button on the keyboard, so for example, pressing A would permute the order of the actors:
1 -> 4
2 -> 1
3 -> 2
4 -> 3

Thanks in advance!
What scripts would I use if if i only want to be able to re-arrange in the main member?
Well, this thread looks dead but I'll try...

Is there a sideview CBS that works with this? It  spaces out all 4 characters across the length of the whole screen...
Um... Excuse me er... Mr. Dargor. I have encountered a problem here. I copied your script but when I play the game, there is no text in the menu. Could you help me with this? Thank you.
Try putting the script above Main and below everything else. Also, make sure you are using the English version of RMVX.
Should I use English version of RMXP or RMVX? Because I use the english version of RMXP. Could it be the problem?
Aw sorry, I said VX. It's for XP.
So if you don't have the English version of XP, it might be the problem.
Excuse me, I'm newb here.  I'm trying to have a change party selection for my game, but there has been some problems.  I found your script and tried to imput it on my game but there seems to be a problem. 'Party Changer' line 644: Type error occurred, undefined superclass 'Scene_Base'   Please reply as soon as possible (I'm using the trial version)  ^^;

Original thread: https://www.hbgames.org/forums/viewtopic.php?t=23508