Jump to content
Rpg²S Forum
  • 0

Modifica al colore dei font in battaglia.


Remias
 Share

Question

Chiedo scusa per la mia ulteriore dimostrazione di aver perso ogni familiarità con rpg maker xp, ma purtroppo ho ancora bisogno di voi; andiamo dritti al sodo, nel gioco che sto creando come battler uso i face dei miei pg, purtroppo però il font di hp ed mp è troppo chiaro e sull'immagine chiara è quasi illeggibile, qualcuno potrebbe dirmi quale script devo modificare per cambiare il colore del font solo in battaglia? E se non è possibile cambiarlo, almeno il codice per farlo più scuro. Grazie in anticipo. ^_^
Link to comment
Share on other sites

4 answers to this question

Recommended Posts

  • 0

Window_Base.

 

Nei def relativi al disegno di HP ed MP, devi inserire una if, più o meno così

if $scene.is_a?(Scene_Battle)   # oppure if $game_temp.in_battle
 self.contents.font.color = Color.new(51, 51, 51)   # Grigio abbastanza scuro
else
 # Istruzione originale per scegliere il colore del testo
end

 


SCRIPT RGSS (RPG Maker XP) VINTAGE LIBRARY [2018+]


Breaking (in ogni senso) News: "Treno deraglia per via del seno di Sakurai Aoi . . ." - Info nello spoiler !!

 


http://afantasymachine.altervista.org/_altervista_ht/NOOOOOOOOOilMIOtreninooooo_500.gif


Non riesco a smettere di essere affascinato da immagini come questa . . .

http://anime.vl-vostok.ru/art/photos2011/17/78049800/wall_VladAnime_WWA_1885-1680x1050.jpg


Alcuni wallpapers che faccio ruotare sul mio vecchio PC . . .


http://afantasymachine.altervista.org/_altervista_ht/gits_window.jpg

http://afantasymachine.altervista.org/_altervista_ht/madoka_group01.jpg
http://afantasymachine.altervista.org/_altervista_ht/arisu_picipici_01.jpg
http://afantasymachine.altervista.org/_altervista_ht/phantom_wp01_einzwei.jpg


La parte più spassosa della mia vita è quando gli altri cercano di spiegarmi i miei pensieri . . .


BBCode Testing


Typeface & Size



Link to comment
Share on other sites

  • 0
giver ho provato a fare una cosa simile a quella che mi hai proposto, purtroppo però ottengo un cambiamento solo nel menu, e in battaglia sparisce il numero di HP attuali, potresti fare una copia del tuo script e provare a modificarlo e farmi sapere?
Link to comment
Share on other sites

  • 0

class Window_Base < Window
# ------------------------------------
BATTLE_LABEL_COLOR = Color.new(0, 0, 102)  # BLU relativamente scuro
BATTLE_HPMP_BASE_COLOR = Color.new(51, 51, 51)  # GRIGIO relativamente scuro
BATTLE_HPMP_CRISIS_COLOR = Color.new(51, 51, 0)  # "GIALLO" molto scuro
BATTLE_HPMP_KOUT_COLOR = Color.new(102, 0, 51)  # "ROSSO" molto scuro
# ------------------------------------
 def draw_actor_hp(actor, x, y, width = 144)
   self.contents.font.color = $scene.is_a?(Scene_Battle) ? BATTLE_LABEL_COLOR : system_color
   self.contents.draw_text(x, y, 32, 32, $data_system.words.hp)
   if width - 32 >= 108
  hp_x = x + width - 108
  flag = true
   elsif width - 32 >= 48
  hp_x = x + width - 48
  flag = false
   end
   if $scene.is_a?(Scene_Battle)
  self.contents.font.color = actor.hp == 0 ? BATTLE_HPMP_KOUT_COLOR :
    actor.hp <= actor.maxhp / 4 ? BATTLE_HPMP_CRISIS_COLOR : BATTLE_HPMP_BASE_COLOR
   else
  self.contents.font.color = actor.hp == 0 ? knockout_color :
    actor.hp <= actor.maxhp / 4 ? crisis_color : normal_color
   end
   self.contents.draw_text(hp_x, y, 48, 32, actor.hp.to_s, 2)
   if flag
  self.contents.font.color = $scene.is_a?(Scene_Battle) ? BATTLE_HPMP_BASE_COLOR : normal_color
  self.contents.draw_text(hp_x + 48, y, 12, 32, "/", 1)
  self.contents.draw_text(hp_x + 60, y, 48, 32, actor.maxhp.to_s)
   end
 end
# ------------------------------------
 def draw_actor_sp(actor, x, y, width = 144)
   self.contents.font.color = $scene.is_a?(Scene_Battle) ? BATTLE_LABEL_COLOR : system_color
   self.contents.draw_text(x, y, 32, 32, $data_system.words.sp)
   if width - 32 >= 108
  sp_x = x + width - 108
  flag = true
   elsif width - 32 >= 48
  sp_x = x + width - 48
  flag = false
   end
   if $scene.is_a?(Scene_Battle)
  self.contents.font.color = actor.sp == 0 ? BATTLE_HPMP_KOUT_COLOR :
    actor.sp <= actor.maxsp / 4 ? BATTLE_HPMP_CRISIS_COLOR : BATTLE_HPMP_BASE_COLOR
   else
  self.contents.font.color = actor.sp == 0 ? knockout_color :
    actor.sp <= actor.maxsp / 4 ? crisis_color : normal_color
   end
   self.contents.draw_text(sp_x, y, 48, 32, actor.sp.to_s, 2)
   if flag
  self.contents.font.color = $scene.is_a?(Scene_Battle) ? BATTLE_HPMP_BASE_COLOR : normal_color
  self.contents.draw_text(sp_x + 48, y, 12, 32, "/", 1)
  self.contents.draw_text(sp_x + 60, y, 48, 32, actor.maxsp.to_s)
   end
 end
# ------------------------------------
end

Scritto "al volo", nell'editor dei messaggi, quindi non ho idea di come renda o se dia errori di sintassi . . .

Va messo almeno sotto lo script Window_Base . . .

 


SCRIPT RGSS (RPG Maker XP) VINTAGE LIBRARY [2018+]


Breaking (in ogni senso) News: "Treno deraglia per via del seno di Sakurai Aoi . . ." - Info nello spoiler !!

 


http://afantasymachine.altervista.org/_altervista_ht/NOOOOOOOOOilMIOtreninooooo_500.gif


Non riesco a smettere di essere affascinato da immagini come questa . . .

http://anime.vl-vostok.ru/art/photos2011/17/78049800/wall_VladAnime_WWA_1885-1680x1050.jpg


Alcuni wallpapers che faccio ruotare sul mio vecchio PC . . .


http://afantasymachine.altervista.org/_altervista_ht/gits_window.jpg

http://afantasymachine.altervista.org/_altervista_ht/madoka_group01.jpg
http://afantasymachine.altervista.org/_altervista_ht/arisu_picipici_01.jpg
http://afantasymachine.altervista.org/_altervista_ht/phantom_wp01_einzwei.jpg


La parte più spassosa della mia vita è quando gli altri cercano di spiegarmi i miei pensieri . . .


BBCode Testing


Typeface & Size



Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...