Ayene - Nie 31 Sty, 2010 23:18 Temat postu: HUD Ekwipunku na mapie [VX]alintes - Pon 01 Lut, 2010 08:26 Wow! Fajny ten skrypt tylko szkoda, że na VX, czy mogłabyś Ayene przerobic ten skrypt na Xp, bo by mi się przydał w projekcie?KillYou - Pon 01 Lut, 2010 12:55 Ayene, czy da się/którym klawiszem przełączyć ekwipunek na innego bohatera?Ayene - Pon 01 Lut, 2010 14:00 Chyba da radę Zmień skrypt na poniższy:
Spoiler:
Kod:
#==============================================================================
# MOG HUD Equip V1.1 VX
# Autor XP: Moghunter
# Przełożone na VX przez Ayene (mam nadzieję, że będzie 'śmigać' :P
#==============================================================================
if true # True = wyświetla HUD / False = nie wyświetla
module MOG
# Położenie HUD - współrzędne x i y
EQPMAPX = 340 # współrzędna x
EQPMAPY = 320 # współrzędna y
$mogscript = {} if $mogscript == nil
$mogscript["mpequip"] = true
#==============================================================================
# Window_Base
#==============================================================================
class Window_Base < Window
def draw_equip_map(item, x, y)
if item == nil
return
end
draw_icon(item.icon_index , x + 3 , y + 34)
end
def draw_mequip(x, y)
mequip = Cache.picture("Mequip")
cw = mequip.width
ch = mequip.height
src_rect = Rect.new(0, 0, cw, ch)
self.contents.blt(x , y - ch + 65 ,mequip, src_rect)
end
end
#==============================================================================
# Scene_Map
#==============================================================================
class Scene_Map
alias ayene_start start
def start
@index = 0
new_equip_hud
ayene_start
end
alias ayene_terminate terminate
def terminate
ayene_terminate
@eqmap.dispose
end
alias mog8_update update
def update
if $game_switches[MOG::EQPMAPVIS] == false
@eqmap.visible = true
else
@eqmap.visible = false
end
if $eref == true
@eqmap.refresh
$eref = false
end
if Input.trigger?(Input::R)
if @index == $game_party.members.size - 1
@index = 0
else
@index += 1
end
elsif Input.trigger?(Input::L)
if @index == 0
@index = $game_party.members.size - 1
else
@index -= 1
end
end
new_equip_hud if @index != @actor.index
mog8_update
end
def new_equip_hud
@actor = $game_party.members[@index]
@eqmap.dispose if !@eqmap.nil?
@eqmap = Window_Equipmap.new(@actor)
@eqmap.x = MOG::EQPMAPX
@eqmap.y = MOG::EQPMAPY
if $game_switches[MOG::EQPMAPVIS] == false
@eqmap.visible = true
else
@eqmap.visible = false
end
end
end
#==============================================================================
# Game_Map
#==============================================================================
class Game_Map
attr_accessor :eref
end
class Game_Interpreter
def eref
$eref = true
end
alias mog319ref command_319
def command_319
eref
return mog319ref
end
end
end
Wyświetlany ekwipunek zmienia się za pomocą klawiszy L i R (domyślnie Page Up i Down)KillYou - Pon 01 Lut, 2010 18:26 Dzięki Ayene! Klawisze działają!krychapl - Sro 10 Lut, 2010 21:40 Dałoby się przerobić ten skrypt żeby pokazywał to co dodaje rozszerzenie ekwipunku?Ayene - Sro 10 Lut, 2010 22:03 Nie wszystkie skrypty są ze sobą kompatybilne. To o co prosisz wymagałoby zbyt wielu przeróbek.krychapl - Sro 10 Lut, 2010 22:23 Dobra użyje tego co jest.Asantos - Nie 21 Lut, 2010 15:08 a jak można ustawić, że kiedy wciśniemy "u" to okno się ukryje/pojawi?
to samo pytanie dotyczy okienka hp,mp i pd bohatera (HUD)Ayene - Nie 21 Lut, 2010 15:27 Okienko ukrywa się, gdy wciśniesz 'D' (U nie jest domyślnie obsługiwane przez program):
Sprawdź, czy o to Tobie chodziło:
Spoiler:
Kod:
#==============================================================================
# MOG HUD Equip V1.1 VX
# Autor XP: Moghunter
# Przełożone na VX przez Ayene (mam nadzieję, że będzie 'śmigać' :P
#==============================================================================
if true # True = wyświetla HUD / False = nie wyświetla
module MOG
# Położenie HUD - współrzędne x i y
EQPMAPX = 340 # współrzędna x
EQPMAPY = 320 # współrzędna y
PRZYCIK_UKRYCIA = Input::Z # "D" na klawiaturze
end
$mogscript = {} if $mogscript == nil
$mogscript["mpequip"] = true
#==============================================================================
# Window_Base
#==============================================================================
class Window_Base < Window
def draw_equip_map(item, x, y)
if item == nil
return
end
draw_icon(item.icon_index , x + 3 , y + 34)
end
def draw_mequip(x, y)
mequip = Cache.picture("Mequip")
cw = mequip.width
ch = mequip.height
src_rect = Rect.new(0, 0, cw, ch)
self.contents.blt(x , y - ch + 65 ,mequip, src_rect)
end
end
#==============================================================================
# Scene_Map
#==============================================================================
class Scene_Map
alias ayene_start start
def start
@index = 0
new_equip_hud
ayene_start
end
alias ayene_terminate terminate
def terminate
ayene_terminate
@eqmap.dispose
end
alias mog8_update update
def update
if $game_switches[MOG::EQPMAPVIS] == false
@eqmap.visible = true
else
@eqmap.visible = false
end
if Input.trigger?(MOG::PRZYCIK_UKRYCIA)
if $game_switches[MOG::EQPMAPVIS] == false
$game_switches[MOG::EQPMAPVIS] = true
else
$game_switches[MOG::EQPMAPVIS] = false
end
return
end
if $eref == true
@eqmap.refresh
$eref = false
end
if Input.trigger?(Input::R)
if @index == $game_party.members.size - 1
@index = 0
else
@index += 1
end
elsif Input.trigger?(Input::L)
if @index == 0
@index = $game_party.members.size - 1
else
@index -= 1
end
end
if Input.trigger?(Input::F5)
@actor.change_equip(0, nil)
end
new_equip_hud # if @index != @actor.index
mog8_update
end
def new_equip_hud
@actor = $game_party.members[@index]
@eqmap.dispose if !@eqmap.nil?
@eqmap = Window_Equipmap.new(@actor)
@eqmap.x = MOG::EQPMAPX
@eqmap.y = MOG::EQPMAPY
if $game_switches[MOG::EQPMAPVIS] == false
@eqmap.visible = true
else
@eqmap.visible = false
end
if Input.trigger?(MOG::PRZYCIK_UKRYCIA)
if $game_switches[MOG::EQPMAPVIS] == false
$game_switches[MOG::EQPMAPVIS] = true
else
$game_switches[MOG::EQPMAPVIS] = false
end
return
end
end
end
#==============================================================================
# Game_Map
#==============================================================================
class Game_Map
attr_accessor :eref
end
class Game_Interpreter
def eref
$eref = true
end
alias mog319ref command_319
def command_319
eref
return mog319ref
end
end
end
Asantos - Nie 21 Lut, 2010 15:47 a jeśli chodzi o HUD z informacjami bohatera?Ayene - Nie 21 Lut, 2010 17:02 Wejdź w skrypt i znajdź (linijka 6):
Kod:
POŁOŻENIE_HUD = 2
i po nim dodaj:
Kod:
PRZYCIK_UKRYCIA = Input::Z # "D" na klawiaturze
Następnie znajdź (linijka 184):
Kod:
return if !HUD_HP_MP_EXP_NAME_FACE_LEVEL::CYCLE
po tym dodaj:
Kod:
if Input.trigger?(AYENE::PRZYCIK_UKRYCIA)
if @hp_mp_exp_name_face_hud.visible
hud(false)
else
hud(true)
end
return
end
Asantos - Nie 21 Lut, 2010 18:19 nie muszę chyba mówić
ale powiem! DziĘkujĘ Ayene :)HESEE - Sob 05 Mar, 2011 09:55 Da radę go na środek przenieść.
Dół środek.Ayene - Sob 05 Mar, 2011 10:10 HESEE, czytaj instrukcję
Kod:
EQPMAPX = 340 # współrzędna x
EQPMAPY = 320 # współrzędna y
HESEE - Sob 05 Mar, 2011 10:42 Przepraszam nie zauważyłem.Mikołaj - Sob 05 Mar, 2011 15:01 Spoko skrypt MrBoomGood - Pon 02 Maj, 2011 22:32 Skrypt super! Przyda mi się do gry!aragorn7015 - Nie 27 Maj, 2012 19:08 Witam, a czy da się zrobić tak żeby pisało kogo to jest wyposażenie?
Czy jest to za trudne? Jeśli tak to trudno...Ayene - Nie 27 Maj, 2012 20:42 Sprawdź to:
Spoiler:
Kod:
#==============================================================================
# MOG HUD Equip V1.1 VX
# Autor XP: Moghunter
# Przełożone na VX przez Ayene (mam nadzieję, że będzie 'śmigać' :P
#==============================================================================
if true # True = wyświetla HUD / False = nie wyświetla
module MOG
# Położenie HUD - współrzędne x i y
EQPMAPX = 340 # współrzędna x
EQPMAPY = 300 # współrzędna y
ACTOR_NAME = true
$mogscript = {} if $mogscript == nil
$mogscript["mpequip"] = true
#==============================================================================
# Window_Base
#==============================================================================
class Window_Base < Window
def draw_equip_map(item, x, y)
if item == nil
return
end
draw_icon(item.icon_index , x + 3 , y + 34)
end
def draw_mequip(x, y)
mequip = Cache.picture("Mequip")
cw = mequip.width
ch = mequip.height
src_rect = Rect.new(0, 0, cw, ch)
self.contents.blt(x , y - ch + 65 ,mequip, src_rect)
end
end
alias ayene_terminate terminate
def terminate
ayene_terminate
@eqmap.dispose unless @eqmap.disposed?
end
alias mog8_update update
def update
if $game_switches[MOG::EQPMAPVIS] == false
@eqmap.visible = true
if Input.trigger?(Input::R)
Sound.play_cursor
next_actor
elsif Input.trigger?(Input::L)
Sound.play_cursor
prev_actor
end
else
@eqmap.visible = false
end
if $eref == true
@eqmap.refresh
$eref = false
end
mog8_update
end
def prev_actor
@actor_index += $game_party.members.size - 1
@actor_index %= $game_party.members.size
@eqmap.dispose
create_hud
end
end
#==============================================================================
# Game_Map
#==============================================================================
class Game_Map
attr_accessor :eref
end
class Game_Interpreter
def eref
$eref = true
end
alias mog319ref command_319
def command_319
eref
return mog319ref
end
end
end
PgUp i PgDn zmieniasz wyświetlany ekwipunek bohatera.aragorn7015 - Pon 28 Maj, 2012 15:26 Dzięki! Działa! Szkoda że nie można dać POMÓGŁ, bo bardzo mi pomogłaś Ayene! Jeszcze raz dzięki!Sharin - Pon 06 Sie, 2012 02:38 Ja mam pewien problem z tym skryptem , wgrałem go wydaje mi się prawidłowo , pokazuje się ogólnie i jest niby wszystko ok... ale jak ustawiam sobie 2 broń to obrazek danego itema nie zgadza się z tym który jest włożony do ekwipunku. Wiecie jak to rozwiązać?adrik20022002 - Sob 20 Paź, 2012 16:06 już wiem jak to robić