赞 | 1 |
VIP | 10 |
好人卡 | 2 |
积分 | 1 |
经验 | 132388 |
最后登录 | 2016-5-9 |
在线时间 | 34 小时 |
Lv1.梦旅人 冰王子
- 梦石
- 0
- 星屑
- 50
- 在线时间
- 34 小时
- 注册时间
- 2008-1-27
- 帖子
- 1875
|
加入我们,或者,欢迎回来。
您需要 登录 才可以下载或查看,没有帐号?注册会员
x
【说明】
=begin
===============================================================================
☆装备等级☆ By 凌冰(Eci)
===============================================================================
使用说明:
①失效或半失效的事件
事件:减少武器、减少防具
说明:完全失效
替代:背包中失去装备的替代办法暂时还没有,只有失去角色当前装备的办法
脚本事件中写入actor_equip_lose(角色ID,类型)
类型为0则为武器,为1~4这是对应的防具
这样不出意外的话,角色的第(类型)件装备就找不回来了
如果你想找个变量寄存这件装备,可以写成
变量 = actor_equip_lose(角色ID,类型)
再得到该装备时写入脚本
$game_party.gain_weapon_lv(变量)
事件:商店
说明:买卖装备时输入数量只能为1
替代:多回车几次吧
②设置方法
武器和防具的设置都可以使用自虐版设置方法或懒人版设置方法或两者混合
③范例
这里提供的范例设置只是为了展示给大家看,并不推荐使用
④各默认类涉及度(可估测整合可能性)
类 | 涉及度
Game_Temp 低
Game_Actor 高
Game_Party 中高
Window_Base 低
Window_Item 低
Window_EquipRight 中低
Window_EquipItem 中低
Window_Status 低
Window_ShopBuy 中低
Window_ShopSell 中低
Window_ShopNumber 低
Window_ShopStatus 低
Interpreter 低
Scene_Equip 中
Scene_Battle 中高
Scene_Shop 中
高 > 中高 > 中 > 中低 > 低
⑤预计整合可能性
中低
⑥商店可购买到等级大于零的装备的办法
(如范例中左边的红发暴力女)
$game_temp.eqlv_list = [[类型,装备ID,等级],[同左],[同左]] 类型3为武器,4为防具
多行的话要在,或者[后换行
然后再下一个事件中设置商店,推出商店界面后自动清空
⑦得到等级大于零装备的办法
(如范例中右边的灰发伪娘男)
方法1:脚本事件中添加$game_party.gain_weapon_lv(1,10)
方法2:公共设置中NUM_LEVEL设置为true,等级则为数量-1
=end
【效果】
- =begin
- ===============================================================================
- □公共设置□
- ===============================================================================
- =end
- module EciDevil
- SCOPE_PLUS = 0.1
- #↑群攻命中叠加比率,即经验 = DF_HIT * (SCOPE_PLUS + 1) **(命中数-1)↑
- #↑SCOPE_PLUS为负,则经验 = DF_HIT * (命中数)
- SHT_COUNT = 4 #单位帧,装备经验窗口的刷新的帧数周期
- MID_COUNT = 10 #单位帧,装备经验窗口切换装备的帧数间隔
- LON_COUNT = 16 #单位帧,装备经验窗口显示完毕后的停留帧数
- NUM_LEVEL = true #是否将增加武器、增加防具事件的数量改为等级(等级=数量-1)
- EQL_WINOP = 128 #装备经验窗口的透明度
- =begin
- ===============================================================================
- □武器设置□
- ===============================================================================
- 简易(懒人)设置说明:
- 在设置里从DF_SKL到DF_INT[1]都可以设置为单一数值或者数组,默认为数组,若设置为单
- 一数值的话,则表示所有类别的武器升级都统一使用该数值。详见【懒人版】
- =end
- class Weapon
- #===============
- #↓初始化↓
- #===============
- ID = {}
- LV_SKL = {}
- LV_LMT = {}
- LV_BAS = {}
- LV_POI = {}
- LV_KND = {}
- LV_MIS = {}
- LV_GUA = {}
- LV_HIT = {}
- LV_CRI = {}
- DF_PRI = []
- DF_ATK = []
- DF_PDE = []
- DF_MDE = []
- DF_STR = []
- DF_DEX = []
- DF_AGI = []
- DF_INT = []
- LV_PRI = {}
- LV_ATK = {}
- LV_PDE = {}
- LV_MDE = {}
- LV_STR = {}
- LV_DEX = {}
- LV_AGI = {}
- LV_INT = {}
- #====
- #扩展
- #====
- AC_NAM = {}
- AC_ICO = {}
- AC_DES = {}
- AC_AAN = {}
- AC_TAN = {}
- AC_ELE = {}
- AC_PST = {}
- AC_MST = {}
- AUTO_CHANGE = {"NAM"=>AC_NAM,"ICO"=>AC_ICO,"DES"=>AC_DES,"AAN"=>AC_AAN,
- "TAN"=>AC_TAN,"ELE"=>AC_ELE,"PST"=>AC_PST,"MST"=>AC_MST}
- #===============
- #↑初始化↑
- #===============
- #=======================================================================
- #↓从下面开始设置↓
- #=======================================================================
- fi = 1 #战士
- la = 2 #枪兵
- wa = 3 #狂战士
- th = 4 #盗贼
- hu = 5 #猎人
- gu = 6 #枪手
- cl = 7 #僧侣
- ma = 8 #魔导士
- KIND = [nil,fi,la,wa,th,hu,gu,cl,ma]
- #↑若要增加武器类型,不要忘记修改这里↑
- #设置武器类型所包含的武器ID
- ID[fi] = [ 1, 3, 4]
- ID[la] = [ 5, 6, 7, 8]
- ID[wa] = [ 9,10,11,12]
- ID[th] = [13,14,15,16]
- ID[hu] = [17,18,19,20]
- ID[gu] = [21,22,23,24]
- ID[cl] = [25,26,27,28]
- ID[ma] = [29,30,31,32]
- #↓加经验的攻击模式↓
- DF_SKL = {fi=>0,la=>0,wa=>0,th=>1,hu=>1,gu=>1,cl=>2,ma=>2}
- #↑0物理技能(包括平砍)增加经验↑
- #↑1全部技能(包括平砍)增加经验↑
- #↑2魔法技能(不包括平砍)增加经验↑
- #↑3只能平砍增加经验↑
- #↑4物理技能(不包括平砍)增加经验↑
- #↑5魔法技能(包括平砍)增加经验↑
- #↑6全部技能(不包括平砍)增加经验↑
- #↑缺省或超出时默认为0↑
- #-----------------------------------------------------
- # ※注明※ #
- #-----------------------------------------------------
- #判断物理技能和魔法技能的参数为atk_f即数据库项攻击力 F
- #-----------------------------------------------------
- DF_MIS = {fi=>1,la=>1,wa=>1,th=>1,hu=>1,gu=>1,cl=>1,ma=>1} #击空时经验
- DF_GUA = {fi=>2,la=>2,wa=>2,th=>2,hu=>2,gu=>2,cl=>2,ma=>2} #防御时经验
- DF_HIT = {fi=>3,la=>3,wa=>3,th=>3,hu=>3,gu=>3,cl=>3,ma=>3} #击中时经验
- DF_CRI = {fi=>4,la=>4,wa=>4,th=>4,hu=>4,gu=>4,cl=>4,ma=>4} #必杀时经验
- #--------------------------------------------------------------------------
- #↓默认设置↓
- DF_LMT = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}
- #↑默认等级限制↑
- DF_BAS = {fi=>5,la=>5,wa=>5,th=>8,hu=>8,gu=>8,cl=>4,ma=>4}
- #↑默认经验基本值↑
- DF_POI = {fi=>0,la=>0,wa=>0,th=>0,hu=>0,gu=>0,cl=>0,ma=>0}
- #↑默认经验增长值↑
- DF_KND = {fi=>0,la=>0,wa=>0,th=>0,hu=>0,gu=>0,cl=>0,ma=>0}
- #↑默认经验增长方式↑
- #↑经验增长方式(0~7)↑
- #↑0:常数函数 NE = BAS
- #↑1:一次函数 NE = POI * LV + BAS
- #↑2:指数函数 NE = POI ** LV + BAS
- #↑3:角色升级函数 NE = BAS*((NL + 3)**(2.4+POI/100.0))/(5**(2.4+POI/100.0))
- #↑(0~3)+4:NE = (0~3)所求NE + LE
- #NE:下一等级经验 NL:下一等级 LE:当前等级经验 LV:当前等级
- #BAS:基本值 POI:增长值
- #----------------属性增长----------------#
- #◇价格◇
- DF_PRI[0] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长值
- DF_PRI[1] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长方式
- #◇攻击◇
- DF_ATK[0] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长值
- DF_ATK[1] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长方式
- #→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→
- #◇物防◇
- DF_PDE[0] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长值
- DF_PDE[1] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长方式
- #◇魔防◇
- DF_MDE[0] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长值
- DF_MDE[1] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长方式
- #◇力量◇
- DF_STR[0] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长值
- DF_STR[1] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长方式
- #◇敏捷◇
- DF_DEX[0] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长值
- DF_DEX[1] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长方式
- #◇速度◇
- DF_AGI[0] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长值
- DF_AGI[1] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长方式
- #◇魔力◇
- DF_INT[0] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长值
- DF_INT[1] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长方式
- #←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←
- #↑增长方式(0~7)↑
- #与经验的增长方式类似,不过公式中的变量所代表的参数不同
- #NE:下一等级属性 NL:下一等级 LE:当前等级属性 LV:当前等级
- #BAS:初始属性 POI增长值
- #0为不增长
- #--------------------------------------------------------------------------
- #↑默认设置↑
- #--------------------------------------------------------------------------
- #----------------#
- #☆ 单独设置 ☆#
- #----------------#
- #----↓↓↓↓任意值可以缺省,则默认为默认值(默认值缺省则为0)↓↓↓↓----#
- #----↓举例(铜剑)测试用↓----#
- LV_SKL[1] = 0 #升级方式
- LV_LMT[1] = 10 #等级限制
- LV_BAS[1] = 1 #经验基本值
- LV_POI[1] = 1 #经验增长值
- LV_KND[1] = 1 #经验增长方式
- LV_MIS[1] = 0 #没有击中时经验
- LV_GUA[1] = 2 #敌人防御时经验
- LV_HIT[1] = 3 #成功命中时经验
- LV_CRI[1] = 5 #会心一击时经验
- LV_PRI[1] = [100,7] #价格[增长值,增长方式]
- LV_ATK[1] = [100,7] #攻击[增长值,增长方式]
- LV_PDE[1] = [100,0] #物防[增长值,增长方式]
- LV_MDE[1] = [100,0] #魔防[增长值,增长方式]
- LV_STR[1] = [100,0] #力量[增长值,增长方式]
- LV_DEX[1] = [100,2] #敏捷[增长值,增长方式]
- LV_AGI[1] = [100,2] #速度[增长值,增长方式]
- LV_INT[1] = [100,0] #魔力[增长值,增长方式]
- #----------------#
- #★ 单独设置 ★#
- #----------------#
- #=========================================================
- #扩展部分
- #=========================================================
- #统一格式
- #AC_XXX[ID] = {LV1 => N1 , LV2 => N2 , LV3 => N3}
- #如果0<LV1<LV2<LV3<MAXLV,则
- #0~LV1,该项属性值为数据库值
- #LV1~LV2,该项属性值为N1
- #LV2~LV3,该项属性值为N2
- #LV3~MAXLV,该项属性值为N3
- AC_NAM[1] = {5 => "真の寒の冰王子の变态の剑",10 => "奥义の冰王子の变态の剑"}
- AC_ICO[1] = {10 => "050-Skill07"}
- AC_DES[1] = {5 => "X,怎么才5级",10 => "终于10级了,可以打BOSS去了"}
- AC_AAN[1] = {5 => 1,10 => 2}
- AC_TAN[1] = {5 => 70,10 => 32}
- AC_ELE[1] = {5 => [3],10 => [2,3]}
- #↑=>后表示要该级别所有属性ID的数组,为空则所有属性清空↑
- AC_PST[1] = {5 => [2],10 => [3,4]}
- #↑=>后表示要该级别所有附加状态ID的数组,为空则所有附加状态清空↑
- AC_MST[1] = {5 => [3],10 => [3,15]}
- #↑=>后表示要该级别所有清除状态ID的数组,为空则所有清除状态清空↑
- #↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓
- #需要注意的是,这些值不是增加或减少,而是替换
- #↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑
- #=======================================================================
- #↑在上面进行设置↑
- #=======================================================================
- end
- =begin
- ===============================================================================
- □防具设置□
- ===============================================================================
- =end
- class Armor
- #===============
- #↓初始化↓
- #===============
- ID = {}
- LV_SKL = {}
- LV_LMT = {}
- LV_BAS = {}
- LV_POI = {}
- LV_KND = {}
- LV_MIS = {}
- LV_GUA = {}
- LV_HIT = {}
- LV_CRI = {}
- DF_PRI = []
- DF_PDE = []
- DF_MDE = []
- DF_EVA = []
- DF_STR = []
- DF_DEX = []
- DF_AGI = []
- DF_INT = []
- LV_PRI = {}
- LV_PDE = {}
- LV_MDE = {}
- LV_EVA = {}
- LV_STR = {}
- LV_DEX = {}
- LV_AGI = {}
- LV_INT = {}
- #====
- #扩展
- #====
- AC_NAM = {}
- AC_ICO = {}
- AC_DES = {}
- AC_AST = {}
- AC_GEL = {}
- AC_GST = {}
- AUTO_CHANGE = {"NAM"=>AC_NAM,"ICO"=>AC_ICO,"DES"=>AC_DES,"AST"=>AC_AST,
- "GEL"=>AC_GEL,"GST"=>AC_GST}
- #===============
- #↑初始化↑
- #===============
- #=======================================================================
- #↓从下面开始设置↓
- #=======================================================================
- fi = 1 #护盾
- la = 2 #头盔
- wa = 3 #法帽
- th = 4 #铠甲
- hu = 5 #板甲
- gu = 6 #法袍
- cl = 7 #辅戒
- ma = 8 #抗戒
- KIND = [nil,fi,la,wa,th,hu,gu,cl,ma]
- #↑若要增加防具类型,不要忘记修改这里↑
- #设置防具类型所包含的防具ID
- ID[fi] = [ 1, 2, 3, 4]
- ID[la] = [ 5, 6, 7, 8]
- ID[wa] = [ 9,10,11,12]
- ID[th] = [13,14,15,16]
- ID[hu] = [17,18,19,20]
- ID[gu] = [21,22,23,24]
- ID[cl] = [25,26,27,28]
- ID[ma] = [29,30,31,32]
- #↓加经验的攻击模式↓
- DF_SKL = {fi=>0,la=>0,wa=>0,th=>1,hu=>1,gu=>1,cl=>2,ma=>2}
- #↑0物理技能(包括平砍)增加经验↑
- #↑1全部技能(包括平砍)增加经验↑
- #↑2魔法技能(不包括平砍)增加经验↑
- #↑3只能平砍增加经验↑
- #↑4物理技能(不包括平砍)增加经验↑
- #↑5魔法技能(包括平砍)增加经验↑
- #↑6全部技能(不包括平砍)增加经验↑
- #↑缺省或超出时默认为0↑
- #-----------------------------------------------------
- # ※注明※ #
- #-----------------------------------------------------
- #判断物理技能和魔法技能的参数为atk_f即数据库项攻击力 F
- #-----------------------------------------------------
- DF_MIS = {fi=>1,la=>1,wa=>1,th=>1,hu=>1,gu=>1,cl=>1,ma=>1} #击空时经验
- DF_GUA = {fi=>2,la=>2,wa=>2,th=>2,hu=>2,gu=>2,cl=>2,ma=>2} #防御时经验
- DF_HIT = {fi=>3,la=>3,wa=>3,th=>3,hu=>3,gu=>3,cl=>3,ma=>3} #击中时经验
- DF_CRI = {fi=>4,la=>4,wa=>4,th=>4,hu=>4,gu=>4,cl=>4,ma=>4} #必杀时经验
- #--------------------------------------------------------------------------
- #↓默认设置↓
- DF_LMT = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}
- #↑默认等级限制↑
- DF_BAS = {fi=>5,la=>5,wa=>5,th=>8,hu=>8,gu=>8,cl=>4,ma=>4}
- #↑默认经验基本值↑
- DF_POI = {fi=>0,la=>0,wa=>0,th=>0,hu=>0,gu=>0,cl=>0,ma=>0}
- #↑默认经验增长值↑
- DF_KND = {fi=>0,la=>0,wa=>0,th=>0,hu=>0,gu=>0,cl=>0,ma=>0}
- #↑默认经验增长方式↑
- #↑经验增长方式(0~7)↑
- #↑0:常数函数 NE = BAS
- #↑1:一次函数 NE = POI * LV + BAS
- #↑2:指数函数 NE = POI ** LV + BAS
- #↑3:角色升级函数 NE = BAS*((NL + 3)**(2.4+POI/100.0))/(5**(2.4+POI/100.0))
- #↑(0~3)+4:NE = (0~3)所求NE + LE
- #NE:下一等级经验 NL:下一等级 LE:当前等级经验 LV:当前等级
- #BAS:基本值 POI:增长值
- #----------------属性增长----------------#
- #◇价格◇
- DF_PRI[0] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长值
- DF_PRI[1] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长方式
- #◇物防◇
- DF_PDE[0] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长值
- DF_PDE[1] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长方式
- #◇魔防◇
- DF_MDE[0] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长值
- DF_MDE[1] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长方式
- #→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→→
- #◇回避◇
- DF_EVA[0] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长值
- DF_EVA[1] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长方式
- #◇力量◇
- DF_STR[0] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长值
- DF_STR[1] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长方式
- #◇敏捷◇
- DF_DEX[0] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长值
- DF_DEX[1] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长方式
- #◇速度◇
- DF_AGI[0] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长值
- DF_AGI[1] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长方式
- #◇魔力◇
- DF_INT[0] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长值
- DF_INT[1] = {fi=>5,la=>5,wa=>5,th=>5,hu=>5,gu=>5,cl=>5,ma=>5}#默认增长方式
- #←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←←
- #↑增长方式(0~7)↑
- #与经验的增长方式类似,不过公式中的变量所代表的参数不同
- #NE:下一等级属性 NL:下一等级 LE:当前等级属性 LV:当前等级
- #BAS:初始属性 POI增长值
- #0为不增长
- #--------------------------------------------------------------------------
- #↑默认设置↑
- #--------------------------------------------------------------------------
- #----------------#
- #☆ 单独设置 ☆#
- #----------------#
- #----↓↓↓↓任意值可以缺省,则默认为默认值(默认值缺省则为0)↓↓↓↓----#
- #----↓举例(铜剑)测试用↓----#
- LV_SKL[1] = 0 #升级方式
- LV_LMT[1] = 10 #等级限制
- LV_BAS[1] = 1 #经验基本值
- LV_POI[1] = 1 #经验增长值
- LV_KND[1] = 1 #经验增长方式
- LV_MIS[1] = 0 #没有击中时经验
- LV_GUA[1] = 2 #敌人防御时经验
- LV_HIT[1] = 3 #成功命中时经验
- LV_CRI[1] = 5 #会心一击时经验
- LV_PRI[1] = [100,7] #价格[增长值,增长方式]
- LV_PDE[1] = [100,0] #物防[增长值,增长方式]
- LV_MDE[1] = [100,0] #魔防[增长值,增长方式]
- LV_EVA[1] = [0.1,0] #回避[增长值,增长方式]
- LV_STR[1] = [100,0] #力量[增长值,增长方式]
- LV_DEX[1] = [100,2] #敏捷[增长值,增长方式]
- LV_AGI[1] = [100,2] #速度[增长值,增长方式]
- LV_INT[1] = [100,0] #魔力[增长值,增长方式]
- #----------------#
- #★ 单独设置 ★#
- #----------------#
- #=========================================================
- #扩展部分
- #=========================================================
- #统一格式
- #AC_XXX[ID] = {LV1 => N1 , LV2 => N2 , LV3 => N3}
- #如果0<LV1<LV2<LV3<MAXLV,则
- #0~LV1,该项属性值为数据库值
- #LV1~LV2,该项属性值为N1
- #LV2~LV3,该项属性值为N2
- #LV3~MAXLV,该项属性值为N3
- AC_NAM[1] = {5 => "圣の护の冰王子の守护の盾",10 => "神喻の冰王子の守护の盾"}
- AC_ICO[1] = {10 => "050-Skill07"}
- AC_DES[1] = {5 => "X,怎么才5级",10 => "终于10级了,可以扛BOSS去了"}
- AC_AST[1] = {5 => 15,10 => 16}
- #↑=>后表示要该级别自动状态ID,为空则无自动状态↑
- AC_GEL[1] = {5 => [3],10 => [2,3]}
- #↑=>后表示要该级别所有防御属性ID的数组,为空则所有防御属性清空↑
- AC_GST[1] = {5 => [3],10 => [3,15]}
- #↑=>后表示要该级别所有防御状态ID的数组,为空则所有防御状态清空↑
- #↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓
- #需要注意的是,这些值不是增加或减少,而是替换
- #↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑↑
- #=======================================================================
- #↑在上面进行设置↑
- #=======================================================================
-
- end
- end
- #==============================================================================
- #描述部分
- #==============================================================================
- #=============================================================================
- #武器
- #=============================================================================
- module EciDevil
- class Weapon
- def self.find_bas(id,p)
- e = $data_weapons[id]
- case p
- when "PRI"
- return e.price
- when "ATK"
- return e.atk
- when "PDE"
- return e.pdef
- when "MDE"
- return e.mdef
- when "STR"
- return e.str_plus
- when "DEX"
- return e.dex_plus
- when "AGI"
- return e.agi_plus
- when "INT"
- return e.int_plus
- end
- end
- def self.make_list(id,p)
- lmt = find_lvup(id,"LMT")
- case p
- when "EXP"
- poi = find_lvup(id,"POI")
- bas = find_lvup(id,"BAS")
- knd = find_lvup(id,"KND")
- list = [0]
- when "PRI","ATK","PDE","MDE","STR","DEX","AGI","INT"
- poi = find_lvup(id,p,0)
- knd = find_lvup(id,p,1)
- bas = find_bas(id,p)
- list = [bas]
- end
- for i in 1...(lmt+1)
- case knd
- when 0
- n = bas
- when 1
- n = bas + poi * (i-1)
- when 2
- n = bas + poi ** (i-1)
- when 3
- n = bas * ((i + 3) ** (2.4 + poi / 100.0)) / (5 ** (2.4 + poi / 100.0))
- when 4
- n = bas + list[i-1]
- when 5
- n = bas + poi * (i-1) + list[i-1]
- when 6
- n = bas + poi ** (i-1) + list[i-1]
- when 7
- n = bas * ((i + 3) ** (2.4 + poi / 100.0)) / (5 ** (2.4 + poi / 100.0)) + list[i-1]
- end
- list[i] = Integer(n)
- end
- return list
- end
- def self.find_lvup(id,p,k=0)
- if AUTO_CHANGE.has_key?(p)
- ac = AUTO_CHANGE[p]
- if ac[id] != nil
- return ac[id]
- end
- return {}
- end
- typ = find_type(id)
- if typ == 0
- return 0
- end
- case p
- when "TYP"
- return typ
- when "SKL"
- lv = LV_SKL[id]
- df = DF_SKL
- when "LMT"
- lv = LV_LMT[id]
- df = DF_LMT
- when "BAS"
- lv = LV_BAS[id]
- df = DF_BAS
- when "POI"
- lv = LV_POI[id]
- df = DF_POI
- when "KND"
- lv = LV_KND[id]
- df = DF_KND
- when "MIS"
- lv = LV_MIS[id]
- df = DF_MIS
- when "GUA"
- lv = LV_GUA[id]
- df = DF_GUA
- when "HIT"
- lv = LV_HIT[id]
- df = DF_HIT
- when "CRI"
- lv = LV_CRI[id]
- df = DF_CRI
- when "PRI"
- lv = LV_PRI[id]
- df = DF_PRI[k]
- when "ATK"
- lv = LV_ATK[id]
- df = DF_ATK[k]
- when "PDE"
- lv = LV_PDE[id]
- df = DF_PDE[k]
- when "MDE"
- lv = LV_MDE[id]
- df = DF_MDE[k]
- when "STR"
- lv = LV_STR[id]
- df = DF_STR[k]
- when "DEX"
- lv = LV_DEX[id]
- df = DF_DEX[k]
- when "AGI"
- lv = LV_AGI[id]
- df = DF_AGI[k]
- when "INT"
- lv = LV_INT[id]
- df = DF_INT[k]
- end
- r= lv !=nil ? (lv.is_a?(Array) ? lv[k] :lv) :(df.is_a?(Hash) ? df[typ] :df)
- return r if r != nil
- return 0
- end
- def self.find_type(id)
- for i in 1...KIND.size
- kind = KIND[i]
- if ID.include?(kind)
- equip = ID[kind]
- if equip.include?(id)
- return i
- end
- else
- next
- end
- end
- return 0
- end
- end
- end
- module EciDevil
- class Game_Weapon
- include EciDevil
- attr_accessor :id
- attr_accessor :name
- attr_accessor :icon_name
- attr_accessor :description
- attr_accessor :animation1_id
- attr_accessor :animation2_id
- attr_accessor :element_set
- attr_accessor :plus_state_set
- attr_accessor :minus_state_set
- attr_accessor :level
- attr_accessor :exp
- attr_accessor :index
- attr_accessor :skill_type
- attr_accessor :mis_exp
- attr_accessor :gua_exp
- attr_accessor :hit_exp
- attr_accessor :cri_exp
- def initialize(weapon_id,index=nil,lv=0)
- if weapon_id == nil
- return nil
- end
- if weapon_id <= 0
- return nil
- end
- @index = index
- @index = $game_party.find_nil_index(0) if index == nil
- @id = weapon_id
- weapon = $data_weapons[weapon_id]
- @name = weapon.name
- @icon_name = weapon.icon_name
- @description = weapon.description
- @animation1_id = weapon.animation1_id
- @animation2_id = weapon.animation2_id
- @element_set = weapon.element_set
- @plus_state_set = weapon.plus_state_set
- @minus_state_set = weapon.minus_state_set
- @price_list = Weapon::make_list(weapon_id,"PRI")
- @atk_list = Weapon::make_list(weapon_id,"ATK")
- @pdef_list = Weapon::make_list(weapon_id,"PDE")
- @mdef_list = Weapon::make_list(weapon_id,"MDE")
- @str_list = Weapon::make_list(weapon_id,"STR")
- @dex_list = Weapon::make_list(weapon_id,"DEX")
- @agi_list = Weapon::make_list(weapon_id,"AGI")
- @int_list = Weapon::make_list(weapon_id,"INT")
- @level_limit = Weapon::find_lvup(weapon_id,"LMT")
- @exp_list = Weapon::make_list(weapon_id,"EXP")
- @skill_type = Weapon::find_lvup(weapon_id,"SKL")
- @mis_exp = Weapon::find_lvup(weapon_id,"MIS")
- @gua_exp = Weapon::find_lvup(weapon_id,"GUA")
- @hit_exp = Weapon::find_lvup(weapon_id,"HIT")
- @cri_exp = Weapon::find_lvup(weapon_id,"CRI")
- @ac_nam = Weapon::find_lvup(weapon_id,"NAM")
- @ac_ico = Weapon::find_lvup(weapon_id,"ICO")
- @ac_des = Weapon::find_lvup(weapon_id,"DES")
- @ac_aan = Weapon::find_lvup(weapon_id,"AAN")
- @ac_tan = Weapon::find_lvup(weapon_id,"TAN")
- @ac_ele = Weapon::find_lvup(weapon_id,"ELE")
- @ac_pst = Weapon::find_lvup(weapon_id,"PST")
- @ac_mst = Weapon::find_lvup(weapon_id,"MST")
- self.level=lv
- @exp = 0
- end
- def exp_next
- return 0 if @exp_list[@level+1] == nil
- return @exp_list[@level+1]
- end
- def price
- return @price_list[@level]
- end
- def atk
- return @atk_list[@level]
- end
- def pdef
- return @pdef_list[@level]
- end
- def mdef
- return @mdef_list[@level]
- end
- def str
- return @str_list[@level]
- end
- def dex
- return @dex_list[@level]
- end
- def agi
- return @agi_list[@level]
- end
- def int
- return @int_list[@level]
- end
- def exp=(exp)
- @exp = exp
- @exp = 0 if @exp < 0
- while @exp >= exp_next and exp_next > 0
- @exp -= exp_next
- self.level=(@level + 1) if @level < @level_limit
- end
- end
- def level=(level)
- @level = [[level, @level_limit].min, 0].max
- @name = @ac_nam[@level] if @ac_nam[@level] != nil
- @icon_name = @ac_ico[@level] if @ac_ico[@level] != nil
- @description = @ac_des[@level] if @ac_des[@level] != nil
- @animation1_id = @ac_aan[@level] if @ac_aan[@level] != nil
- @animation2_id = @ac_tan[@level] if @ac_tan[@level] != nil
- @element_set = @ac_ele[@level] if @ac_ele[@level] != nil
- @plus_state_set = @ac_pst[@level] if @ac_pst[@level] != nil
- @minus_state_set = @ac_mst[@level] if @ac_mst[@level] != nil
- if @level == @level_limit
- @exp = 0
- end
- end
- def index=(index)
- @index = index
- end
- end
- end
- #=============================================================================
- #防具
- #=============================================================================
- module EciDevil
- class Armor
- def self.find_bas(id,p)
- e = $data_armors[id]
- case p
- when "PRI"
- return e.price
- when "PDE"
- return e.pdef
- when "MDE"
- return e.mdef
- when "EVA"
- return e.eva
- when "STR"
- return e.str_plus
- when "DEX"
- return e.dex_plus
- when "AGI"
- return e.agi_plus
- when "INT"
- return e.int_plus
- end
- end
- def self.make_list(id,p)
- lmt = find_lvup(id,"LMT")
- case p
- when "EXP"
- poi = find_lvup(id,"POI")
- bas = find_lvup(id,"BAS")
- knd = find_lvup(id,"KND")
- list = [0]
- when "PRI","PDE","MDE","EVA","STR","DEX","AGI","INT"
- poi = find_lvup(id,p,0)
- knd = find_lvup(id,p,1)
- bas = find_bas(id,p)
- list = [bas]
- end
- for i in 1...(lmt+1)
- case knd
- when 0
- n = bas
- when 1
- n = bas + poi * (i-1)
- when 2
- n = bas + poi ** (i-1)
- when 3
- n = bas * ((i + 3) ** (2.4 + poi / 100.0)) / (5 ** (2.4 + poi / 100.0))
- when 4
- n = bas + list[i-1]
- when 5
- n = bas + poi * (i-1) + list[i-1]
- when 6
- n = bas + poi ** (i-1) + list[i-1]
- when 7
- n = bas * ((i + 3) ** (2.4 + poi / 100.0)) / (5 ** (2.4 + poi / 100.0)) + list[i-1]
- end
- list[i] = Integer(n)
- end
- return list
- end
- def self.find_lvup(id,p,k=0)
- if AUTO_CHANGE.has_key?(p)
- ac = AUTO_CHANGE[p]
- if ac[id] != nil
- return ac[id]
- end
- return {}
- end
- typ = find_type(id)
- if typ == 0
- return 0
- end
- case p
- when "TYP"
- return typ
- when "SKL"
- lv = LV_SKL[id]
- df = DF_SKL
- when "LMT"
- lv = LV_LMT[id]
- df = DF_LMT
- when "BAS"
- lv = LV_BAS[id]
- df = DF_BAS
- when "POI"
- lv = LV_POI[id]
- df = DF_POI
- when "KND"
- lv = LV_KND[id]
- df = DF_KND
- when "MIS"
- lv = LV_MIS[id]
- df = DF_MIS
- when "GUA"
- lv = LV_GUA[id]
- df = DF_GUA
- when "HIT"
- lv = LV_HIT[id]
- df = DF_HIT
- when "CRI"
- lv = LV_CRI[id]
- df = DF_CRI
- when "PRI"
- lv = LV_PRI[id]
- df = DF_PRI[k]
- when "PDE"
- lv = LV_PDE[id]
- df = DF_PDE[k]
- when "MDE"
- lv = LV_MDE[id]
- df = DF_MDE[k]
- when "EVA"
- lv = LV_EVA[id]
- df = DF_EVA[k]
- when "STR"
- lv = LV_STR[id]
- df = DF_STR[k]
- when "DEX"
- lv = LV_DEX[id]
- df = DF_DEX[k]
- when "AGI"
- lv = LV_AGI[id]
- df = DF_AGI[k]
- when "INT"
- lv = LV_INT[id]
- df = DF_INT[k]
- end
- r= lv !=nil ? (lv.is_a?(Array) ? lv[k] :lv) :(df.is_a?(Hash) ? df[typ] :df)
- return r if r != nil
- return 0
- end
- def self.find_type(id)
- for i in 1...KIND.size
- kind = KIND[i]
- if ID.include?(kind)
- equip = ID[kind]
- if equip.include?(id)
- return i
- end
- else
- next
- end
- end
- return 0
- end
- end
- end
- module EciDevil
- class Game_Armor
- include EciDevil
- attr_accessor :id
- attr_accessor :name
- attr_accessor :icon_name
- attr_accessor :description
- attr_accessor :kind
- attr_accessor :auto_state_id
- attr_accessor :guard_element_set
- attr_accessor :guard_state_set
- attr_accessor :level
- attr_accessor :exp
- attr_accessor :index
- attr_accessor :skill_type
- attr_accessor :mis_exp
- attr_accessor :gua_exp
- attr_accessor :hit_exp
- attr_accessor :cri_exp
- def initialize(armor_id,index=nil,lv=0)
- if armor_id == nil
- return nil
- end
- if armor_id <= 0
- return nil
- end
- @index = index
- @index = $game_party.find_nil_index(1) if index == nil
- @id = armor_id
- armor = $data_armors[armor_id]
- @name = armor.name
- @icon_name = armor.icon_name
- @description = armor.description
- @kind = armor.kind
- @auto_state_id = armor.auto_state_id
- @guard_element_set = armor.guard_element_set
- @guard_state_set = armor.guard_state_set
- @price_list = Armor::make_list(armor_id,"PRI")
- @pdef_list = Armor::make_list(armor_id,"PDE")
- @mdef_list = Armor::make_list(armor_id,"MDE")
- @eva_list = Armor::make_list(armor_id,"EVA")
- @str_list = Armor::make_list(armor_id,"STR")
- @dex_list = Armor::make_list(armor_id,"DEX")
- @agi_list = Armor::make_list(armor_id,"AGI")
- @int_list = Armor::make_list(armor_id,"INT")
- @level_limit = Armor::find_lvup(armor_id,"LMT")
- @exp_list = Armor::make_list(armor_id,"EXP")
- @skill_type = Armor::find_lvup(armor_id,"SKL")
- @mis_exp = Armor::find_lvup(armor_id,"MIS")
- @gua_exp = Armor::find_lvup(armor_id,"GUA")
- @hit_exp = Armor::find_lvup(armor_id,"HIT")
- @cri_exp = Armor::find_lvup(armor_id,"CRI")
- @ac_nam = Armor::find_lvup(armor_id,"NAM")
- @ac_ico = Armor::find_lvup(armor_id,"ICO")
- @ac_des = Armor::find_lvup(armor_id,"DES")
- @ac_ast = Armor::find_lvup(armor_id,"AST")
- @ac_gel = Armor::find_lvup(armor_id,"GEL")
- @ac_gst = Armor::find_lvup(armor_id,"GST")
- self.level=lv
- @exp = 0
- end
- def exp_next
- return 0 if @exp_list[@level+1] == nil
- return @exp_list[@level+1]
- end
- def price
- return @price_list[@level]
- end
- def pdef
- return @pdef_list[@level]
- end
- def mdef
- return @mdef_list[@level]
- end
- def eva
- return @eva_list[@level]
- end
- def str
- return @str_list[@level]
- end
- def dex
- return @dex_list[@level]
- end
- def agi
- return @agi_list[@level]
- end
- def int
- return @int_list[@level]
- end
- def exp=(exp)
- @exp = exp
- @exp = 0 if @exp < 0
- while @exp >= exp_next and exp_next > 0
- @exp -= exp_next
- self.level=(@level + 1) if @level < @level_limit
- end
- end
- def level=(level)
- @level = [[level, @level_limit].min, 0].max
- @name = @ac_nam[@level] if @ac_nam[@level] != nil
- @icon_name = @ac_ico[@level] if @ac_ico[@level] != nil
- @description = @ac_des[@level] if @ac_des[@level] != nil
- @auto_state_id = @ac_ast[@level] if @ac_ast[@level] != nil
- @guard_element_set = @ac_gel[@level] if @ac_gel[@level] != nil
- @guard_state_set = @ac_gst[@level] if @ac_gst[@level] != nil
- if @level == @level_limit
- @exp = 0
- end
- end
- def index=(index)
- @index = index
- end
- end
- end
复制代码
【范例】
http://rpg.blue/upload_program/d ... ��级_106262213.rar
|
|