โชว์ Icon_Item ขณะคุย (เเก้ไขสคริปต์ใหม่)
หน้า 1 จาก 1
โชว์ Icon_Item ขณะคุย (เเก้ไขสคริปต์ใหม่)
Download
วิธีใช้ ( n = หมายเลข Item )
1.\I[n] = Item with name
2.\W[n] = Weapon with name
3.\A[n] = Armor with name
4.\S[n] = Skill with name
เเถม
1.\Class[n] = ชื่อ Hero
2.\class[n] = Class Hero
(ซีเล็กเเละซีใหญต้องไม่เหมือนกัน)
วิธีพิมพ์โค้ดใน Window_Message
1.บรรทัดที่ 86 - 107
- Code:
text.gsub!(/\\[i]\[([0-9]+)\]/) do
$data_items[$1.to_i] != nil ? $data_items[$1.to_i].name : ""
end
text.gsub!(/\\[w]\[([0-9]+)\]/) do
$data_weapons[$1.to_i] != nil ? $data_weapons[$1.to_i].name : ""
end
text.gsub!(/\\[a]\[([0-9]+)\]/) do
$data_armors[$1.to_i] != nil ? $data_armors[$1.to_i].name : ""
end
text.gsub!(/\\[Ee]\[([0-9]+)\]/) do
$data_enemies[$1.to_i] != nil ? $data_enemies[$1.to_i].name : ""
end
text.gsub!(/\\[c]lass\[([0-9]+)\]/) do
$data_classes[$1.to_i] != nil ? $data_classes[$1.to_i].name : ""
end
text.gsub!(/\\[C]lass\[([0-9]+)\]/) do
$data_classes[$data_actors[$1.to_i].class_id] != nil ?
$data_classes[$data_actors[$1.to_i].class_id] .name : ""
end
- Code:
text.gsub!(/\\[I]\[([0-9]+)\]/) { "\006[#{$1}]" }
text.gsub!(/\\[W]\[([0-9]+)\]/) { "\007[#{$1}]" }
text.gsub!(/\\[A]\[([0-9]+)\]/) { "\010[#{$1}]" }
text.gsub!(/\\[S]\[([0-9]+)\]/) { "\011[#{$1}]" }
- Code:
# \I = Show Item Name with Icon
if c == "\006"
text.sub!(/\[([0-9]+)\]/, "")
item_sub = $1.to_i
c = $data_items [item_sub].name
n = self.contents.text_size(c).width
draw_item_name($data_items[item_sub], x, y * 32 + 1)
x = x + n + 24
next
# To The following letter
end
# \W = Show Weapon Name with Icon
if c == "\007"
text.sub!(/\[([0-9]+)\]/, "")
weapon_sub = $1.to_i
c = $data_weapons [weapon_sub].name
n = self.contents.text_size(c).width
draw_item_name($data_weapons[weapon_sub], x, y * 32 + 1)
x = x + n + 24
next
# To The following letter
end
# \A = Show Armor Name with Icon
if c == "\010"
text.sub!(/\[([0-9]+)\]/, "")
armor_sub = $1.to_i
c = $data_armors [armor_sub].name
n = self.contents.text_size(c).width
draw_item_name($data_armors[armor_sub], x, y * 32 + 1)
x = x + n + 24
next
# To The following letter
end
# \S = Show Skill Name with Icon
if c == "\011"
text.sub!(/\[([0-9]+)\]/, "")
skill_sub = $1.to_i
c = $data_skills [skill_sub].name
n = self.contents.text_size(c).width
draw_item_name($data_skills[skill_sub], x, y * 32 + 1)
x = x + n + 24
next
# To The following letter
end
หน้า 1 จาก 1
Permissions in this forum:
คุณไม่สามารถพิมพ์ตอบ