Jump to content
Rpg²S Forum
  • 0

Statistiche con icona


L. Phatimo
 Share

Question

Scusate, c'è un modo tramite script per fare si che le statistiche abbiano delle icone??? Sarebbe bello se ci fosse, alcuni menù le hanno ma in genere sono menù troppo articolati, io sto facendo un processo semplice e ci andrebbe meglio un menù tipo Pokèmon, piuttosto che FF7... Spero sappiate rispondermi :rovatfl:

War Vegetables

Pagina del Progetto: War Vegetables - Progetti MV - Rpg²S Forum (rpg2s.net)

Pagina Instagram: https://www.instagram.com/warvegetables/?hl=it

YouTube: https://www.youtube.com/channel/UCIVnrwNtklrKGwHLS9pDwkQ

http://www.rpg2s.net/cover_contest/icons/cc_5.png

Link to comment
Share on other sites

9 answers to this question

Recommended Posts

  • 0
Si si intendo un menù a script, ma non ne sto usando uino in particolare, mi basterebbe inserire delle icone affianco alle statistiche nel normale script RTP...

War Vegetables

Pagina del Progetto: War Vegetables - Progetti MV - Rpg²S Forum (rpg2s.net)

Pagina Instagram: https://www.instagram.com/warvegetables/?hl=it

YouTube: https://www.youtube.com/channel/UCIVnrwNtklrKGwHLS9pDwkQ

http://www.rpg2s.net/cover_contest/icons/cc_5.png

Link to comment
Share on other sites

  • 0

Allooooora...

 

Vai sulla classe Windows_Base alla riga 277 dovrebbe esserci il metodo :

  def draw_actor_parameter(actor, x, y, type)

che è racchiuso tra due commenti (li riconosci perchè le scritte dei commenti sono verdi), cancellalo e al suo posto scrivi questo:

  def draw_actor_parameter(actor, x, y, type)	case type	when 0	  nomepar = "atk"	  parameter_name = $data_system.words.atk	  parameter_value = actor.atk	when 1	  nomepar = "pdef"	  parameter_name = $data_system.words.pdef	  parameter_value = actor.pdef	when 2	  nomepar = "mdef"	  parameter_name = $data_system.words.mdef	  parameter_value = actor.mdef	when 3	  nomepar = "str"	  parameter_name = $data_system.words.str	  parameter_value = actor.str	when 4	  nomepar = "dex"	  parameter_name = $data_system.words.dex	  parameter_value = actor.dex	when 5	  nomepar = "agi"	  parameter_name = $data_system.words.agi	  parameter_value = actor.agi	when 6	  nomepar = "int"	  parameter_name = $data_system.words.int	  parameter_value = actor.int	end	bitmap = RPG::Cache.icon("Icon_"+nomepar)	self.contents.blt(x, y, bitmap, Rect.new(0, 0, 24, 24))	self.contents.font.color = system_color	self.contents.draw_text(x + 24, y, 120, 32, parameter_name)	self.contents.font.color = normal_color	self.contents.draw_text(x + 120, y, 36, 32, parameter_value.to_s, 2)  end

 

Ora salva tra le icone (con QUESTO nome) i seguenti files:

http://img5.imageshack.us/img5/7594/iconagi.png Icon_agi

http://img684.imageshack.us/img684/27/iconatk.png Icon_atk

http://img684.imageshack.us/img684/4562/icondex.png Icon_dex

http://img696.imageshack.us/img696/7383/iconint.png Icon_int

http://img684.imageshack.us/img684/3982/iconmdef.png Icon_mdef

http://img694.imageshack.us/img694/7673/iconpdef.png Icon_pdef

http://img12.imageshack.us/img12/463/iconstr.png Icon_str

 

Naturalmente le icone le puoi cambiare, le ho messe a casaccio! XD basta che i nomi siano quelli però!

 

Ora, l'unica cosa cui devi fare attenzione è la lunghezza dei nomi dei parametri che potrebbe coprire i numerini (a me non succede) quindi o li fai brevi oppure cambi/rimpicciolisci il font!

 

PS: se vuoi mettere le icone anche ad Hp Mp Exp Lv ed Eva dimmelo che cerco i relativi moduli e li modifico e te li scrivo qui ^___^

http://i30.tinypic.com/xehois.gif

} 2rA - web site {

E' disponibile il primo capitolo completo di 2rA!

} 2rA: Capitolo I {

Link to comment
Share on other sites

  • 0
Funziona benissimo!!!! Grazie!!! Vmq allora se hai altro tempo da perdere per me volentieri accetterei le icone anche per il LV e il resto, grazie mi sei di grande aiuto!! :sisi: :sisi: Edited by L. Phatimo

War Vegetables

Pagina del Progetto: War Vegetables - Progetti MV - Rpg²S Forum (rpg2s.net)

Pagina Instagram: https://www.instagram.com/warvegetables/?hl=it

YouTube: https://www.youtube.com/channel/UCIVnrwNtklrKGwHLS9pDwkQ

http://www.rpg2s.net/cover_contest/icons/cc_5.png

Link to comment
Share on other sites

  • 0

Per l'icona al lvl modifica il modulo:

 def draw_actor_level(actor, x, y)

in

  def draw_actor_level(actor, x, y)	bitmap = RPG::Cache.icon("Icon_lvl")	self.contents.blt(x-24, y, bitmap, Rect.new(0, 0, 24, 24))	self.contents.font.color = system_color	self.contents.draw_text(x, y, 32, 32, "Lv")	self.contents.font.color = normal_color	self.contents.draw_text(x + 32, y, 24, 32, actor.level.to_s, 2)  end

 

Per l'icona all'exp (ma NON nella finestra Status, se vuoi ti dico come farla apparire anche lì!) modifica il modulo:

  def draw_actor_exp(actor, x, y)

in

  def draw_actor_exp(actor, x, y)	bitmap = RPG::Cache.icon("Icon_exp")	self.contents.blt(x-24, y, bitmap, Rect.new(0, 0, 24, 24))	self.contents.font.color = system_color	self.contents.draw_text(x, y, 24, 32, "E")	self.contents.font.color = normal_color	self.contents.draw_text(x + 24, y, 84, 32, actor.exp_s, 2)	self.contents.draw_text(x + 108, y, 12, 32, "/", 1)	self.contents.draw_text(x + 120, y, 84, 32, actor.next_exp_s)  end

 

Per l'icona agli hp modifica il modulo:

  def draw_actor_hp(actor, x, y, width = 144)

in

  def draw_actor_hp(actor, x, y, width = 144)	# Draw "HP" text string	bitmap = RPG::Cache.icon("Icon_hp")	self.contents.blt(x-24, y, bitmap, Rect.new(0, 0, 24, 24))	self.contents.font.color = system_color	self.contents.draw_text(x, y, 32, 32, $data_system.words.hp)	# Calculate if there is draw space for MaxHP	if width - 32 >= 108	  hp_x = x + width - 108	  flag = true	elsif width - 32 >= 48	  hp_x = x + width - 48	  flag = false	end	# Draw HP	self.contents.font.color = actor.hp == 0 ? knockout_color :	  actor.hp <= actor.maxhp / 4 ? crisis_color : normal_color	self.contents.draw_text(hp_x, y, 48, 32, actor.hp.to_s, 2)	# Draw MaxHP	if flag	  self.contents.font.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

 

Per l'icona agli sp modifica il modulo:

  def draw_actor_sp(actor, x, y, width = 144)

in

  def draw_actor_sp(actor, x, y, width = 144)	# Draw "SP" text string	bitmap = RPG::Cache.icon("Icon_sp")	self.contents.blt(x-24, y, bitmap, Rect.new(0, 0, 24, 24))	self.contents.font.color = system_color	self.contents.draw_text(x, y, 32, 32, $data_system.words.sp)	# Calculate if there is draw space for MaxHP	if width - 32 >= 108	  sp_x = x + width - 108	  flag = true	elsif width - 32 >= 48	  sp_x = x + width - 48	  flag = false	end	# Draw SP	self.contents.font.color = actor.sp == 0 ? knockout_color :	  actor.sp <= actor.maxsp / 4 ? crisis_color : normal_color	self.contents.draw_text(sp_x, y, 48, 32, actor.sp.to_s, 2)	# Draw MaxSP	if flag	  self.contents.font.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

 

PS: per trovare i moduli sullo script (è sempre nella classe Window_Base) clicca sullo script col tasto destro e seleziona "Find" poi scrivi il nome del modulo e te lo trova lui ^____^

 

PPS: RICORDATI DI METTERE LE NUOVE ICONE! XD

Edited by nihil-omen

http://i30.tinypic.com/xehois.gif

} 2rA - web site {

E' disponibile il primo capitolo completo di 2rA!

} 2rA: Capitolo I {

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...