-
Amphilohiy
-
-
Вне сайта
-
Светлый дракон
-
- Сообщений: 547
- Спасибо получено: 666
-
-
|
Мои глаза жжет! Боль, невыносимая боль!
Вот это вроде работает:
=begin =========================================================================
Dekita's v1.1
★ THE MOST BASIC ENEMY INFO EVER™ ★
================================================================================
Script Information:
====================
This script gives you basic information about your enemy during battle
this is "VERY" basic...
================================================================================
★☆★☆★☆★☆★☆★☆★☆★ TERMS AND CONDITIONS: ☆★☆★☆★☆★☆★☆★☆★☆★☆
================================================================================
1. You must give credit to "Dekita"
2. You are NOT allowed to repost this script.(or modified versions)
3. You are NOT allowed to convert this script.(into other game engines e.g RGSS2)
4. You are NOT allowed to use this script for Commercial games.
5. ENJOY!
"FINE PRINT"
By using this script you hereby agree to the above terms and conditions,
if any violation of the above terms occurs "legal action" may be taken.
Not understanding the above terms and conditions does NOT mean that
they do not apply to you.
If you wish to discuss the terms and conditions in further detail you can
contact me at http://dekitarpg.wordpress.com/ or [email protected]
================================================================================
History:
=========
D /M /Y
18/10/2o12 - wrote script,
================================================================================
INSTRUCTIONS:
==============
Place this script UNDER "▼ Materials" and ABOVE "▼ Main" in your script editor.
=end #==========================================================================#
module Dekita__Enemy_HP_MP_BASIC
# CUSTOMISATION OPTIONS
Enemy_Info_Column =[
[:mhp],
[:mmp],
[:mtp],
]#
# MaxHP Settings
MHP_Color_1 = Color.new(0, 50, 0, 100)
MHP_Color_2 = Color.new(0, 255, 0, 150)
# MaxMP Settings
MMP_Color_1 = Color.new(0, 0, 50)
MMP_Color_2 = Color.new(0, 0, 255)
# MaxTP Settings
MTP_Color_1 = Color.new(255, 160, 64)
MTP_Color_2 = Color.new(255, 255, 96)
Gauge_Width = (Graphics.width / 5 - 12)
# CUSTOMISATION OPTIONS END!
p 'Loaded : DPBz - Basic Enemy Info'
end # Dekita__Enemy_HP_MP_BASIC
$imported = {} if $imported.nil?
$imported[:Dekita__Basic_Enemy_Info] = true
#==============================================================================
class Window_BattleEnemy < Window_Selectable
#==============================================================================
# // Overwrite method
def col_max
return 1
end
# // Alias method
alias basic_enemy_info draw_item
def draw_item(index)
basic_enemy_info(index)
e_i_index = $game_troop.alive_members[0]
e_i_index1 = $game_troop.alive_members[1]
e_i_index2 = $game_troop.alive_members[2]
e_i_index3 = $game_troop.alive_members[3]
e_i_index4 = $game_troop.alive_members[4]
e_i_index5 = $game_troop.alive_members[5]
e_i_index6 = $game_troop.alive_members[6]
e_i_index7 = $game_troop.alive_members[7]
draw_enemy_info_column(e_i_index, 0)
if !$game_troop.alive_members[1].nil?
draw_enemy_info_column(e_i_index1, line_height * 1)
end
if !$game_troop.alive_members[2].nil?
draw_enemy_info_column(e_i_index2, line_height * 2)
end
if !$game_troop.alive_members[3].nil?
draw_enemy_info_column(e_i_index3, line_height * 3)
end
if !$game_troop.alive_members[4].nil?
draw_enemy_info_column(e_i_index4, line_height * 4)
end
if !$game_troop.alive_members[5].nil?
draw_enemy_info_column(e_i_index5, line_height * 5)
end
if !$game_troop.alive_members[6].nil?
draw_enemy_info_column(e_i_index6, line_height * 6)
end
if !$game_troop.alive_members[7].nil?
draw_enemy_info_column(e_i_index7, line_height * 7)
end
end
# // New method
def draw_enemy_info_column(index, dy)
dx = window_width / 4 * 1
dw = Dekita__Enemy_HP_MP_BASIC::Gauge_Width
for information in Dekita__Enemy_HP_MP_BASIC::Enemy_Info_Column
draw_basic_enemy_info(information, index, dx, dy, dw)
dx += (dw+2)
end
end
# // New method
def draw_basic_enemy_info(stat_info, target, dx, dy, dw)
dpbz_target = target
case stat_info[0]
when :mhp
text = Vocab.hp
value = "#{dpbz_target.hp.to_i} / #{dpbz_target.mhp}"
rate = dpbz_target.hp_rate
color1 = Dekita__Enemy_HP_MP_BASIC::MHP_Color_1
color2 = Dekita__Enemy_HP_MP_BASIC::MHP_Color_2
when :mmp
text = Vocab.mp
value = "#{dpbz_target.mp.to_i} / #{dpbz_target.mmp}"
rate = dpbz_target.mp_rate
color1 = Dekita__Enemy_HP_MP_BASIC::MMP_Color_1
color2 = Dekita__Enemy_HP_MP_BASIC::MMP_Color_2
when :mtp
text = Vocab.tp
value = "#{dpbz_target.tp.to_i} / #{dpbz_target.max_tp}"
rate = dpbz_target.tp_rate
color1 = Dekita__Enemy_HP_MP_BASIC::MTP_Color_1
color2 = Dekita__Enemy_HP_MP_BASIC::MTP_Color_2
else; return dy
end
contents.font.size = 18
change_color(system_color)
draw_gauge(dx, dy-2, dw-4, rate, color1, color2)
draw_text(dx, dy-2, dw-2, line_height, text, 0)
change_color(normal_color)
draw_text(dx, dy-2, dw-2, line_height, value, 2)
return dy + line_height
end
end # Window_BattleEnemy
#===============================================================================#
# - SCRIPT END - #
#===============================================================================#
# http://dekitarpg.wordpress.com/ #
#===============================================================================# Радует меня это лицензионное соглашение, по сути ты его уже нарушил, запостив сюда код.
|