——— — Before you ask! Read! ;) —
You must have 30+ Posts to create a topic here!
— Thanks for reading! — ———
|
|
  |
Side View Battle System (Request) |
|
|
|
|
Feb 7 2012, 07:26 PM
|

Level 1

Group: Member
Posts: 14
Type: Developer
RM Skill: Intermediate

|
I want a side view battle system that doesn't have animated battlers,special moves,etc. Everywhere I search up a side view battle system theres always that. I just want a simple side view battle system. Kinda like the one that coms with rmxp but at the side view. I don't want to change much. Please and Thank you
__________________________
)@y
|
|
|
|
|
|
|
|
|
Feb 8 2012, 12:53 AM
|

Dark Jentleman

Group: Local Mod
Posts: 904
Type: Scripter
RM Skill: Skilled
Rev Points: 120

|
Try this. SPACING_X is the x distance between your characters, SPACING_Y the y distance. CODE #-------------------------------------------------------------------------- #** Game_Actor #-------------------------------------------------------------------------- SPACING_X = 20 #x distance between two adjacent battlers SPACING_Y = 20 #y distance between two adjacent battlers OFFSET_X = 500 #first party member x position OFFSET_Y = 220 #first party member y position
class Game_Actor #-------------------------------------------------------------------------- # * screen_x #-------------------------------------------------------------------------- def screen_x if self.index != nil return self.index * SPACING_X + OFFSET_X else return 0 end end #-------------------------------------------------------------------------- # * screen_y #-------------------------------------------------------------------------- def screen_y if self.index != nil return OFFSET_Y + self.index * SPACING_Y else return OFFSET_Y end end #-------------------------------------------------------------------------- # * screen_z #-------------------------------------------------------------------------- def screen_z if self.index != nil return self.index else return 0 end end end Just paste it above main. Jens
This post has been edited by Jens of Zanicuud: Feb 8 2012, 12:56 AM
__________________________
|
|
|
|
|
|
|
|
|
Feb 8 2012, 05:10 PM
|

Level 1

Group: Member
Posts: 14
Type: Developer
RM Skill: Intermediate

|
One more thing Is there a way to make animations smaller? Besides making all animations smaller by editting them?
__________________________
)@y
|
|
|
|
|
|
|
|
|
Feb 9 2012, 04:24 PM
|

Level 1

Group: Member
Posts: 14
Type: Developer
RM Skill: Intermediate

|
Its the size of an original sprite that comes with the game maker. i just copied them facing < and >. I didn't edit them. to be specific 43x23 or 23x43 i never figured out wich is wich  Edit:Sry to sound needy but i also need a script to change party members in battle
This post has been edited by jayjay5366: Feb 9 2012, 07:13 PM
__________________________
)@y
|
|
|
|
|
|
|
|
|
Feb 10 2012, 01:44 AM
|

Dark Jentleman

Group: Local Mod
Posts: 904
Type: Scripter
RM Skill: Skilled
Rev Points: 120

|
What is party maximum size? How many heroes in battle? How many replacements? Example of answer: "I decided for a maximum of 8 party members. In battle, there are 4 active battlers, who can be shifted with the replacements. I'm planning to have from 1 to 4 replacements." It's just for windows size, in order to place them better. It should not be too much difficult and rather quick to script. Right, then. Give me the infos and I feel I can solve this. However, standard RTP XP char graphics are 32*48 pixels, if you are using them. Jens EDIT: Animation issue solved; Paste this in a blank above main. CODE #============================================================================== #=#============================================================================ # #** Jens of Zanicuud animation magnifier script v 1.0 # # -free use, just credit # # -free customization, however, posting on RRR the modified version is # # mandatory # # -you can find me on www.rpgrevolution.com #=#============================================================================ #==============================================================================
#============================================================================== # ** Sprite class #============================================================================== class RPG::Sprite
#============================================================================== # ** Constants #============================================================================== ZOOM_RATIO = 0.5
#============================================================================== # ** Animation Set Sprites #============================================================================== def animation_set_sprites(sprites, cell_data, position) for i in 0..15 sprite = sprites[i] pattern = cell_data[i, 0] if sprite == nil or pattern == nil or pattern == -1 sprite.visible = false if sprite != nil next end sprite.visible = true sprite.src_rect.set(pattern % 5 * 192, pattern / 5 * 192, 192, 192) if position == 3 if self.viewport != nil sprite.x = self.viewport.rect.width / 2 sprite.y = self.viewport.rect.height - 160 else sprite.x = 320 sprite.y = 240 end else sprite.x = self.x - self.ox + self.src_rect.width / 2 sprite.y = self.y - self.oy + self.src_rect.height / 2 sprite.y -= self.src_rect.height / 4 if position == 0 sprite.y += self.src_rect.height / 4 if position == 2 end ratio = ZOOM_RATIO sprite.zoom_x = cell_data[i, 3] / 100.0 * ratio sprite.zoom_y = cell_data[i, 3] / 100.0 * ratio sprite.x += cell_data[i, 1] sprite.y += cell_data[i, 2] sprite.z = 2000 sprite.ox = 96 sprite.oy = 96 sprite.angle = cell_data[i, 4] sprite.mirror = (cell_data[i, 5] == 1) sprite.opacity = cell_data[i, 6] * self.opacity / 255.0 sprite.blend_type = cell_data[i, 7] end end end Edit ZOOM_RATIO variable to modify magnification. I set it to 0.5, which is half of the normal size you set into animation database. Jens
This post has been edited by Jens of Zanicuud: Feb 10 2012, 04:20 AM
__________________________
|
|
|
|
|
|
|
|
|
Feb 10 2012, 04:50 PM
|

Level 1

Group: Member
Posts: 14
Type: Developer
RM Skill: Intermediate

|
There's a maximun of 4 people fighting at a time. Theres like 36 characters i might add more. I have Leon's party changing script. I want to be able to switch in battle too  Edit:There's going to be a skill that the bad guys use on you and ur character freezes you in a stone and the only cure is to do a quest but I don't want to be too cruel and make it that u can't switch people
This post has been edited by jayjay5366: Feb 10 2012, 04:52 PM
__________________________
)@y
|
|
|
|
|
|
|
|
|
Feb 11 2012, 09:12 PM
|

Level 1

Group: Member
Posts: 14
Type: Developer
RM Skill: Intermediate

|
It worked ferfectly thx. And this is the code CODE #=================================== # Party Changing System by Leon_Westbrooke # -v 1.1 #---------------------------------------------------------------------- # Instructions: Place above main, but below all other default scripts. # # Features: # -Allows the player to make a party from the minimum to maximum size. # -Extra members are limitless. # -You can remove a person from the party and put it into reserve using: # $game_party.remove_actor_to_party(actor_id) # -You can remove a person from the reserve if they exist, and them into # the party: # $game_party.add_actor_to_party(actor_id) # -You can lock a character in reserve or active party by using: # $game_party.locked.push(actor_id) # -You can set the maximum and minimum number of the party in-game using: # $game_party.min_size = x # $game_party.max_size = x # (NOTE: Do NOT make the max size lower than the minimum size.) # -Allows you to use the default add/remove actors command. # (NOTE: If you remove an actor with this method, he is gone from both # the party and the reserve members.) # # Credits: # This setup uses SephirothSpawn's coding to simplify the cursor's position. # # # Command Quick-list: # $game_party.remove_actor_from_party(actor_id) # -Removes an actor from the party, and puts them in reserve. # $game_party.add_actor_to_party(actor_id) # -Replaces the last actor in the party with the actor in reserve. # $game_party.locked.push(actor_id) # -Locks the actor in place. # $game_party.min_size = x # $game_party.max_size = x # -Sets the minimum and maximum party size. # # # Notes: # This script rewrites these methods from Game_Party: # add_actor # remove_actor #=================================== #================================================== # Game_Party #================================================== class Game_Party attr_accessor :party_members attr_accessor :move attr_accessor :locked attr_accessor :min_size attr_accessor :max_size alias leon_partyswitch_gameactor_initialize initialize def initialize leon_partyswitch_gameactor_initialize @party_members = [] # Edit :This is to change if an actor is locked or not. To lock them, add # their id to the array below. @locked = [1] @min_size = 1 @max_size = 4 end def add_actor(actor_id) actor = $game_actors[actor_id] if @actors.size < @max_size unless @actors.include?(actor) unless @party_members.include?(actor.id) @actors.push(actor) $game_player.refresh end end else unless @party_members.include?(actor.id) unless @actors.include?(actor) @party_members.push(actor.id) $game_player.refresh end end end end def remove_actor(actor_id) @actors.delete($game_actors[actor_id]) @party_members.delete(actor_id) $game_player.refresh end def remove_actor_from_party(actor_id) if @actors.include?($game_actors[actor_id]) unless @party_members.include?(actor_id) @party_members.push(actor_id) @party_members.sort! end end @actors.delete($game_actors[actor_id]) $game_player.refresh end def add_actor_to_party(actor_id) if @party_members.include?(actor_id) if @actors[@max_size - 1] != nil @party_members.push(@actors[@max_size - 1].id) @actors.delete_at(@max_size - 1) end @actors.push($game_actors[actor_id]) @party_members.delete(actor_id) end end end #================================================== # END Game_Party #================================================== #========================================================================== ==== # ** Window_Selectable #============================================================================== class Window_Selectable < Window_Base #-------------------------------------------------------------------------- # * Public Instance Variables #-------------------------------------------------------------------------- attr_accessor :cursor_height #-------------------------------------------------------------------------- # * Alias Initialization #-------------------------------------------------------------------------- alias custom_int initialize #-------------------------------------------------------------------------- # * Object Initialization #-------------------------------------------------------------------------- def initialize(x, y, width, height) custom_int(x, y, width, height) @cursor_height = 32 end #-------------------------------------------------------------------------- # * Get Top Row #-------------------------------------------------------------------------- def top_row # Divide y-coordinate of window contents transfer origin by 1 row # height of @cursor_height return self.oy / @cursor_height end #-------------------------------------------------------------------------- # * Set Top Row # row : row shown on top #-------------------------------------------------------------------------- def top_row=(row) # If row is less than 0, change it to 0 if row < 0 row = 0 end # If row exceeds row_max - 1, change it to row_max - 1 if row > row_max - 1 row = row_max - 1 end # Multiply 1 row height by 32 for y-coordinate of window contents # transfer origin self.oy = row * @cursor_height end #-------------------------------------------------------------------------- # * Get Number of Rows Displayable on 1 Page #-------------------------------------------------------------------------- def page_row_max # Subtract a frame height of 32 from the window height, and divide it by # 1 row height of @cursor_height return (self.height - 32) / @cursor_height end #-------------------------------------------------------------------------- # * Update Cursor Rectangle #-------------------------------------------------------------------------- def update_cursor_rect # If cursor position is less than 0 if @index < 0 self.cursor_rect.empty return end # Get current row row = @index / @column_max # If current row is before top row if row < self.top_row # Scroll so that current row becomes top row self.top_row = row end # If current row is more to back than back row if row > self.top_row + (self.page_row_max - 1) # Scroll so that current row becomes back row self.top_row = row - (self.page_row_max - 1) end # Calculate cursor width cursor_width = self.width / @column_max - 32 # Calculate cursor coordinates x = @index % @column_max * (cursor_width + 32) y = @index / @column_max * @cursor_height - self.oy if self.active == true # Update cursor rectangle self.cursor_rect.set(x, y, cursor_width, @cursor_height) end end end #========================================================================== ==== # ** Window_Command #============================================================================== class Window_Command < Window_Selectable #-------------------------------------------------------------------------- # * Unisable Item # index : item number #-------------------------------------------------------------------------- def undisable_item(index) draw_item(index, normal_color) end end #============================================================ #================================================== # Window_Party_Info #================================================== class Window_Party_Info < Window_Base def initialize super(0, 0, 640, 64) self.contents = Bitmap.new(width - 32, height - 32) refresh end def refresh self.contents.clear self.contents.draw_text(0, 0, 614, 32, "Please make a party of #{$game_party.min_size.to_s} to #{$game_party.max_size.to_s} members.", 1) end end #================================================== # END Window_Party_Info #================================================== #================================================== # Window_Party_Slots #================================================== class Window_Party_Slots < Window_Selectable def initialize super(0, 64, 320, 416) @item_max = 4 self.contents = Bitmap.new(width - 32, height - 32) self.index = 0 self.active = true refresh end def actors if @data[index] != nil return @data[index] end end def refresh @data = [] if self.contents != nil self.contents.dispose self.contents = nil end for i in 0...$game_party.actors.size @data.push($game_party.actors[i]) end @item_max = (@data.size + 1) if @item_max > 0 if @item_max > 4 @item_max = 4 end self.contents = Bitmap.new(width - 32, row_max * 96) for i in 0...@item_max draw_item(i) end end end def draw_item(index) @actor = @data[index] y = index * 96 x = 4 if $game_party.locked.include?(@actor.id) self.contents.font.color = disabled_color opacity = 128 else self.contents.font.color = normal_color opacity = 255 end if @actor != nil self.contents.draw_text(x + 100, y, 192, 32, @actor.name) draw_actor_hp(@actor, x + 100, y + 32) draw_actor_sp(@actor, x + 100, y + 64) bitmap = RPG::Cache.character(@actor.character_name, @actor.character_hue) cw = bitmap.width / 4 ch = bitmap.height / 4 facing = 0 src_rect = Rect.new(0, facing * ch, cw, ch) self.contents.blt(x + 24, y + 32, bitmap, src_rect, opacity) end end def update_cursor_rect if @index > -1 x = 0 y = index * 96 self.cursor_rect.set(x, y, (self.width - 32), 96) else self.cursor_rect.empty end end end #================================================== # END Window_Party_Slots #================================================== #================================================== # Window_Party_Extras #================================================== class Window_Party_Extras < Window_Selectable def initialize super(320, 64, 320, 416) self.cursor_height = 96 self.contents = Bitmap.new(width - 32, height - 32) self.index = -1 self.active = false refresh end def actors if @data != nil return @data[index] end end def refresh if self.contents != nil self.contents.dispose self.contents = nil end @data = [] for i in 0...$game_party.party_members.size @data.push($game_actors[$game_party.party_members[i]]) end @data.push(nil) @item_max = @data.size if @item_max > 0 self.contents = Bitmap.new(width - 32, row_max * 96) for i in 0...@item_max draw_item(i) end end end def draw_item(index) @actor = @data[index] y = index * 96 x = 4 if $game_party.locked.include?(@actor.id) self.contents.font.color = disabled_color opacity = 128 else self.contents.font.color = normal_color opacity = 255 end if @actor != nil self.contents.draw_text(x + 100, y, 192, 32, @actor.name) draw_actor_hp(@actor, x + 100, y + 32) draw_actor_sp(@actor, x + 100, y + 64) bitmap = RPG::Cache.character(@actor.character_name, @actor.character_hue) cw = bitmap.width / 4 ch = bitmap.height / 4 facing = 0 src_rect = Rect.new(0, facing * ch, cw, ch) self.contents.blt(x + 24, y + 32, bitmap, src_rect, opacity) end end end #=================================== # END Window_Party_Extras #=================================== #=================================== # Scene_Party_Change #=================================== class Scene_Party_Change def main @info_window = Window_Party_Info.new @slot_window = Window_Party_Slots.new @extra_window = Window_Party_Extras.new Graphics.transition loop do Graphics.update Input.update update if $scene != self break end end Graphics.freeze @info_window.dispose @slot_window.dispose @extra_window.dispose end def update @slot_window.update if @slot_window.active update_slot return end if @extra_window.active update_extra return end end def update_slot if Input.trigger?(Input::B) if $game_party.actors.size >= $game_party.min_size and $game_party.actors.size <= $game_party.max_size $game_player.refresh $game_system.se_play($data_system.cancel_se) $scene = Scene_Map.new else $game_system.se_play($data_system.buzzer_se) end end if Input.trigger?(Input::C) if $game_party.locked.include?(@slot_window.actors.id) == true if @slot_window.index != 0 $game_system.se_play($data_system.decision_se) @slot_window.active = false @extra_window.active = true @extra_window.index = 0 else $game_system.se_play($data_system.buzzer_se) end else $game_system.se_play($data_system.decision_se) @slot_window.active = false @extra_window.active = true @extra_window.index = 0 end end end def update_extra @extra_window.update if Input.trigger?(Input::B) $game_system.se_play($data_system.cancel_se) @slot_window.active = true @extra_window.active = false @extra_window.index = -1 end if Input.trigger?(Input::C) $game_system.se_play($data_system.decision_se) if $game_party.locked.include?(@extra_window.actors.id) $game_system.se_play($data_system.buzzer_se) return end if @extra_window.actors == nil if $game_party.actors[@slot_window.index] != nil $game_party.party_members.push($game_party.actors[@slot_window.index].id) $game_party.remove_actor_from_party($game_party.actors[@slot_window.index].id) $game_party.party_members.sort! @slot_window.refresh @extra_window.refresh @slot_window.active = true @extra_window.active = false @extra_window.index = -1 else @slot_window.active = true @extra_window.active = false @extra_window.index = -1 end else if $game_party.actors[@slot_window.index] != nil hold = @extra_window.actors $game_party.party_members.push($game_party.actors[@slot_window.index].id) $game_party.actors[@slot_window.index] = hold $game_party.party_members.delete_at(@extra_window.index) $game_party.party_members.sort! @slot_window.refresh @extra_window.refresh @slot_window.active = true @extra_window.active = false @extra_window.index = -1 else $game_party.actors[@slot_window.index] = @extra_window.actors $game_party.party_members.delete_at(@extra_window.index) $game_party.party_members.sort! @slot_window.refresh @extra_window.refresh @slot_window.active = true @extra_window.active = false @extra_window.index = -1 end end end end end #=================================== # Party Changing System by Leon_Westbrooke # -v 1.2 #---------------------------------------------------------------------- # Instructions: Place above main, but below all other default scripts. # # Features: # -Allows the player to make a party from the minimum to maximum size. # -Extra members are limitless. # -You can remove a person from the party and put it into reserve using: # $game_party.remove_actor_to_party(actor_id) # -You can remove a person from the reserve if they exist, and them into # the party: # $game_party.add_actor_to_party(actor_id) # -You can lock a character in reserve or active party by using: # $game_party.locked.push(actor_id) # -You can set the maximum and minimum number of the party in-game using: # $game_party.min_size = x # $game_party.max_size = x # (NOTE: Do NOT make the max size lower than the minimum size.) # -Allows you to use the default add/remove actors command. # (NOTE: If you remove an actor with this method, he is gone from both # the party and the reserve members.) # # Credits: # This setup uses SephirothSpawn's coding to simplify the cursor's position. # # # Command Quick-list: # $game_party.remove_actor_from_party(actor_id) # -Removes an actor from the party, and puts them in reserve. # $game_party.add_actor_to_party(actor_id) # -Replaces the last actor in the party with the actor in reserve. # $game_party.locked.push(actor_id) # -Locks the actor in place. # $game_party.min_size = x # $game_party.max_size = x # -Sets the minimum and maximum party size. # # # Notes: # This script rewrites these methods from Game_Party: # add_actor # remove_actor #===================================
#================================================== # Game_Party #================================================== class Game_Party
attr_accessor :party_members attr_accessor :move attr_accessor :locked attr_accessor :min_size attr_accessor :max_size alias leon_partyswitch_gameactor_initialize initialize
def initialize leon_partyswitch_gameactor_initialize @party_members = [] # Edit :This is to change if an actor is locked or not. To lock them, add # their id to the array below. @locked = [] @min_size = 1 @max_size = 4 end def add_actor(actor_id) actor = $game_actors[actor_id] if @actors.size < @max_size unless @actors.include?(actor) unless @party_members.include?(actor.id) @actors.push(actor) $game_player.refresh end end else unless @party_members.include?(actor.id) unless @actors.include?(actor) @party_members.push(actor.id) $game_player.refresh end end end end def remove_actor(actor_id) @actors.delete($game_actors[actor_id]) @party_members.delete(actor_id) $game_player.refresh end def remove_actor_from_party(actor_id) if @actors.include?($game_actors[actor_id]) unless @party_members.include?(actor_id) @party_members.push(actor_id) @party_members.sort! end end @actors.delete($game_actors[actor_id]) $game_player.refresh end
def add_actor_to_party(actor_id) if @party_members.include?(actor_id) if @actors[@max_size - 1] != nil @party_members.push(@actors[@max_size - 1].id) @actors.delete_at(@max_size - 1) end @actors.push($game_actors[actor_id]) @party_members.delete(actor_id) end end end #================================================== # END Game_Party #==================================================
#============================================================================== # ** Window_Selectable #============================================================================== class Window_Selectable < Window_Base #-------------------------------------------------------------------------- # * Public Instance Variables #-------------------------------------------------------------------------- attr_accessor :cursor_height #-------------------------------------------------------------------------- # * Alias Initialization #-------------------------------------------------------------------------- alias custom_int initialize #-------------------------------------------------------------------------- # * Object Initialization #-------------------------------------------------------------------------- def initialize(x, y, width, height) custom_int(x, y, width, height) @cursor_height = 32 end #-------------------------------------------------------------------------- # * Get Top Row #-------------------------------------------------------------------------- def top_row # Divide y-coordinate of window contents transfer origin by 1 row # height of @cursor_height return self.oy / @cursor_height end #-------------------------------------------------------------------------- # * Set Top Row # row : row shown on top #-------------------------------------------------------------------------- def top_row=(row) # If row is less than 0, change it to 0 if row < 0 row = 0 end # If row exceeds row_max - 1, change it to row_max - 1 if row > row_max - 1 row = row_max - 1 end # Multiply 1 row height by 32 for y-coordinate of window contents # transfer origin self.oy = row * @cursor_height end #-------------------------------------------------------------------------- # * Get Number of Rows Displayable on 1 Page #-------------------------------------------------------------------------- def page_row_max # Subtract a frame height of 32 from the window height, and divide it by # 1 row height of @cursor_height return (self.height - 32) / @cursor_height end #-------------------------------------------------------------------------- # * Update Cursor Rectangle #-------------------------------------------------------------------------- def update_cursor_rect # If cursor position is less than 0 if @index < 0 self.cursor_rect.empty return end # Get current row row = @index / @column_max # If current row is before top row if row < self.top_row # Scroll so that current row becomes top row self.top_row = row end # If current row is more to back than back row if row > self.top_row + (self.page_row_max - 1) # Scroll so that current row becomes back row self.top_row = row - (self.page_row_max - 1) end # Calculate cursor width cursor_width = self.width / @column_max - 32 # Calculate cursor coordinates x = @index % @column_max * (cursor_width + 32) y = @index / @column_max * @cursor_height - self.oy if self.active == true # Update cursor rectangle self.cursor_rect.set(x, y, cursor_width, @cursor_height) end end end
#============================================================================== # ** Window_Command #============================================================================== class Window_Command < Window_Selectable #-------------------------------------------------------------------------- # * Unisable Item # index : item number #-------------------------------------------------------------------------- def undisable_item(index) draw_item(index, normal_color) end end #============================================================
#================================================== # Window_Party_Info #================================================== class Window_Party_Info < Window_Base def initialize super(0, 0, 640, 64) self.contents = Bitmap.new(width - 32, height - 32) refresh end
def refresh self.contents.clear self.contents.draw_text(0, 0, 614, 32, "Please make a party of #{$game_party.min_size.to_s} to #{$game_party.max_size.to_s} members.", 1) end end #================================================== # END Window_Party_Info #==================================================
#================================================== # Window_Party_Slots #================================================== class Window_Party_Slots < Window_Selectable
def initialize super(0, 64, 320, 416) @item_max = 4 self.contents = Bitmap.new(width - 32, height - 32) self.index = 0 self.active = true refresh end def actors if @data[index] != nil return @data[index] end end
def refresh @data = [] if self.contents != nil self.contents.dispose self.contents = nil end for i in 0...$game_party.actors.size @data.push($game_party.actors[i]) end @item_max = (@data.size + 1) if @item_max > 0 if @item_max > 4 @item_max = 4 end self.contents = Bitmap.new(width - 32, row_max * 96) for i in 0...@item_max draw_item(i) end end end def draw_item(index) @actor = @data[index] y = index * 96 x = 4 if $game_party.locked.include?(@actor.id) self.contents.font.color = disabled_color opacity = 128 else self.contents.font.color = normal_color opacity = 255 end if @actor != nil self.contents.draw_text(x + 100, y, 192, 32, @actor.name) draw_actor_hp(@actor, x + 100, y + 32) draw_actor_sp(@actor, x + 100, y + 64) bitmap = RPG::Cache.character(@actor.character_name, @actor.character_hue) cw = bitmap.width / 4 ch = bitmap.height / 4 facing = 0 src_rect = Rect.new(0, facing * ch, cw, ch) self.contents.blt(x + 24, y + 32, bitmap, src_rect, opacity) end end def update_cursor_rect if @index > -1 x = 0 y = index * 96 self.cursor_rect.set(x, y, (self.width - 32), 96) else self.cursor_rect.empty end end end #================================================== # END Window_Party_Slots #==================================================
#================================================== # Window_Party_Extras #================================================== class Window_Party_Extras < Window_Selectable def initialize super(320, 64, 320, 416) self.cursor_height = 96 self.contents = Bitmap.new(width - 32, height - 32) self.index = -1 self.active = false refresh end def actors if @data != nil return @data[index] end end
def refresh if self.contents != nil self.contents.dispose self.contents = nil end @data = [] for i in 0...$game_party.party_members.size @data.push($game_actors[$game_party.party_members[i]]) end @data.push(nil) @item_max = @data.size if @item_max > 0 self.contents = Bitmap.new(width - 32, row_max * 96) for i in 0...@item_max draw_item(i) end end end def draw_item(index) @actor = @data[index] y = index * 96 x = 4 if $game_party.locked.include?(@actor.id) self.contents.font.color = disabled_color opacity = 128 else self.contents.font.color = normal_color opacity = 255 end if @actor != nil self.contents.draw_text(x + 100, y, 192, 32, @actor.name) draw_actor_hp(@actor, x + 100, y + 32) draw_actor_sp(@actor, x + 100, y + 64) bitmap = RPG::Cache.character(@actor.character_name, @actor.character_hue) cw = bitmap.width / 4 ch = bitmap.height / 4 facing = 0 src_rect = Rect.new(0, facing * ch, cw, ch) self.contents.blt(x + 24, y + 32, bitmap, src_rect, opacity) end end end #=================================== # END Window_Party_Extras #===================================
#=================================== # Scene_Party_Change #=================================== class Scene_Party_Change def main @info_window = Window_Party_Info.new @slot_window = Window_Party_Slots.new @extra_window = Window_Party_Extras.new Graphics.transition loop do Graphics.update Input.update update if $scene != self break end end Graphics.freeze @info_window.dispose @slot_window.dispose @extra_window.dispose end def update @slot_window.update if @slot_window.active update_slot return end if @extra_window.active update_extra return end end def update_slot if Input.trigger?(Input::B) if $game_party.actors.size >= $game_party.min_size and $game_party.actors.size <= $game_party.max_size $game_player.refresh $game_system.se_play($data_system.cancel_se) $scene = Scene_Map.new else $game_system.se_play($data_system.buzzer_se) end end if Input.trigger?(Input::C) if $game_party.locked.include?(@slot_window.actors.id) == true $game_system.se_play($data_system.buzzer_se) else $game_system.se_play($data_system.decision_se) @slot_window.active = false @extra_window.active = true @extra_window.index = 0 end end end def update_extra @extra_window.update if Input.trigger?(Input::B) $game_system.se_play($data_system.cancel_se) @slot_window.active = true @extra_window.active = false @extra_window.index = -1 end if Input.trigger?(Input::C) $game_system.se_play($data_system.decision_se) if $game_party.locked.include?(@extra_window.actors.id) $game_system.se_play($data_system.buzzer_se) return end if @extra_window.actors == nil if $game_party.actors[@slot_window.index] != nil $game_party.party_members.push($game_party.actors[@slot_window.index].id) $game_party.remove_actor_from_party($game_party.actors[@slot_window.index].id) $game_party.party_members.sort! @slot_window.refresh @extra_window.refresh @slot_window.active = true @extra_window.active = false @extra_window.index = -1 else @slot_window.active = true @extra_window.active = false @extra_window.index = -1 end else if $game_party.actors[@slot_window.index] != nil hold = @extra_window.actors $game_party.party_members.push($game_party.actors[@slot_window.index].id) $game_party.actors[@slot_window.index] = hold $game_party.party_members.delete_at(@extra_window.index) $game_party.party_members.sort! @slot_window.refresh @extra_window.refresh @slot_window.active = true @extra_window.active = false @extra_window.index = -1 else $game_party.actors[@slot_window.index] = @extra_window.actors $game_party.party_members.delete_at(@extra_window.index) $game_party.party_members.sort! @slot_window.refresh @extra_window.refresh @slot_window.active = true @extra_window.active = false @extra_window.index = -1 end end end end end And i want to do it manually because they might not be dead they just might be frozen forever. (To unfreeze u have to do some sort of quest) Edit:I'm sorry for it being jumbled idk wat to do about it D: hopefully it won't mess up the script right? ):
This post has been edited by jayjay5366: Feb 11 2012, 09:20 PM
__________________________
)@y
|
|
|
|
|
|
|
|
|
Feb 13 2012, 09:18 AM
|

Dark Jentleman

Group: Local Mod
Posts: 904
Type: Scripter
RM Skill: Skilled
Rev Points: 120

|
Done. Just copy&paste this above main CODE #============================================================================== #=#============================================================================ # #** Jens of Zanicuud Party_Change_Addons script v 1.0 # # -free use, just credit # # -free customization, however, posting on RRR the modified version is # # mandatory # # -you can find me on www.rpgrevolution.com #=#============================================================================ #==============================================================================
#================================================== # Window_Party_Slots #================================================== class Window_Party_Slots_Battle < Window_Selectable
def initialize super(0, 64, 320, 416) @item_max = 4 self.cursor_height = 96 self.contents = Bitmap.new(width - 32, height - 32) self.index = 0 self.active = true refresh end def actors if @data[index] != nil return @data[index] end end
def refresh @data = [] if self.contents != nil self.contents.dispose self.contents = nil end for i in 0...$game_party.actors.size @data.push($game_party.actors[i]) end @item_max = (@data.size + 1) if @item_max > 0 if @item_max > 4 @item_max = 4 end self.contents = Bitmap.new(width - 32, row_max * 96) for i in 0...@item_max draw_item(i) end end end def draw_item(index) @actor = @data[index] y = index * 96 x = 4 if $game_party.locked.include?(@actor.id) self.contents.font.color = disabled_color opacity = 128 else self.contents.font.color = normal_color opacity = 255 end if @actor != nil self.contents.draw_text(x + 100, y, 192, 32, @actor.name) draw_actor_hp(@actor, x + 100, y + 32) draw_actor_sp(@actor, x + 100, y + 64) bitmap = RPG::Cache.character(@actor.character_name, @actor.character_hue) cw = bitmap.width / 4 ch = bitmap.height / 4 facing = 0 src_rect = Rect.new(0, facing * ch, cw, ch) self.contents.blt(x + 24, y + 32, bitmap, src_rect, opacity) end end def update_cursor_rect if $game_temp.in_battle super else if @index > -1 x = 0 y = index * 96 self.cursor_rect.set(x, y, (self.width - 32), 96) else self.cursor_rect.empty end end end end #================================================== # END Window_Party_Slots #================================================== #============================================================================== # ** Game_Party #============================================================================== class Game_Party #-------------------------------------------------------------------------- # * replacements #-------------------------------------------------------------------------- def replacements size = @party_members.size minimum_size = [@min_size,size].min if size <= minimum_size return [] end return @party_members[minimum_size,size-minimum_size] end #-------------------------------------------------------------------------- # * can_replace? # returns false if there are no replacements and / or actor is locked. #-------------------------------------------------------------------------- def can_replace?(actor_id) return (!replacements.empty? and !@locked.include?(actor_id)) end #-------------------------------------------------------------------------- # * can_replace_someone? # returns false if there are no replacements and / or actor is locked. #-------------------------------------------------------------------------- def can_replace_someone? return !replacements.empty? end
end
#============================================================================== # ** Game_Actor #============================================================================== class Game_Actor < Game_Battler #-------------------------------------------------------------------------- # * valid_replacement? # returns false if actor is KO. #-------------------------------------------------------------------------- def valid_replacement? return !self.hp0? end end
#============================================================================== # ** Scene_Battle #============================================================================== class Scene_Battle #-------------------------------------------------------------------------- # * start_party_shift #-------------------------------------------------------------------------- def start_party_shift @help_window.set_text("Shift party members:",1) @slot_window = Window_Party_Slots_Battle.new @extra_window = Window_Party_Extras.new @slot_window.height = 256 @extra_window.height = 256 @party_shift = true @party_command_window.active = false @party_command_window.visible = false @slot_window.active = true end #-------------------------------------------------------------------------- # * update_party_shift #-------------------------------------------------------------------------- def update_party_shift #window update @extra_window.update @slot_window.update #slot window update if @slot_window.active update_shift_slot return end #extra window update if @extra_window.active update_shift_extra return end end #-------------------------------------------------------------------------- # * end_party_shift #-------------------------------------------------------------------------- def party_shift_end @slot_window.dispose @extra_window.dispose @party_shift = false @help_window.visible = false end #-------------------------------------------------------------------------- # * update slot #-------------------------------------------------------------------------- def update_shift_slot #case: Input B (ESC, X) if Input.trigger?(Input::B) #if size is correct, then exit shift screen if $game_party.actors.size >= $game_party.min_size and $game_party.actors.size <= $game_party.max_size @status_window.refresh $game_system.se_play($data_system.cancel_se) party_shift_end start_phase2 else #else: buzzer! $game_system.se_play($data_system.buzzer_se) end end #case: Input C (Enter, C, Spacebar) if Input.trigger?(Input::C) #if actor is locked, then buzzer! if $game_party.locked.include?(@slot_window.actors.id) == true $game_system.se_play($data_system.buzzer_se) else #else: begin shifting $game_system.se_play($data_system.decision_se) @slot_window.active = false @extra_window.active = true @extra_window.index = 0 end end end #-------------------------------------------------------------------------- # * update extra #-------------------------------------------------------------------------- def update_shift_extra #case: Input B (ESC, X) if Input.trigger?(Input::B) $game_system.se_play($data_system.cancel_se) @slot_window.active = true @extra_window.active = false @extra_window.index = -1 end #case: Input C (Enter, C, Spacebar) if Input.trigger?(Input::C) $game_system.se_play($data_system.decision_se) #if replacement locked, then buzzer. if $game_party.locked.include?(@extra_window.actors.id) $game_system.se_play($data_system.buzzer_se) return end #if no replacements selected then replace members. if @extra_window.actors == nil #shift window if no party actor selected. if $game_party.actors[@slot_window.index] != nil $game_party.party_members.push($game_party.actors[@slot_window.index].id) $game_party.remove_actor_from_party($game_party.actors[@slot_window.index].id) $game_party.party_members.sort! @slot_window.refresh @extra_window.refresh @slot_window.active = true @extra_window.active = false @extra_window.index = -1 else @slot_window.active = true @extra_window.active = false @extra_window.index = -1 end else #if replacement selected then replace members. if $game_party.actors[@slot_window.index] != nil hold = @extra_window.actors $game_party.party_members.push($game_party.actors[@slot_window.index].id) $game_party.actors[@slot_window.index] = hold $game_party.party_members.delete_at(@extra_window.index) $game_party.party_members.sort! @slot_window.refresh @extra_window.refresh @slot_window.active = true @extra_window.active = false @extra_window.index = -1 else $game_party.actors[@slot_window.index] = @extra_window.actors $game_party.party_members.delete_at(@extra_window.index) $game_party.party_members.sort! @slot_window.refresh @extra_window.refresh @slot_window.active = true @extra_window.active = false @extra_window.index = -1 end end @status_window.refresh end end
#-------------------------------------------------------------------------- # * Frame Update (party command phase) #-------------------------------------------------------------------------- def update_phase2 # If shifting if @party_shift #update_shift update_party_shift return end # If C button was pressed if Input.trigger?(Input::C) and !@party_shift # Branch by party command window cursor position case @party_command_window.index when 0 # fight # Play decision SE $game_system.se_play($data_system.decision_se) # Start actor command phase start_phase3 when 1 # escape # If it's not possible to escape if $game_temp.battle_can_escape == false # Play buzzer SE $game_system.se_play($data_system.buzzer_se) return end # Play decision SE $game_system.se_play($data_system.decision_se) # Escape processing update_phase2_escape when 2 # Play decision SE $game_system.se_play($data_system.decision_se) # Start party shift phase start_party_shift end return end end end #class end
#============================================================================== # ** Window_PartyCommand #------------------------------------------------------------------------------ # This window is used to select whether to fight or escape on the battle # screen. #==============================================================================
class Window_PartyCommand < Window_Selectable #-------------------------------------------------------------------------- # * Object Initialization #-------------------------------------------------------------------------- def initialize super(0, 0, 640, 64) self.contents = Bitmap.new(width - 32, height - 32) self.back_opacity = 160 @commands = ["Fight", "Escape", "Party"] @item_max = 3 @column_max = 3 draw_item(0, normal_color) draw_item(1, $game_temp.battle_can_escape ? normal_color : disabled_color) draw_item(2, $game_party.can_replace_someone? ? normal_color : disabled_color) self.active = false self.visible = false self.index = 0 end #-------------------------------------------------------------------------- # * Draw Item # index : item number # color : text character color #-------------------------------------------------------------------------- def draw_item(index, color) self.contents.font.color = color rect = Rect.new(80 + index * 160 + 4, 0, 128 - 10, 32) self.contents.fill_rect(rect, Color.new(0, 0, 0, 0)) self.contents.draw_text(rect, @commands[index], 1) end #-------------------------------------------------------------------------- # * Cursor Rectangle Update #-------------------------------------------------------------------------- def update_cursor_rect self.cursor_rect.set(80 + index * 160, 0, 128, 32) end end Ask for troubleshooting anytime, just remind I'm taking two days of semi-vacation in order to study. Jens
__________________________
|
|
|
|
|
|
|
|
|
Feb 13 2012, 02:32 PM
|

Level 1

Group: Member
Posts: 14
Type: Developer
RM Skill: Intermediate

|
Thx a bunch It work exactly how i wanted it Is it okay if i ask for more help with scripts if it comes by?
__________________________
)@y
|
|
|
|
|
|
|
|
|
Mar 15 2012, 02:19 PM
|

Level 1

Group: Member
Posts: 14
Type: Developer
RM Skill: Intermediate

|
I totally forgot the only reason i wanted a side view battle system was that i couldnt find a good real time battle system script! All of the real time battle systems i found were terrible. The monsters didn't attack. some of them were 2 scripts in one like with animated battlers. I just dont want the charactrers and monsters taking turns like the battle system rmxp comes with. Can you make/find a real time battle system that action bar that acually goes by ur speed? Please and thank you!
__________________________
)@y
|
|
|
|
|
|
|
|
  |
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:
RPG RPG Revolution is an Privacy
Policy and Legal
|
|