Jump to content

GantzRPG

Member
  • Content Count

    21
  • Joined

  • Last visited

About GantzRPG

  • Rank
    Member

Recent Profile Visitors

1,281 profile views
  1. Can anyone convert this script to rpg maker mv? I would love to have a resident evil style inventory for rpg maker mv, as abs I use alpha ABS P.S. I can also pay for the job module RE_MENU BAR_POSITION_X = 3 BAR_POSITION_Y = 0 end module Special_Map Archive_ID = 12 Archive_x = 17 Archive_y = 13 Option_ID = 11 Option_x = 17 Option_y = 13 Map_ID_Variable = 6 Coord_x_Variable = 7 Coord_y_Variable = 8 def self.set_coordinates $game_variables[Map_ID_Variable] = $game_map.map_id $game_variables[Coord_x_Variable] = $game_player.x $game_variables[Coord_y_Variable] = $game_player.y end end class Scene_Menu < Scene_MenuBase alias re_inventory_create_command_window create_command_window def create_command_window re_inventory_create_command_window @command_window.set_handler(:inventory, method(:command_inventory)) end def command_inventory SceneManager.call(Scene_RE_Menu) end end class Window_MenuCommand < Window_Command alias re_inventory_add_main_commands add_main_commands def add_main_commands add_command("RE Inventory", :inventory, main_commands_enabled) re_inventory_add_main_commands end end class Scene_RE_Menu < Scene_Base attr_reader :help_window def start super Special_Map.set_coordinates load_windowskin $game_party.last_item.object = nil create_menu_window create_face_window create_name_window create_life_window create_help_window create_weapon_window create_ammo_window create_equip_window create_use_window create_item_window @item_index = 0 @item_window.select(-1) @menu_window.select(1) @menu_window.activate create_background end def load_windowskin @windowskin = Bitmap.new("Graphics/System/re_menu_skin") @windowskin2 = Bitmap.new("Graphics/System/re_menu_ski2") end def create_menu_window @menu_window = Window_RE_Command.new(167,10) @menu_window.windowskin = @windowskin @menu_window.set_handler(:option, method(:open_option)) @menu_window.set_handler(:item, method(:go_inventory)) @menu_window.set_handler(:exit, method(:return_map)) @menu_window.set_handler(:cancel, method(:return_scene)) end def create_face_window @face_window = Window_Base.new(0,43,100,100) @face_window.windowskin = @windowskin @face_window.padding = 8 @face_window.contents = Bitmap.new(84,84) @face_window.draw_actor_face($game_party.members[0],-6,-6) @face_window.hide end def create_name_window @name_window = Window_Base.new(0,138,100,48) @name_window.windowskin = @windowskin @name_window.draw_text(-16,0,100,24,$game_party.members[0].name,1) @name_window.hide end def create_life_window @life_window = Window_Base.new(100,54,259,50) @life_window.windowskin = @windowskin life_refresh end def create_help_window @help_window = Window_Help2.new(3,305,358,Graphics.height - 30) @help_window.windowskin = @windowskin end def create_weapon_window @weapon_window = Window_Base.new(0,53,Graphics.width-440,90) @weapon_window.windowskin = @windowskin @weapon_window.draw_RE_weapon($game_player.actor.weapons[0],0,0) if $game_player.actor.weapons[0] end def create_ammo_window @ammo_window = Window_Base.new(430,90+48,Graphics.width-430,48) @ammo_window.windowskin = @windowskin ammo_refresh @ammo_window.hide end def create_equip_window @equip_window = Window_RE_Equip.new(248,130+48) @equip_window.windowskin = @windowskin2 @equip_window.set_handler(:cancel, method(:item_back)) @equip_window.set_handler(:equip, method(:equip_weapon)) @equip_window.set_handler(:remove, method(:remove_weapon)) @equip_window.set_handler(:reload, method(:reload_weapon)) @equip_window.deactivate @equip_window.hide end def create_use_window @use_window = Window_RE_Use.new(248,130+48) @use_window.windowskin = @windowskin2 @use_window.set_handler(:cancel, method(:item_back)) @use_window.set_handler(:use, method(:use_item)) @use_window.deactivate @use_window.hide end def create_item_window @item_window = Window_RE_Item.new(359,20+33,191,395-48) #(353,40+48,191,375-48) New Version (353,10+33,191,400-48) @item_window.windowskin = @windowskin @item_window.set_handler(:ok, method(:on_item_ok)) @item_window.set_handler(:cancel, method(:exit_inventory)) @item_window.refresh end def create_background @background_sprite = Sprite.new @background_sprite.bitmap = Cache.picture ("Background Inventory") @background_sprite.x = 0 @background_sprite.y = 0 end def item_back @use_window.hide @equip_window.hide @item_window.refresh @item_window.activate end def on_item_ok $game_party.last_item.object = @item_window.item if @item_window.item.is_a?(RPG::Item) @use_window.set_item(@item_window.item) @use_window.refresh @use_window.activate @use_window.show elsif @item_window.item.is_a?(RPG::Weapon) @equip_window.set_item(@item_window.item) @equip_window.refresh @equip_window.activate @equip_window.show else RPG::SE.stop @item_window.activate end end def item @item_window.item end def equip_weapon $game_player.actor.change_equip(0,@item_window.item) weapon_refresh item_back end def remove_weapon $game_player.actor.change_equip(0,nil) weapon_refresh item_back end def reload_weapon weapon = $weapons.find{|weapon| weapon.weapon.name == $data_weapons[item.id].name} $game_party.items.each { |item| if item.id == weapon.magazine.id $game_party.lose_item(weapon.magazine,1) weapon.bullets += weapon.max Audio.se_play("Audio/Se/#{weapon.wav_name}_reload", 100, 100) break end } if weapon == $game_player.equipped_weapon weapon_refresh else ammo_refresh end item_back end def ammo_refresh @ammo_window.contents.clear if $game_player.equipped_weapon != nil string = sprintf( "Munizioni : %d",$game_player.equipped_weapon.bullets) else string ="" end @ammo_window.draw_text(0,0,Graphics.width-430,24,string,0) end def weapon_refresh @weapon_window.contents.clear @weapon_window.draw_RE_weapon($game_player.actor.weapons[0],0,0) if $game_player.actor.weapons[0] ammo_refresh end def item_target_actors if !item.for_friend? [] elsif item.for_all? $game_party.members else [$game_player.actor] end end #-------------------------------------------------------------------------- # * Use Item on Actor #-------------------------------------------------------------------------- def use_item_to_actors user = $game_player.actor item_target_actors.each do |target| item.repeats.times { target.item_apply(user, item) } end end #-------------------------------------------------------------------------- # * Use Item #-------------------------------------------------------------------------- def use_item Sound.play_use_item $game_player.actor.use_item(item) use_item_to_actors check_common_event check_gameover weapon_refresh life_refresh RPG::BGS.stop item_back end #-------------------------------------------------------------------------- # * Determine if Common Event Is Reserved # Transition to the map screen if the event call is reserved. #-------------------------------------------------------------------------- def check_common_event SceneManager.goto(Scene_Map) if $game_temp.common_event_reserved? end def life_refresh bar1 = Bitmap.new("Graphics/System/life_bar") bar2 = Bitmap.new("Graphics/System/blood_bar") x = RE_MENU::BAR_POSITION_X y = RE_MENU::BAR_POSITION_Y @life_window.contents.blt(x,y,bar2,bar2.rect) rate = $game_player.actor.hp*1.0/$game_player.actor.mhp rect = Rect.new(0,0,bar1.width * rate,bar1.height) @life_window.contents.blt(x,y,bar1,rect) end def go_inventory @item_window.select(0) @menu_window.select(-1) @menu_window.deactivate @item_window.activate end def exit_inventory @help_window.clear @item_index = @item_window.index @item_window.select(-1) @item_window.deactivate @menu_window.select(1) @menu_window.activate end def open_option $game_player.transparent = true $game_system.save_bgm RPG::BGS.stop $game_player.reserve_transfer(Special_Map::Option_ID,Special_Map::Option_x,Special_Map::Option_y) $game_player.perform_transfer SceneManager.call(Scene_Map) $game_switches[10] = false end def open_archive $game_player.transparent = true $game_system.save_bgm RPG::BGS.stop $game_player.reserve_transfer(Special_Map::Archive_ID,Special_Map::Archive_x,Special_Map::Archive_y) $game_player.perform_transfer SceneManager.call(Scene_Map) $game_switches[10] = false end def return_map map = $game_variables[Special_Map::Map_ID_Variable] x = $game_variables[Special_Map::Coord_x_Variable] y = $game_variables[Special_Map::Coord_y_Variable] if $game_map.map_id != map #se esco da un menu... $game_player.reserve_transfer(map,x,y) #ritorna nella mappa $game_system.replay_bgm #Riparte la bgm $game_switches[980] = true #si attiva la switch per togliere la dissolvenza $game_temp.reserve_common_event(43) #Si attiva l'evento comune per togliere la dissolvenza end return_scene end end class Window_RE_Equip < Window_Command def initialize(x,y) super(x,y) end def window_width return (Graphics.width-430) end def make_command_list add_command("Equip", :equip, equip_ok?) add_command("Rimuovi", :remove, remove_ok?) add_command("Ricarica", :reload, reload_ok?) end def reload_ok? if @item a = $weapons.find{|weapon| weapon.weapon.name == $data_weapons[@item.id].name} a && a.bullets == 0 else b = false end end def equip_ok? @item != $game_player.actor.weapons[0] end def remove_ok? @item == $game_player.actor.weapons[0] end def set_item(item) @item = item end end class Window_RE_Use < Window_Command def initialize(x,y) super(x,y) end def window_width return (Graphics.width-430) end def make_command_list add_command("Usa", :use, use_ok?) end def use_ok? actor = $game_player.actor actor.usable?(@item) && actor.item_test(actor,@item) end def set_item(item) @item = item end end #============================================================================== # ** Window_ItemList #------------------------------------------------------------------------------ # This window displays a list of party items on the item screen. #============================================================================== class Window_RE_Item < Window_Selectable #-------------------------------------------------------------------------- # * Object Initialization #-------------------------------------------------------------------------- def initialize(x, y, width, height) super(x, y, width, height) @help_window = SceneManager.scene.help_window @data = [] end #-------------------------------------------------------------------------- # * Get Digit Count #-------------------------------------------------------------------------- def col_max return 2 end def item_width return 80 end def item_height return 80 end def spacing return 0 end #-------------------------------------------------------------------------- # * Get Number of Items #-------------------------------------------------------------------------- def item_max @data ? @data.size : 1 end #-------------------------------------------------------------------------- # * Get Item #-------------------------------------------------------------------------- def item @data && index >= 0 ? @data[index] : nil end #-------------------------------------------------------------------------- # * Include in Item List? #-------------------------------------------------------------------------- def include?(item) return true end #-------------------------------------------------------------------------- # * Create Item List #-------------------------------------------------------------------------- def make_item_list actor = $game_party.members[0] @data = actor.weapons @data += $game_party.all_items.select {|item| include?(item) } # @data.push(nil) if include?(nil) end #-------------------------------------------------------------------------- # * Restore Previous Selection Position #-------------------------------------------------------------------------- def select_last select(@data.index($game_party.last_item.object) || 0) end #-------------------------------------------------------------------------- # * Draw Item #-------------------------------------------------------------------------- def draw_item(index) item = @data[index] if item rect = item_rect(index) if item.is_a?(RPG::Weapon) draw_RE_weapon(item,rect.x,rect.y+10) else draw_RE_item(item,rect.x,rect.y+10) end end end #-------------------------------------------------------------------------- # * Update Help Text #-------------------------------------------------------------------------- def update_help @help_window.set_item(item) end #-------------------------------------------------------------------------- # * Refresh #-------------------------------------------------------------------------- def refresh make_item_list create_contents draw_all_items select_last end end class Window_Help2 < Window_Base #-------------------------------------------------------------------------- # * Object Initialization #-------------------------------------------------------------------------- def initialize(x,y,width,height) super(x,y,width,height) end #-------------------------------------------------------------------------- # * Set Text #-------------------------------------------------------------------------- def set_text(text) if text != @text @text = text refresh end end #-------------------------------------------------------------------------- # * Clear #-------------------------------------------------------------------------- def clear set_text("") end #-------------------------------------------------------------------------- # * Set Item # item : Skills and items etc. #-------------------------------------------------------------------------- def set_item(item) set_text(item ? item.name + "" + item.description : "") end #-------------------------------------------------------------------------- # * Refresh #-------------------------------------------------------------------------- def refresh contents.clear self.contents.font.size = 20 # draw_text_ex(4, 0, @text) a = @text.scan(/(.+)/) draw_text(4,0, width , 24, a[0][0]) if a[0] draw_text(4,24, width , 24, a[1][0]) if a[1] end end class Window_Base def draw_RE_weapon(item, x, y, enabled = true) bmp = Bitmap.new(90,70) bmp.fill_rect(bmp.rect,Color.new(255,255,255)) bitmap = Cache.RE_weapon(item.name) rescue bmp a = $weapons.find{|weapon| weapon.weapon.name == $data_weapons[item.id].name} image = Bitmap.new(90,70) image.blt((80-bitmap.width)/2,(60-bitmap.height)/2,bitmap,bitmap.rect) image.draw_text(-15,40,85,20,a.bullets,2) if a rect = Rect.new(0,0,90,70) contents.blt(x, y, image, rect, enabled ? 255 : translucent_alpha) bmp.dispose end def draw_RE_item(item, x, y, enabled = true) bmp = Bitmap.new(90,70) bmp.fill_rect(bmp.rect,Color.new(255,255,255)) bitmap = Cache.RE_item(item.name) rescue bmp image = Bitmap.new(90,70) image.blt((80-bitmap.width)/2,(60-bitmap.height)/2,bitmap,bitmap.rect) image.draw_text(-15,40,85,20,$game_party.item_number(item),2) rect = Rect.new(0,0,90,70) contents.blt(x,y,image, rect, enabled ? 255 : translucent_alpha) bmp.dispose end end class Window_RE_Command < Window_HorzCommand def window_width return Graphics.width end def make_command_list add_command("", :option) add_command("", :item) add_command("", :exit) end def col_max return 6 end def spacing return 1 end def item_width (width - standard_padding * 1 + spacing) / col_max - spacing #10 end end module Cache def self.RE_weapon(filename) load_bitmap("Graphics/Weapons/", filename) end def self.RE_item(filename) load_bitmap("Graphics/Items/", filename) end end
  2. GantzRPG

    RE WEAPONS SYSTEM 2 PROBLEM GRAPHICS

    OK it works thank you very much for the time you dedicated, you can close the topic
  3. GantzRPG

    RE WEAPONS SYSTEM 2 PROBLEM GRAPHICS

    nothing to do, the problem remains https://www.youtube.com/watch?v=BGIjf57HFJE&feature=youtu.be
  4. GantzRPG

    RE WEAPONS SYSTEM 2 PROBLEM GRAPHICS

    Mmmh,the problem still exists. Watch the video, so you'll understand https://www.youtube.com/watch?v=6MNypSk-mOw&feature=youtu.be
  5. GantzRPG

    RE WEAPONS SYSTEM 2 PROBLEM GRAPHICS

    I did, but it is still the weapon graphics after removing the weapon from the inventory, I would either remove that hide it https://www.youtube.com/watch?v=810LcB4hptI&feature=youtu.be This new video shows you what I mean
  6. GantzRPG

    RE WEAPONS SYSTEM 2 PROBLEM GRAPHICS

    When I try to remove the gun from the inventory, the graphics of the weapon remains on the character https://www.youtube.com/watch?v=MLoWmSNAyL4&feature=youtu.be Watch full screen 1080p
  7. GantzRPG

    RE WEAPONS SYSTEM 2 PROBLEM GRAPHICS

    It works however I should solve one last issue. Basically when you finish the game, you will unlock extra mode, with another part of the game, I wish the weapon removed from the inventory, I tried to remove it but I can't do it, can you help me?
  8. GantzRPG

    RE WEAPONS SYSTEM 2 PROBLEM GRAPHICS

    In the game there will be a scene where I'm changing character, and I want the weapon in this scene is invisible https://www.youtube.com/watch?v=RxFCMhH41Ao&feature=youtu.be Changing character, the weapon is still visible
  9. GantzRPG

    RE WEAPONS SYSTEM 2 PROBLEM GRAPHICS

    It works but I have to solve other problems 2 https://www.youtube.com/watch?v=nz_wQRmmcgk&feature=youtu.be It works, but the character can shoot the same https://www.youtube.com/watch?v=2wnVW07lSX8 When changing the character with another character, the weapon must remain invisible and must not be operated
  10. GantzRPG

    RE WEAPONS SYSTEM 2 PROBLEM GRAPHICS

    I wish when the character is invisible in a scene, the weapon becomes invisible, but apparently the weapon remains visible... There is a command script to equip and remove the equipped weapon? https://www.youtube.com/watch?v=t6F5wNpP3gk&feature=youtu.be
  11. Bump ( Forgive me but I desperately need help in solving the problem )
  12. User Graphic = $Axe User Anime Speed = 18 Tool Cooldown = 20 Tool Graphic = nil Tool Index = 0 Tool Size = 1 Tool Distance = 1 Tool Effect Delay = 10 Tool Destroy Delay = 20 Tool Speed = 5 Tool Cast Time = 0 Tool Cast Animation = 0 Tool Blow Power = 1 Tool Piercing = true Tool Animation When = Tool Animation Repeat = false Tool Special = nil Tool Target = false Tool Invoke Skill = 0 Tool Guard Rate = 0 Tool Knockdown Rate = 40 Tool Sound Se = nil Tool Cooldown Display = false Tool Item Cost = 0 Tool Short Jump = false Tool Through = true Tool Priority = 1 Tool Hit Shake = false Tool Self Damage = false Tool Combo Tool =
  13. Guys I have a problem, the enemy doesn't strike me Any solution? https://www.youtube.com/watch?v=OPgD_jSwCUE
×