diff --git a/data/MapInfos.json b/data/MapInfos.json
index 6a246aa..5072982 100644
--- a/data/MapInfos.json
+++ b/data/MapInfos.json
@@ -34,7 +34,7 @@ null,
{"id":32,"expanded":true,"name":"表世界宇宙","order":26,"parentId":1,"scrollX":1589,"scrollY":1613.5},
{"id":33,"expanded":true,"name":"柯伊伯站","order":27,"parentId":32,"scrollX":2069.3333333333335,"scrollY":2077.3333333333335},
{"id":34,"expanded":true,"name":"豆豆星系","order":28,"parentId":32,"scrollX":819,"scrollY":474.5},
-{"id":35,"expanded":false,"name":"豆豆星","order":29,"parentId":34,"scrollX":1450,"scrollY":4176.5},
+{"id":35,"expanded":false,"name":"豆豆星","order":29,"parentId":34,"scrollX":1434,"scrollY":4160.5},
{"id":36,"expanded":true,"name":"群星之城","order":30,"parentId":35,"scrollX":686.2222222222222,"scrollY":1432},
{"id":37,"expanded":false,"name":"测试用的地图","order":53,"parentId":1,"scrollX":693.3333333333334,"scrollY":424},
{"id":38,"expanded":true,"name":"艾瑞姆皇宫","order":31,"parentId":36,"scrollX":1157.3333333333333,"scrollY":1405.3333333333333},
diff --git a/data/Skills.json b/data/Skills.json
index 0f8b685..4591210 100644
--- a/data/Skills.json
+++ b/data/Skills.json
@@ -370,7 +370,7 @@ null,
{"id":368,"animationId":33,"damage":{"critical":false,"elementId":0,"formula":"0","type":0,"variance":20},"description":"用电流制造纯粹的强光掩护队友逃跑","effects":[{"code":41,"dataId":0,"value1":1,"value2":0}],"hitType":0,"iconIndex":70,"message1":"使用了%1!","message2":"","mpCost":5,"name":"逃脱闪光","note":"","occasion":1,"repeats":1,"requiredWtypeId1":0,"requiredWtypeId2":0,"scope":8,"speed":0,"stypeId":1,"successRate":100,"tpCost":0,"tpGain":0},
{"id":369,"animationId":0,"damage":{"critical":false,"elementId":0,"formula":"0","type":0,"variance":20},"description":"机械师必备的逃生装置,不属于组装物","effects":[{"code":41,"dataId":0,"value1":1,"value2":0}],"hitType":0,"iconIndex":307,"message1":"使用了%1!","message2":"","mpCost":0,"name":"逃生装置","note":"","occasion":1,"repeats":1,"requiredWtypeId1":0,"requiredWtypeId2":0,"scope":8,"speed":0,"stypeId":1,"successRate":100,"tpCost":0,"tpGain":0},
{"id":370,"animationId":0,"damage":{"critical":false,"elementId":6,"formula":"20+(1+a.level/45)*(a.atk * 3 + a.mat + a.agi/20 - b.def - b.mdf/3)*(a.level*a.atk/2048+2)","type":0,"variance":10},"description":"<强普显示><10%暴击叠加><无视嘲讽> 乱舞状态的普通攻击,几率造成\\it[56],\n挥舞武器时释放的生物电也会在身体周围形成一定的护盾","effects":[],"hitType":0,"iconIndex":76,"message1":"","message2":"","mpCost":0,"name":"普通攻击(乱舞状态)","note":"","occasion":3,"repeats":1,"requiredWtypeId1":0,"requiredWtypeId2":0,"scope":0,"speed":0,"stypeId":3,"successRate":100,"tpCost":0,"tpGain":5},
-{"id":371,"animationId":0,"damage":{"critical":false,"elementId":0,"formula":"0","type":0,"variance":20},"description":"在菜单里使用可以查看郝籽的被动说明","effects":[],"hitType":0,"iconIndex":0,"message1":"","message2":"","mpCost":0,"name":"郝籽被动说明","note":"","occasion":2,"repeats":1,"requiredWtypeId1":0,"requiredWtypeId2":0,"scope":0,"speed":0,"stypeId":3,"successRate":100,"tpCost":0,"tpGain":0},
+{"id":371,"animationId":0,"damage":{"critical":false,"elementId":0,"formula":"0","type":0,"variance":20},"description":"在菜单里使用可以查看郝籽的被动说明","effects":[{"code":44,"dataId":13,"value1":1,"value2":0}],"hitType":0,"iconIndex":0,"message1":"","message2":"","mpCost":0,"name":"郝籽被动说明","note":"","occasion":2,"repeats":1,"requiredWtypeId1":0,"requiredWtypeId2":0,"scope":0,"speed":0,"stypeId":3,"successRate":100,"tpCost":0,"tpGain":0},
{"id":372,"animationId":1,"damage":{"critical":true,"elementId":1,"formula":"1+(a.atk * 2+a.agi/200 - b.def*3/2)*(a.level*a.atk/2048+2)","type":1,"variance":20},"description":"","effects":[],"hitType":1,"iconIndex":0,"message1":"赤手空拳的攻击!","message2":"","mpCost":0,"name":"赤手空拳的攻击","note":"","occasion":1,"repeats":1,"requiredWtypeId1":0,"requiredWtypeId2":0,"scope":1,"speed":0,"stypeId":5,"successRate":100,"tpCost":0,"tpGain":8},
{"id":373,"animationId":10,"damage":{"critical":true,"elementId":8,"formula":"50+(3*(b.mhp-b.hp)/b.mhp)*(a.atk * 2+a.mat*2 - b.mdf- b.def)*(a.level*a.atk/2048+2)/2","type":1,"variance":20},"description":"对濒死敌人进行最后一击的杀戮剑术","effects":[{"code":21,"dataId":0,"value1":1,"value2":0}],"hitType":1,"iconIndex":99,"message1":"的强力攻击!","message2":"","mpCost":0,"name":"绝剑诛邪I","note":"","occasion":1,"repeats":1,"requiredWtypeId1":0,"requiredWtypeId2":0,"scope":1,"speed":0,"stypeId":5,"successRate":100,"tpCost":0,"tpGain":10},
{"id":374,"animationId":12,"damage":{"critical":true,"elementId":-1,"formula":"1+(1/2+b.hp/(2*b.mhp) + a.level/198)*(a.atk*5/2 +a.mat*3/2 - b.def-b.mdf/2)*(a.level*a.atk/2048+2)","type":0,"variance":20},"description":"<强普显示> 伊扎克斯刚成为魔王时的得意技能,只能在真身状态下,\n通过叠满魔力层数获得释放机会(详情查看被动说明)","effects":[],"hitType":1,"iconIndex":0,"message1":"使用了%1!","message2":"","mpCost":0,"name":"魔王斩","note":"","occasion":3,"repeats":1,"requiredWtypeId1":0,"requiredWtypeId2":0,"scope":0,"speed":0,"stypeId":4,"successRate":100,"tpCost":0,"tpGain":10},
diff --git a/data/System.json b/data/System.json
index 00ec484..a52f3f7 100644
--- a/data/System.json
+++ b/data/System.json
@@ -1 +1 @@
-{"airship":{"bgm":{"name":"Ship3","pan":0,"pitch":100,"volume":90},"characterIndex":0,"characterName":"$巨龟岩台号","startMapId":0,"startX":0,"startY":0},"armorTypes":["","轻甲","重甲","魔法护甲","普通饰品","魔法饰品","魔法球","副手匕首","副手枪械","左手爪"],"attackMotions":[{"type":0,"weaponImageId":0},{"type":1,"weaponImageId":2},{"type":1,"weaponImageId":9},{"type":1,"weaponImageId":1},{"type":1,"weaponImageId":4},{"type":1,"weaponImageId":10},{"type":1,"weaponImageId":7},{"type":2,"weaponImageId":21},{"type":1,"weaponImageId":14},{"type":1,"weaponImageId":11},{"type":0,"weaponImageId":10},{"type":0,"weaponImageId":11},{"type":0,"weaponImageId":12}],"battleBgm":{"name":"Battle1","pan":0,"pitch":100,"volume":90},"battleback1Name":"DecorativeTile","battleback2Name":"Temple","battlerHue":0,"battlerName":"Dragon","boat":{"bgm":{"name":"Ship1","pan":0,"pitch":100,"volume":90},"characterIndex":0,"characterName":"Vehicle","startMapId":0,"startX":0,"startY":0},"currencyUnit":"经费","defeatMe":{"name":"Defeat1","pan":0,"pitch":100,"volume":90},"editMapId":35,"elements":["","物理","地","风","水","火","电","冰","圣","暗","精神","力场","混沌","幽能","毒","生命治疗","冰火双伤","真实","生命吸取"],"equipTypes":["","武器","副手","帽子","甲衣","靴子","项链","戒指"],"gameTitle":"异常生物见闻录","gameoverMe":{"name":"Gameover1","pan":0,"pitch":100,"volume":90},"locale":"zh_CN","magicSkills":[2],"menuCommands":[true,true,true,true,true,true],"optDisplayTp":true,"optDrawTitle":true,"optExtraExp":false,"optFloorDeath":false,"optFollowers":true,"optSideView":false,"optSlipDeath":false,"optTransparent":false,"partyMembers":[1],"ship":{"bgm":{"name":"Kan R Gao - Floating By","pan":0,"pitch":100,"volume":100},"characterIndex":1,"characterName":"Vehicle","startMapId":31,"startX":174,"startY":58},"skillTypes":["","特技","魔法","专属技能","神术与天赋","各种普通攻击"],"sounds":[{"name":"Cursor2","pan":0,"pitch":100,"volume":90},{"name":"Decision1","pan":0,"pitch":100,"volume":90},{"name":"Cancel2","pan":0,"pitch":100,"volume":90},{"name":"Buzzer1","pan":0,"pitch":100,"volume":90},{"name":"Equip1","pan":0,"pitch":100,"volume":90},{"name":"Save","pan":0,"pitch":100,"volume":90},{"name":"Load","pan":0,"pitch":100,"volume":90},{"name":"Battle1","pan":0,"pitch":100,"volume":90},{"name":"Run","pan":0,"pitch":100,"volume":90},{"name":"Attack3","pan":0,"pitch":100,"volume":90},{"name":"Damage4","pan":0,"pitch":100,"volume":90},{"name":"Collapse1","pan":0,"pitch":100,"volume":90},{"name":"Collapse2","pan":0,"pitch":100,"volume":90},{"name":"Collapse3","pan":0,"pitch":100,"volume":90},{"name":"Damage5","pan":0,"pitch":100,"volume":90},{"name":"Collapse4","pan":0,"pitch":100,"volume":90},{"name":"Recovery","pan":0,"pitch":100,"volume":90},{"name":"Miss","pan":0,"pitch":100,"volume":90},{"name":"Evasion1","pan":0,"pitch":100,"volume":90},{"name":"Evasion2","pan":0,"pitch":100,"volume":90},{"name":"Reflection","pan":0,"pitch":100,"volume":90},{"name":"Shop1","pan":0,"pitch":100,"volume":90},{"name":"Item3","pan":0,"pitch":100,"volume":90},{"name":"Item3","pan":0,"pitch":100,"volume":90}],"startMapId":65,"startX":18,"startY":31,"switches":["","吃完饭","水管爆了","薇薇安出现","蝙蝠出现","海妖现身","五月海妖形态","出现水泡","水塔剧情借宿","去地下室","治疗海妖","准备出发","苏哈白火出现","击败幽灵船","不明海妖出现","丧尸出现","发现丧尸","击败人鱼","对战冰系怪物","对战老鼠怪","对战蝙蝠怪","对战火系怪物","飞砖对话","豆豆星彩蛋完成","熔岩巨蝎出现","击败巨蝎","收集素材","对战魔族","第一次狗炮时的对话","狗炮彩蛋剧情结束","对战恶灵生物","怪物秒杀开关","阿拉曼达开局剧情完成","希尔妲对话完成","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","偷看","尝试交互","触碰脑和容器","完成研究红球","击败伊娃","出现水花","水花伤害","增加火球1","增加火球2","增加火球3","增加背球","增加左球","增加右球","进入纳萨托恩","进入管道","海妖消失","丧尸复苏","水晶破碎","打败守门海妖哨兵","被海妖围了","击败脑怪","密室","击败密室门卫","支援老王","击败海妖女王","发现大漩涡","前往水涌之核","关闭大护壁","豆豆出现","清理皇宫","清理完成","莎奇拉水泡开","点击w","能召唤飞船","初次进入研究炸","游戏开始","点击Q","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","",""],"terms":{"basic":["等级","Lv","HP","HP","MP","MP","TP","TP","经验值","EXP"],"commands":["战斗","逃跑","攻击","防御","物品","技能","装备","状态","整队","保存","游戏结束","设置","武器","护甲","随身杂物","装备","最强装备","清空","开始游戏","继续游戏",null,"回到标题","取消",null,"购买","出售"],"params":["最大 HP","最大 MP","攻击力","防御力","魔法攻击","魔法防御","敏捷","幸运","命中率","回避率"],"messages":{"actionFailure":"对%1没有效果!","actorDamage":"%1受到了 %2 点伤害!","actorDrain":"%1被吸收了 %3 点 %2!","actorGain":"%1的 %2 增加了 %3 点!","actorLoss":"%1的 %2 减少了 %3 点!","actorNoDamage":"%1没有受到伤害!","actorNoHit":"Miss! %1没有受到伤害!","actorRecovery":"%1恢复了 %3 点 %2!","alwaysDash":"始终跑步","bgmVolume":"BGM 音量","bgsVolume":"BGS 音量","buffAdd":"%1的%2上升了!","buffRemove":"%1的%2恢复正常了!","commandRemember":"记住指令","counterAttack":"%1的反击!","criticalToActor":"痛恨一击!","criticalToEnemy":"会心一击!","debuffAdd":"%1的%2下降了!","defeat":"%1被击败了。","emerge":"%1出现了!","enemyDamage":"%1受到了 %2 点伤害!","enemyDrain":"%1被吸收了 %3 点 %2!","enemyGain":"%1的 %2 增加了 %3 点!","enemyLoss":"%1的 %2 减少了 %3 点!","enemyNoDamage":"没有对%1造成伤害!","enemyNoHit":"Miss!没有对%1造成伤害!","enemyRecovery":"%1恢复了 %3 点 %2!","escapeFailure":"但是没有逃跑成功!","escapeStart":"%1开始逃跑了!","evasion":"%1躲开了攻击!","expNext":"距离下一%1","expTotal":"现在的%1","file":"文件","levelUp":"%1升到了 %2 %3!","loadMessage":"读取哪个文件?","magicEvasion":"%1抵消了魔法!","magicReflection":"%1反射了魔法!","meVolume":"ME 音量","obtainExp":"获得了 %1 点%2!","obtainGold":"获得了 %1\\G!","obtainItem":"获得了%1!","obtainSkill":"学会了%1!","partyName":"%1的队伍","possession":"持有数","preemptive":"%1先发制人!","saveMessage":"保存到哪个文件?","seVolume":"SE 音量","substitute":"%1保护了%2!","surprise":"%1被偷袭了!","useItem":"%1使用了%2!","victory":"%1胜利了!"}},"testBattlers":[{"actorId":1,"equips":[6,0,0,0,0],"level":12},{"actorId":8,"equips":[0,0,0,0,0],"level":12},{"actorId":0,"equips":[3,0,2,3,4],"level":1},{"actorId":0,"equips":[4,0,2,3,4],"level":1}],"testTroopId":17,"title1Name":"Plain","title2Name":"","titleBgm":{"name":"猫耳开关","pan":0,"pitch":100,"volume":90},"variables":["","技能数值","数据判断","掉落物概率随机数","","诺兰扣血数值","时间推进","诺兰应急维修计数","刚性护盾数值计算","海妖碰撞伤害","火位置X","火位置Y","玩家方向","火距离","BGM编号记录","清理废墟","","","","","","地图ID","玩家位置X","玩家位置Y","图片移动X","图片移动Y","随机数","火1位置X","火1位置Y","火1距离","火2位置X","火2位置Y","火2距离","火3位置X","火3位置Y","火3距离","背火位置X","背火位置Y","背火距离","右火位置X","右火位置Y","右火距离","左火位置X","左火位置Y","左火距离","海妖碰撞伤害1","海妖碰撞伤害2","海妖碰撞伤害3","海妖碰撞伤害背","海妖碰撞伤害右","海妖碰撞伤害左","玩家方向1","玩家方向2","玩家方向3","玩家方向4","玩家方向5","玩家方向6","伊娃血量","","","","史莱姆核心结晶数量","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","",""],"versionId":71019623,"victoryMe":{"name":"Victory1","pan":0,"pitch":100,"volume":90},"weaponTypes":["","剑","长柄武器","匕首","斧","爪","弓弩","枪炮","法杖","莉莉的爪子","魔王佩剑","魔导工作手套","宇宙碎片长剑"],"windowTone":[0,0,0,0]}
\ No newline at end of file
+{"airship":{"bgm":{"name":"Ship3","pan":0,"pitch":100,"volume":90},"characterIndex":0,"characterName":"$巨龟岩台号","startMapId":0,"startX":0,"startY":0},"armorTypes":["","轻甲","重甲","魔法护甲","普通饰品","魔法饰品","魔法球","副手匕首","副手枪械","左手爪"],"attackMotions":[{"type":0,"weaponImageId":0},{"type":1,"weaponImageId":2},{"type":1,"weaponImageId":9},{"type":1,"weaponImageId":1},{"type":1,"weaponImageId":4},{"type":1,"weaponImageId":10},{"type":1,"weaponImageId":7},{"type":2,"weaponImageId":21},{"type":1,"weaponImageId":14},{"type":1,"weaponImageId":11},{"type":0,"weaponImageId":10},{"type":0,"weaponImageId":11},{"type":0,"weaponImageId":12}],"battleBgm":{"name":"Battle1","pan":0,"pitch":100,"volume":90},"battleback1Name":"DecorativeTile","battleback2Name":"Temple","battlerHue":0,"battlerName":"Dragon","boat":{"bgm":{"name":"Ship1","pan":0,"pitch":100,"volume":90},"characterIndex":0,"characterName":"Vehicle","startMapId":0,"startX":0,"startY":0},"currencyUnit":"经费","defeatMe":{"name":"Defeat1","pan":0,"pitch":100,"volume":90},"editMapId":35,"elements":["","物理","地","风","水","火","电","冰","圣","暗","精神","力场","混沌","幽能","毒","生命治疗","冰火双伤","真实","生命吸取"],"equipTypes":["","武器","副手","帽子","甲衣","靴子","项链","戒指"],"gameTitle":"异常生物见闻录","gameoverMe":{"name":"Gameover1","pan":0,"pitch":100,"volume":90},"locale":"zh_CN","magicSkills":[2],"menuCommands":[true,true,true,true,true,true],"optDisplayTp":true,"optDrawTitle":true,"optExtraExp":false,"optFloorDeath":false,"optFollowers":true,"optSideView":false,"optSlipDeath":false,"optTransparent":false,"partyMembers":[1],"ship":{"bgm":{"name":"Kan R Gao - Floating By","pan":0,"pitch":100,"volume":100},"characterIndex":1,"characterName":"Vehicle","startMapId":31,"startX":174,"startY":58},"skillTypes":["","特技","魔法","专属技能","神术与天赋","各种普通攻击"],"sounds":[{"name":"Cursor2","pan":0,"pitch":100,"volume":90},{"name":"Decision1","pan":0,"pitch":100,"volume":90},{"name":"Cancel2","pan":0,"pitch":100,"volume":90},{"name":"Buzzer1","pan":0,"pitch":100,"volume":90},{"name":"Equip1","pan":0,"pitch":100,"volume":90},{"name":"Save","pan":0,"pitch":100,"volume":90},{"name":"Load","pan":0,"pitch":100,"volume":90},{"name":"Battle1","pan":0,"pitch":100,"volume":90},{"name":"Run","pan":0,"pitch":100,"volume":90},{"name":"Attack3","pan":0,"pitch":100,"volume":90},{"name":"Damage4","pan":0,"pitch":100,"volume":90},{"name":"Collapse1","pan":0,"pitch":100,"volume":90},{"name":"Collapse2","pan":0,"pitch":100,"volume":90},{"name":"Collapse3","pan":0,"pitch":100,"volume":90},{"name":"Damage5","pan":0,"pitch":100,"volume":90},{"name":"Collapse4","pan":0,"pitch":100,"volume":90},{"name":"Recovery","pan":0,"pitch":100,"volume":90},{"name":"Miss","pan":0,"pitch":100,"volume":90},{"name":"Evasion1","pan":0,"pitch":100,"volume":90},{"name":"Evasion2","pan":0,"pitch":100,"volume":90},{"name":"Reflection","pan":0,"pitch":100,"volume":90},{"name":"Shop1","pan":0,"pitch":100,"volume":90},{"name":"Item3","pan":0,"pitch":100,"volume":90},{"name":"Item3","pan":0,"pitch":100,"volume":90}],"startMapId":65,"startX":18,"startY":31,"switches":["","吃完饭","水管爆了","薇薇安出现","蝙蝠出现","海妖现身","五月海妖形态","出现水泡","水塔剧情借宿","去地下室","治疗海妖","准备出发","苏哈白火出现","击败幽灵船","不明海妖出现","丧尸出现","发现丧尸","击败人鱼","对战冰系怪物","对战老鼠怪","对战蝙蝠怪","对战火系怪物","飞砖对话","豆豆星彩蛋完成","熔岩巨蝎出现","击败巨蝎","收集素材","对战魔族","第一次狗炮时的对话","狗炮彩蛋剧情结束","对战恶灵生物","怪物秒杀开关","阿拉曼达开局剧情完成","希尔妲对话完成","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","偷看","尝试交互","触碰脑和容器","完成研究红球","击败伊娃","出现水花","水花伤害","增加火球1","增加火球2","增加火球3","增加背球","增加左球","增加右球","进入纳萨托恩","进入管道","海妖消失","丧尸复苏","水晶破碎","打败守门海妖哨兵","被海妖围了","击败脑怪","密室","击败密室门卫","支援老王","击败海妖女王","发现大漩涡","前往水涌之核","关闭大护壁","豆豆出现","清理皇宫","清理完成","莎奇拉水泡开","点击w","能召唤飞船","初次进入研究炸","游戏开始","点击Q","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","",""],"terms":{"basic":["等级","Lv","HP","HP","MP","MP","TP","TP","经验值","EXP"],"commands":["战斗","逃跑","攻击","防御","物品","技能","装备","状态","整队","保存","游戏结束","设置","武器","护甲","随身杂物","装备","最强装备","清空","开始游戏","继续游戏",null,"回到标题","取消",null,"购买","出售"],"params":["最大 HP","最大 MP","攻击力","防御力","魔法攻击","魔法防御","敏捷","幸运","命中率","回避率"],"messages":{"actionFailure":"对%1没有效果!","actorDamage":"%1受到了 %2 点伤害!","actorDrain":"%1被吸收了 %3 点 %2!","actorGain":"%1的 %2 增加了 %3 点!","actorLoss":"%1的 %2 减少了 %3 点!","actorNoDamage":"%1没有受到伤害!","actorNoHit":"Miss! %1没有受到伤害!","actorRecovery":"%1恢复了 %3 点 %2!","alwaysDash":"始终跑步","bgmVolume":"BGM 音量","bgsVolume":"BGS 音量","buffAdd":"%1的%2上升了!","buffRemove":"%1的%2恢复正常了!","commandRemember":"记住指令","counterAttack":"%1的反击!","criticalToActor":"痛恨一击!","criticalToEnemy":"会心一击!","debuffAdd":"%1的%2下降了!","defeat":"%1被击败了。","emerge":"%1出现了!","enemyDamage":"%1受到了 %2 点伤害!","enemyDrain":"%1被吸收了 %3 点 %2!","enemyGain":"%1的 %2 增加了 %3 点!","enemyLoss":"%1的 %2 减少了 %3 点!","enemyNoDamage":"没有对%1造成伤害!","enemyNoHit":"Miss!没有对%1造成伤害!","enemyRecovery":"%1恢复了 %3 点 %2!","escapeFailure":"但是没有逃跑成功!","escapeStart":"%1开始逃跑了!","evasion":"%1躲开了攻击!","expNext":"距离下一%1","expTotal":"现在的%1","file":"文件","levelUp":"%1升到了 %2 %3!","loadMessage":"读取哪个文件?","magicEvasion":"%1抵消了魔法!","magicReflection":"%1反射了魔法!","meVolume":"ME 音量","obtainExp":"获得了 %1 点%2!","obtainGold":"获得了 %1\\G!","obtainItem":"获得了%1!","obtainSkill":"学会了%1!","partyName":"%1的队伍","possession":"持有数","preemptive":"%1先发制人!","saveMessage":"保存到哪个文件?","seVolume":"SE 音量","substitute":"%1保护了%2!","surprise":"%1被偷袭了!","useItem":"%1使用了%2!","victory":"%1胜利了!"}},"testBattlers":[{"actorId":1,"equips":[6,0,0,0,0],"level":12},{"actorId":8,"equips":[0,0,0,0,0],"level":12},{"actorId":0,"equips":[3,0,2,3,4],"level":1},{"actorId":0,"equips":[4,0,2,3,4],"level":1}],"testTroopId":17,"title1Name":"Plain","title2Name":"","titleBgm":{"name":"猫耳开关","pan":0,"pitch":100,"volume":90},"variables":["","技能数值","数据判断","掉落物概率随机数","","诺兰扣血数值","时间推进","诺兰应急维修计数","刚性护盾数值计算","海妖碰撞伤害","火位置X","火位置Y","玩家方向","火距离","BGM编号记录","清理废墟","","","","","","地图ID","玩家位置X","玩家位置Y","图片移动X","图片移动Y","随机数","火1位置X","火1位置Y","火1距离","火2位置X","火2位置Y","火2距离","火3位置X","火3位置Y","火3距离","背火位置X","背火位置Y","背火距离","右火位置X","右火位置Y","右火距离","左火位置X","左火位置Y","左火距离","海妖碰撞伤害1","海妖碰撞伤害2","海妖碰撞伤害3","海妖碰撞伤害背","海妖碰撞伤害右","海妖碰撞伤害左","玩家方向1","玩家方向2","玩家方向3","玩家方向4","玩家方向5","玩家方向6","伊娃血量","","","","史莱姆核心结晶数量","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","",""],"versionId":9570604,"victoryMe":{"name":"Victory1","pan":0,"pitch":100,"volume":90},"weaponTypes":["","剑","长柄武器","匕首","斧","爪","弓弩","枪炮","法杖","莉莉的爪子","魔王佩剑","魔导工作手套","宇宙碎片长剑"],"windowTone":[0,0,0,0]}
\ No newline at end of file
diff --git a/img/VirtualButtons/4dir.png b/img/VirtualButtons/4dir.png
new file mode 100644
index 0000000..949d9e8
Binary files /dev/null and b/img/VirtualButtons/4dir.png differ
diff --git a/img/VirtualButtons/Control.bac.png b/img/VirtualButtons/Control.bac.png
new file mode 100644
index 0000000..7e0f592
Binary files /dev/null and b/img/VirtualButtons/Control.bac.png differ
diff --git a/img/VirtualButtons/Control.png b/img/VirtualButtons/Control.png
new file mode 100644
index 0000000..5f4ce38
Binary files /dev/null and b/img/VirtualButtons/Control.png differ
diff --git a/img/VirtualButtons/DEBUG.bac.png b/img/VirtualButtons/DEBUG.bac.png
new file mode 100644
index 0000000..836c383
Binary files /dev/null and b/img/VirtualButtons/DEBUG.bac.png differ
diff --git a/img/VirtualButtons/DEBUG.png b/img/VirtualButtons/DEBUG.png
new file mode 100644
index 0000000..836c383
Binary files /dev/null and b/img/VirtualButtons/DEBUG.png differ
diff --git a/img/VirtualButtons/DEBUG1.png b/img/VirtualButtons/DEBUG1.png
new file mode 100644
index 0000000..a2916dd
Binary files /dev/null and b/img/VirtualButtons/DEBUG1.png differ
diff --git a/img/VirtualButtons/DEBUG2.png b/img/VirtualButtons/DEBUG2.png
new file mode 100644
index 0000000..63ef093
Binary files /dev/null and b/img/VirtualButtons/DEBUG2.png differ
diff --git a/img/VirtualButtons/Directions.png b/img/VirtualButtons/Directions.png
new file mode 100644
index 0000000..fd0dac0
Binary files /dev/null and b/img/VirtualButtons/Directions.png differ
diff --git a/img/VirtualButtons/ESC.png b/img/VirtualButtons/ESC.png
new file mode 100644
index 0000000..d66f3d6
Binary files /dev/null and b/img/VirtualButtons/ESC.png differ
diff --git a/img/VirtualButtons/Menu.png b/img/VirtualButtons/Menu.png
new file mode 100644
index 0000000..a3d32e2
Binary files /dev/null and b/img/VirtualButtons/Menu.png differ
diff --git a/img/VirtualButtons/Menu1.png b/img/VirtualButtons/Menu1.png
new file mode 100644
index 0000000..035867a
Binary files /dev/null and b/img/VirtualButtons/Menu1.png differ
diff --git a/img/VirtualButtons/Menu2.png b/img/VirtualButtons/Menu2.png
new file mode 100644
index 0000000..6b80e01
Binary files /dev/null and b/img/VirtualButtons/Menu2.png differ
diff --git a/img/VirtualButtons/OK.png b/img/VirtualButtons/OK.png
new file mode 100644
index 0000000..64e3341
Binary files /dev/null and b/img/VirtualButtons/OK.png differ
diff --git a/img/VirtualButtons/OK1.png b/img/VirtualButtons/OK1.png
new file mode 100644
index 0000000..e30c089
Binary files /dev/null and b/img/VirtualButtons/OK1.png differ
diff --git a/img/VirtualButtons/OK2.png b/img/VirtualButtons/OK2.png
new file mode 100644
index 0000000..1a958dc
Binary files /dev/null and b/img/VirtualButtons/OK2.png differ
diff --git a/img/VirtualButtons/PageDown.png b/img/VirtualButtons/PageDown.png
new file mode 100644
index 0000000..c8273f1
Binary files /dev/null and b/img/VirtualButtons/PageDown.png differ
diff --git a/img/VirtualButtons/PageUp.png b/img/VirtualButtons/PageUp.png
new file mode 100644
index 0000000..c072acf
Binary files /dev/null and b/img/VirtualButtons/PageUp.png differ
diff --git a/img/VirtualButtons/Points.png b/img/VirtualButtons/Points.png
new file mode 100644
index 0000000..15283e1
Binary files /dev/null and b/img/VirtualButtons/Points.png differ
diff --git a/img/VirtualButtons/dynamic.png b/img/VirtualButtons/dynamic.png
new file mode 100644
index 0000000..b805d9f
Binary files /dev/null and b/img/VirtualButtons/dynamic.png differ
diff --git a/img/VirtualButtons/dynamic_1.png b/img/VirtualButtons/dynamic_1.png
new file mode 100644
index 0000000..0ce76b2
Binary files /dev/null and b/img/VirtualButtons/dynamic_1.png differ
diff --git a/img/VirtualButtons/dynamic_2.png b/img/VirtualButtons/dynamic_2.png
new file mode 100644
index 0000000..745c9cf
Binary files /dev/null and b/img/VirtualButtons/dynamic_2.png differ
diff --git a/js/plugins.js b/js/plugins.js
index 9c68334..b89b799 100644
--- a/js/plugins.js
+++ b/js/plugins.js
@@ -78,5 +78,6 @@ var $plugins =
{"name":"YEP_QuestJournal","status":true,"description":"YEP任务日志系统-优","parameters":{"---Main Menu---":"","Quest Command":"任务","Show Command":"true","Enable Command":"true","Auto Place Command":"true","---Quest Menu---":"","Quest Category Window":"{\"---Categories---\":\"\",\"Category Order\":\"[\\\"available\\\",\\\"completed\\\",\\\"failed\\\",\\\"all\\\"]\",\"Available Text\":\"\\\\i[192]正进行任务 (%1)\",\"Completed Text\":\"\\\\i[191]已完成任务 (%1)\",\"Failed Text\":\"\\\\i[194]失败的任务 (%1)\",\"All Text\":\"\\\\i[189]所有的任务 (%1)\",\"Cancel Text\":\"\\\\i[161]取消\",\"---Window Settings---\":\"\",\"X\":\"0\",\"Y\":\"0\",\"Width\":\"Graphics.boxWidth / 3\",\"Height\":\"this.fittingHeight(this.numVisibleRows())\",\"Rows\":\"4\",\"Columns\":\"1\",\"Line Height\":\"36\",\"Font Face\":\"GameFont\",\"Font Size\":\"28\",\"Standard Padding\":\"18\",\"Text Padding\":\"6\",\"Text Alignment\":\"left\",\"Standard Opacity\":\"255\",\"Back Opacity\":\"192\",\"Window Skin\":\"Window\"}","Quest List Window":"{\"---Types---\":\"\",\"Show Types\":\"true\",\"Type Order\":\"[\\\"\\\\\\\\c[6]主线任务\\\",\\\"\\\\\\\\c[4]支线任务\\\",\\\"\\\\\\\\c[3]特殊任务\\\",\\\"\\\\\\\\c[5]教程任务\\\"]\",\"List Open Symbol\":\"-\",\"List Closed Symbol\":\"+\",\"Type Text Format\":\"%1%2 (%3)\",\"Quest Indent\":\"0\",\"Show Empty\":\"false\",\"Read Quest\":\"\\\\i[121]查看任务\",\"Cancel\":\"\\\\i[16]退出\",\"---Window Settings---\":\"\",\"X\":\"0\",\"Y\":\"Graphics.boxHeight - height\",\"Width\":\"Graphics.boxWidth / 3\",\"Height\":\"Graphics.boxHeight - this.fittingHeight(4)\",\"Line Height\":\"36\",\"Font Face\":\"GameFont\",\"Font Size\":\"28\",\"Standard Padding\":\"18\",\"Text Padding\":\"6\",\"Standard Opacity\":\"255\",\"Back Opacity\":\"192\",\"Type Alignment\":\"left\",\"Quest Alignment\":\"left\",\"Window Skin\":\"Window\"}","Quest Title Window":"{\"---Window Settings---\":\"\",\"No Quest Title\":\"\\\\c[4]❀ 任务日志 ❀\",\"X\":\"Graphics.boxWidth - width\",\"Y\":\"0\",\"Width\":\"Graphics.boxWidth * 2 / 3\",\"Height\":\"this.fittingHeight(1)\",\"Line Height\":\"36\",\"Font Face\":\"GameFont\",\"Font Size\":\"28\",\"Standard Padding\":\"18\",\"Text Padding\":\"6\",\"Text Alignment\":\"center\",\"Standard Opacity\":\"255\",\"Back Opacity\":\"192\",\"Window Skin\":\"Window\"}","Quest Data Window":"{\"---Data Settings---\":\"\",\"No Data Text\":\"\\\"欢迎来到 \\\\\\\\c[4]任务系统\\\\\\\\c[0].\\\\n\\\"\",\"Quest Data Format\":\"\\\"\\\\\\\\c[4]任务难度:\\\\\\\\c[0] %2\\\\n\\\\\\\\c[4]任务发布:\\\\\\\\c[0] %3\\\\n\\\\\\\\c[4]发布地点:\\\\\\\\c[0] %4\\\\n\\\\n\\\\\\\\c[4]任务描述:\\\\\\\\c[0]\\\\n%5\\\\n\\\\n\\\\\\\\c[4]任务目标:\\\\\\\\c[0]\\\\n%6\\\\n\\\\n\\\\\\\\c[4]任务奖励:\\\\\\\\c[0]\\\\n%7\\\\n\\\\n%8\\\"\",\"Uncleared Objective\":\"\\\\i[160]%1\",\"Completed Objective\":\"\\\\i[165]%1\",\"Failed Objective\":\"\\\\i[162]%1\",\"Unclaimed Reward\":\"\\\\i[160]%1\",\"Claimed Reward\":\"\\\\i[163]%1\",\"Denied Reward\":\"\\\\i[161]%1\",\"Load Delay\":\"30\",\"---Window Settings---\":\"\",\"X\":\"Graphics.boxWidth - width\",\"Y\":\"Graphics.boxHeight - height\",\"Width\":\"Graphics.boxWidth * 2 / 3\",\"Height\":\"Graphics.boxHeight - this.fittingHeight(1)\",\"Line Height\":\"36\",\"Font Face\":\"GameFont\",\"Font Size\":\"28\",\"Standard Padding\":\"18\",\"Text Padding\":\"6\",\"Standard Opacity\":\"255\",\"Back Opacity\":\"192\",\"Window Skin\":\"Window\",\"Scroll Speed\":\"4\"}","Lunatic Mode":"{\"---Quest Menu---\":\"\",\"Before Create Windows\":\"\\\"// Variables\\\\n// background - background image used for the menu\\\\n// windowLayer - sprite layer that contains all windows\\\\n//\\\\n// background.bitmap = ImageManager.loadTitle1(\\\\\\\"Book\\\\\\\");\\\\n// this.fitScreen(background);\\\"\",\"After Create Windows\":\"\\\"// Variables\\\\n// background - background image used for the menu\\\\n// windowLayer - sprite layer that contains all windows\\\"\",\"Close Quest Menu\":\"\\\"// Variables\\\\n// background - background image used for the menu\\\\n// windowLayer - sprite layer that contains all windows\\\"\",\"---Quest Status---\":\"\",\"Quest Add\":\"\\\"// Variables:\\\\n// questId - ID of the quest being added\\\\n//\\\\n// console.log('Quest ' + questId + ' successfully added!')\\\"\",\"Quest Remove\":\"\\\"// Variables:\\\\n// questId - ID of the quest being removed\\\\n//\\\\n// console.log('Quest ' + questId + ' successfully removed!')\\\"\",\"Quest Complete\":\"\\\"// Variables:\\\\n// questId - ID of the quest set to completed\\\\n//\\\\n// console.log('Quest ' + questId + ' status changed to Completed!')\\\"\",\"Quest Fail\":\"\\\"// Variables:\\\\n// questId - ID of the quest set to failed\\\\n//\\\\n// console.log('Quest ' + questId + ' status changed to Failed!')\\\"\",\"Quest Available\":\"\\\"// Variables:\\\\n// questId - ID of the quest set to available\\\\n//\\\\n// console.log('Quest ' + questId + ' status changed to Available!')\\\"\",\"---Description---\":\"\",\"Change Description\":\"\\\"// Variables:\\\\n// questId - ID of the quest whose description is changed\\\\n// index - Description index being changed to\\\\n//\\\\n// console.log('Quest ' + questId + ' description index changed to ' + index)\\\"\",\"---Objectives---\":\"\",\"Show Objective\":\"\\\"// Variables:\\\\n// questId - ID of the quest whose objectives are altered\\\\n// objectiveId - ID of the objective being shown\\\\n//\\\\n// console.log('Quest ' + questId + ' objective ' + objectiveId + ' changed to shown!')\\\"\",\"Hide Objective\":\"\\\"// Variables:\\\\n// questId - ID of the quest whose objectives are altered\\\\n// objectiveId - ID of the objective being hidden\\\\n//\\\\n// console.log('Quest ' + questId + ' objective ' + objectiveId + ' changed to hidden!')\\\"\",\"Complete Objective\":\"\\\"// Variables:\\\\n// questId - ID of the quest whose objectives are altered\\\\n// objectiveId - ID of the objective being completed\\\\n//\\\\n// console.log('Quest ' + questId + ' objective ' + objectiveId + ' changed to completed!')\\\"\",\"Fail Objective\":\"\\\"// Variables:\\\\n// questId - ID of the quest whose objectives are altered\\\\n// objectiveId - ID of the objective having failed\\\\n//\\\\n// console.log('Quest ' + questId + ' objective ' + objectiveId + ' changed to failed!')\\\"\",\"Normalize Objective\":\"\\\"// Variables:\\\\n// questId - ID of the quest whose objectives are altered\\\\n// objectiveId - ID of the objective normalized\\\\n//\\\\n// console.log('Quest ' + questId + ' objective ' + objectiveId + ' changed to normal!')\\\"\",\"---Rewards---\":\"\",\"Show Reward\":\"\\\"// Variables:\\\\n// questId - ID of the quest whose rewards are altered\\\\n// rewardId - ID of the reward being shown\\\\n//\\\\n// console.log('Quest ' + questId + ' reward ' + rewardId + ' becomes shown!')\\\"\",\"Hide Reward\":\"\\\"// Variables:\\\\n// questId - ID of the quest whose rewards are altered\\\\n// rewardId - ID of the reward being hidden\\\\n//\\\\n// console.log('Quest ' + questId + ' reward ' + rewardId + ' becomes hidden!')\\\"\",\"Claim Reward\":\"\\\"// Variables:\\\\n// questId - ID of the quest whose rewards are altered\\\\n// rewardId - ID of the reward becoming claimed\\\\n//\\\\n// console.log('Quest ' + questId + ' reward ' + rewardId + ' is now claimed!')\\\"\",\"Deny Reward\":\"\\\"// Variables:\\\\n// questId - ID of the quest whose rewards are altered\\\\n// rewardId - ID of the reward becoming denied\\\\n//\\\\n// console.log('Quest ' + questId + ' reward ' + rewardId + ' is now denied!')\\\"\",\"Normalize Reward\":\"\\\"// Variables:\\\\n// questId - ID of the quest whose rewards are altered\\\\n// rewardId - ID of the reward normalized\\\\n//\\\\n// console.log('Quest ' + questId + ' reward ' + rewardId + ' is normalized!')\\\"\",\"---Subtext---\":\"\",\"Change Subtext\":\"\\\"// Variables:\\\\n// questId - ID of the quest whose subtext is changed\\\\n// index - Subtext index being changed to\\\\n//\\\\n// console.log('Quest ' + questId + ' subtext index changed to ' + index)\\\"\"}","---Quest List---":"","Quest 1":"{\"Title\":\"\\\\i[87]研究长子\",\"Type\":\"主线任务\",\"Difficulty\":\"简单难度\",\"From\":\"\",\"Location\":\"晶核研究站\",\"Description\":\"[\\\"\\\\\\\"进入晶核研究站后向上走,穿过星港进入研究站\\\\\\\"\\\",\\\"\\\\\\\"从研究站向右进入实验室\\\\\\\"\\\",\\\"\\\\\\\"点击右边长子容器研究长子\\\\\\\"\\\"]\",\"Objectives List\":\"[\\\"\\\\\\\"进入晶核研究站\\\\\\\"\\\",\\\"\\\\\\\"进入实验室\\\\\\\"\\\",\\\"\\\\\\\"研究长子\\\\\\\"\\\"]\",\"Visible Objectives\":\"[\\\"1\\\"]\",\"Rewards List\":\"[\\\"\\\\\\\"\\\\\\\\\\\\\\\\i[176]Potion x5\\\\\\\"\\\",\\\"\\\\\\\"\\\\\\\\\\\\\\\\i[178]Ether x3\\\\\\\"\\\",\\\"\\\\\\\"To make other rewards appear,\\\\\\\\nenable them through the \\\\\\\\\\\\\\\\c[4]'Visible\\\\\\\\nRewards'\\\\\\\\\\\\\\\\c[0] plugin parameter or by\\\\\\\\nusing a plugin command to make\\\\\\\\nthem appear\\\\\\\"\\\"]\",\"Visible Rewards\":\"[\\\"1\\\"]\",\"Subtext\":\"[\\\"\\\\\\\"\\\\\\\"\\\",\\\"\\\\\\\"This is a subtext. It is used as\\\\\\\\nextra text that you may want to\\\\\\\\nplace on your quest journal that\\\\\\\\ndiffers from the description.\\\\\\\"\\\"]\"}","Quest 2":"","Quest 3":"","Quest 4":"","Quest 5":"","Quest 6":"","Quest 7":"","Quest 8":"","Quest 9":"","Quest 10":"","Quest 11":"","Quest 12":"","Quest 13":"","Quest 14":"","Quest 15":"","Quest 16":"","Quest 17":"","Quest 18":"","Quest 19":"","Quest 20":"","Quest 21":"","Quest 22":"","Quest 23":"","Quest 24":"","Quest 25":"","Quest 26":"","Quest 27":"","Quest 28":"","Quest 29":"","Quest 30":"","Quest 31":"","Quest 32":"","Quest 33":"","Quest 34":"","Quest 35":"","Quest 36":"","Quest 37":"","Quest 38":"","Quest 39":"","Quest 40":"","Quest 41":"","Quest 42":"","Quest 43":"","Quest 44":"","Quest 45":"","Quest 46":"","Quest 47":"","Quest 48":"","Quest 49":"","Quest 50":"","Quest 51":"","Quest 52":"","Quest 53":"","Quest 54":"","Quest 55":"","Quest 56":"","Quest 57":"","Quest 58":"","Quest 59":"","Quest 60":"","Quest 61":"","Quest 62":"","Quest 63":"","Quest 64":"","Quest 65":"","Quest 66":"","Quest 67":"","Quest 68":"","Quest 69":"","Quest 70":"","Quest 71":"","Quest 72":"","Quest 73":"","Quest 74":"","Quest 75":"","Quest 76":"","Quest 77":"","Quest 78":"","Quest 79":"","Quest 80":"","Quest 81":"","Quest 82":"","Quest 83":"","Quest 84":"","Quest 85":"","Quest 86":"","Quest 87":"","Quest 88":"","Quest 89":"","Quest 90":"","Quest 91":"","Quest 92":"","Quest 93":"","Quest 94":"","Quest 95":"","Quest 96":"","Quest 97":"","Quest 98":"","Quest 99":"","Quest 100":""}},
{"name":"YEP_X_MapQuestWindow","status":true,"description":"YEP任务活动窗口-扩展","parameters":{"---Main---":"","Window Settings":"{\"---General---\":\"\",\"Word Wrap Objectives\":\"true\",\"Default Show\":\"true\",\"---Window Settings---\":\"\",\"X\":\"Graphics.boxWidth - width\",\"Y\":\"Graphics.boxHeight - height\",\"Scale\":\"0.50\",\"Width\":\"Graphics.boxWidth / 3\",\"Line Height\":\"36\",\"Font Face\":\"GameFont\",\"Font Size\":\"28\",\"Standard Padding\":\"18\",\"Text Padding\":\"6\",\"Standard Opacity\":\"255\",\"Back Opacity\":\"192\",\"Window Skin\":\"Window\"}","Set Active":"\\i[189]开启展示","Currently Active":"\\i[189]已展示","Clear Active":"\\i[186]取消展示","---Options---":"","Options Command":"任务窗口","Options Enable":"true","---Automatic Updates---":"","Quest Add":"true","Quest Complete":"true","Quest Failed":"true","Change Objectives":"true","Event Update":"true"}},
{"name":"YEP_X_MoreQuests1","status":true,"description":"YEP任务扩展-任务数扩充1000","parameters":{"---Quests 101 to 200---":"","Category: 101 to 200":"主线任务","Difficulty: 101 to 200":"简单难度","From: 101 to 200":"系统","Location: 101 to 200":"系统","Quest 101":"","Quest 102":"","Quest 103":"","Quest 104":"","Quest 105":"","Quest 106":"","Quest 107":"","Quest 108":"","Quest 109":"","Quest 110":"","Quest 111":"","Quest 112":"","Quest 113":"","Quest 114":"","Quest 115":"","Quest 116":"","Quest 117":"","Quest 118":"","Quest 119":"","Quest 120":"","Quest 121":"","Quest 122":"","Quest 123":"","Quest 124":"","Quest 125":"","Quest 126":"","Quest 127":"","Quest 128":"","Quest 129":"","Quest 130":"","Quest 131":"","Quest 132":"","Quest 133":"","Quest 134":"","Quest 135":"","Quest 136":"","Quest 137":"","Quest 138":"","Quest 139":"","Quest 140":"","Quest 141":"","Quest 142":"","Quest 143":"","Quest 144":"","Quest 145":"","Quest 146":"","Quest 147":"","Quest 148":"","Quest 149":"","Quest 150":"","Quest 151":"","Quest 152":"","Quest 153":"","Quest 154":"","Quest 155":"","Quest 156":"","Quest 157":"","Quest 158":"","Quest 159":"","Quest 160":"","Quest 161":"","Quest 162":"","Quest 163":"","Quest 164":"","Quest 165":"","Quest 166":"","Quest 167":"","Quest 168":"","Quest 169":"","Quest 170":"","Quest 171":"","Quest 172":"","Quest 173":"","Quest 174":"","Quest 175":"","Quest 176":"","Quest 177":"","Quest 178":"","Quest 179":"","Quest 180":"","Quest 181":"","Quest 182":"","Quest 183":"","Quest 184":"","Quest 185":"","Quest 186":"","Quest 187":"","Quest 188":"","Quest 189":"","Quest 190":"","Quest 191":"","Quest 192":"","Quest 193":"","Quest 194":"","Quest 195":"","Quest 196":"","Quest 197":"","Quest 198":"","Quest 199":"","Quest 200":"","---Quests 201 to 300---":"","Category: 201 to 300":"支线任务","Difficulty: 201 to 300":"Kinda Easy","From: 201 to 300":"Ulrika","Location: 201 to 300":"RPG Maker World","Quest 201":"","Quest 202":"","Quest 203":"","Quest 204":"","Quest 205":"","Quest 206":"","Quest 207":"","Quest 208":"","Quest 209":"","Quest 210":"","Quest 211":"","Quest 212":"","Quest 213":"","Quest 214":"","Quest 215":"","Quest 216":"","Quest 217":"","Quest 218":"","Quest 219":"","Quest 220":"","Quest 221":"","Quest 222":"","Quest 223":"","Quest 224":"","Quest 225":"","Quest 226":"","Quest 227":"","Quest 228":"","Quest 229":"","Quest 230":"","Quest 231":"","Quest 232":"","Quest 233":"","Quest 234":"","Quest 235":"","Quest 236":"","Quest 237":"","Quest 238":"","Quest 239":"","Quest 240":"","Quest 241":"","Quest 242":"","Quest 243":"","Quest 244":"","Quest 245":"","Quest 246":"","Quest 247":"","Quest 248":"","Quest 249":"","Quest 250":"","Quest 251":"","Quest 252":"","Quest 253":"","Quest 254":"","Quest 255":"","Quest 256":"","Quest 257":"","Quest 258":"","Quest 259":"","Quest 260":"","Quest 261":"","Quest 262":"","Quest 263":"","Quest 264":"","Quest 265":"","Quest 266":"","Quest 267":"","Quest 268":"","Quest 269":"","Quest 270":"","Quest 271":"","Quest 272":"","Quest 273":"","Quest 274":"","Quest 275":"","Quest 276":"","Quest 277":"","Quest 278":"","Quest 279":"","Quest 280":"","Quest 281":"","Quest 282":"","Quest 283":"","Quest 284":"","Quest 285":"","Quest 286":"","Quest 287":"","Quest 288":"","Quest 289":"","Quest 290":"","Quest 291":"","Quest 292":"","Quest 293":"","Quest 294":"","Quest 295":"","Quest 296":"","Quest 297":"","Quest 298":"","Quest 299":"","Quest 300":"","---Quests 301 to 400---":"","Category: 301 to 400":"特殊任务","Difficulty: 301 to 400":"Easy to Normal","From: 301 to 400":"Bennett","Location: 301 to 400":"RPG Maker Kart","Quest 301":"","Quest 302":"","Quest 303":"","Quest 304":"","Quest 305":"","Quest 306":"","Quest 307":"","Quest 308":"","Quest 309":"","Quest 310":"","Quest 311":"","Quest 312":"","Quest 313":"","Quest 314":"","Quest 315":"","Quest 316":"","Quest 317":"","Quest 318":"","Quest 319":"","Quest 320":"","Quest 321":"","Quest 322":"","Quest 323":"","Quest 324":"","Quest 325":"","Quest 326":"","Quest 327":"","Quest 328":"","Quest 329":"","Quest 330":"","Quest 331":"","Quest 332":"","Quest 333":"","Quest 334":"","Quest 335":"","Quest 336":"","Quest 337":"","Quest 338":"","Quest 339":"","Quest 340":"","Quest 341":"","Quest 342":"","Quest 343":"","Quest 344":"","Quest 345":"","Quest 346":"","Quest 347":"","Quest 348":"","Quest 349":"","Quest 350":"","Quest 351":"","Quest 352":"","Quest 353":"","Quest 354":"","Quest 355":"","Quest 356":"","Quest 357":"","Quest 358":"","Quest 359":"","Quest 360":"","Quest 361":"","Quest 362":"","Quest 363":"","Quest 364":"","Quest 365":"","Quest 366":"","Quest 367":"","Quest 368":"","Quest 369":"","Quest 370":"","Quest 371":"","Quest 372":"","Quest 373":"","Quest 374":"","Quest 375":"","Quest 376":"","Quest 377":"","Quest 378":"","Quest 379":"","Quest 380":"","Quest 381":"","Quest 382":"","Quest 383":"","Quest 384":"","Quest 385":"","Quest 386":"","Quest 387":"","Quest 388":"","Quest 389":"","Quest 390":"","Quest 391":"","Quest 392":"","Quest 393":"","Quest 394":"","Quest 395":"","Quest 396":"","Quest 397":"","Quest 398":"","Quest 399":"","Quest 400":"","---Quests 401 to 500---":"","Category: 401 to 500":"教程任务","Difficulty: 401 to 500":"Interesting","From: 401 to 500":"Lawrence","Location: 401 to 500":"RPG Maker Sunshine","Quest 401":"","Quest 402":"","Quest 403":"","Quest 404":"","Quest 405":"","Quest 406":"","Quest 407":"","Quest 408":"","Quest 409":"","Quest 410":"","Quest 411":"","Quest 412":"","Quest 413":"","Quest 414":"","Quest 415":"","Quest 416":"","Quest 417":"","Quest 418":"","Quest 419":"","Quest 420":"","Quest 421":"","Quest 422":"","Quest 423":"","Quest 424":"","Quest 425":"","Quest 426":"","Quest 427":"","Quest 428":"","Quest 429":"","Quest 430":"","Quest 431":"","Quest 432":"","Quest 433":"","Quest 434":"","Quest 435":"","Quest 436":"","Quest 437":"","Quest 438":"","Quest 439":"","Quest 440":"","Quest 441":"","Quest 442":"","Quest 443":"","Quest 444":"","Quest 445":"","Quest 446":"","Quest 447":"","Quest 448":"","Quest 449":"","Quest 450":"","Quest 451":"","Quest 452":"","Quest 453":"","Quest 454":"","Quest 455":"","Quest 456":"","Quest 457":"","Quest 458":"","Quest 459":"","Quest 460":"","Quest 461":"","Quest 462":"","Quest 463":"","Quest 464":"","Quest 465":"","Quest 466":"","Quest 467":"","Quest 468":"","Quest 469":"","Quest 470":"","Quest 471":"","Quest 472":"","Quest 473":"","Quest 474":"","Quest 475":"","Quest 476":"","Quest 477":"","Quest 478":"","Quest 479":"","Quest 480":"","Quest 481":"","Quest 482":"","Quest 483":"","Quest 484":"","Quest 485":"","Quest 486":"","Quest 487":"","Quest 488":"","Quest 489":"","Quest 490":"","Quest 491":"","Quest 492":"","Quest 493":"","Quest 494":"","Quest 495":"","Quest 496":"","Quest 497":"","Quest 498":"","Quest 499":"","Quest 500":"","---Quests 501 to 600---":"","Category: 501 to 600":"Villain Quests","Difficulty: 501 to 600":"Normalish","From: 501 to 600":"Oscar","Location: 501 to 600":"RPG Maker Party","Quest 501":"","Quest 502":"","Quest 503":"","Quest 504":"","Quest 505":"","Quest 506":"","Quest 507":"","Quest 508":"","Quest 509":"","Quest 510":"","Quest 511":"","Quest 512":"","Quest 513":"","Quest 514":"","Quest 515":"","Quest 516":"","Quest 517":"","Quest 518":"","Quest 519":"","Quest 520":"","Quest 521":"","Quest 522":"","Quest 523":"","Quest 524":"","Quest 525":"","Quest 526":"","Quest 527":"","Quest 528":"","Quest 529":"","Quest 530":"","Quest 531":"","Quest 532":"","Quest 533":"","Quest 534":"","Quest 535":"","Quest 536":"","Quest 537":"","Quest 538":"","Quest 539":"","Quest 540":"","Quest 541":"","Quest 542":"","Quest 543":"","Quest 544":"","Quest 545":"","Quest 546":"","Quest 547":"","Quest 548":"","Quest 549":"","Quest 550":"","Quest 551":"","Quest 552":"","Quest 553":"","Quest 554":"","Quest 555":"","Quest 556":"","Quest 557":"","Quest 558":"","Quest 559":"","Quest 560":"","Quest 561":"","Quest 562":"","Quest 563":"","Quest 564":"","Quest 565":"","Quest 566":"","Quest 567":"","Quest 568":"","Quest 569":"","Quest 570":"","Quest 571":"","Quest 572":"","Quest 573":"","Quest 574":"","Quest 575":"","Quest 576":"","Quest 577":"","Quest 578":"","Quest 579":"","Quest 580":"","Quest 581":"","Quest 582":"","Quest 583":"","Quest 584":"","Quest 585":"","Quest 586":"","Quest 587":"","Quest 588":"","Quest 589":"","Quest 590":"","Quest 591":"","Quest 592":"","Quest 593":"","Quest 594":"","Quest 595":"","Quest 596":"","Quest 597":"","Quest 598":"","Quest 599":"","Quest 600":"","---Quests 601 to 700---":"","Category: 601 to 700":"Training Quests","Difficulty: 601 to 700":"Normal to Hard","From: 601 to 700":"Vera","Location: 601 to 700":"Paper RPG Maker","Quest 601":"","Quest 602":"","Quest 603":"","Quest 604":"","Quest 605":"","Quest 606":"","Quest 607":"","Quest 608":"","Quest 609":"","Quest 610":"","Quest 611":"","Quest 612":"","Quest 613":"","Quest 614":"","Quest 615":"","Quest 616":"","Quest 617":"","Quest 618":"","Quest 619":"","Quest 620":"","Quest 621":"","Quest 622":"","Quest 623":"","Quest 624":"","Quest 625":"","Quest 626":"","Quest 627":"","Quest 628":"","Quest 629":"","Quest 630":"","Quest 631":"","Quest 632":"","Quest 633":"","Quest 634":"","Quest 635":"","Quest 636":"","Quest 637":"","Quest 638":"","Quest 639":"","Quest 640":"","Quest 641":"","Quest 642":"","Quest 643":"","Quest 644":"","Quest 645":"","Quest 646":"","Quest 647":"","Quest 648":"","Quest 649":"","Quest 650":"","Quest 651":"","Quest 652":"","Quest 653":"","Quest 654":"","Quest 655":"","Quest 656":"","Quest 657":"","Quest 658":"","Quest 659":"","Quest 660":"","Quest 661":"","Quest 662":"","Quest 663":"","Quest 664":"","Quest 665":"","Quest 666":"","Quest 667":"","Quest 668":"","Quest 669":"","Quest 670":"","Quest 671":"","Quest 672":"","Quest 673":"","Quest 674":"","Quest 675":"","Quest 676":"","Quest 677":"","Quest 678":"","Quest 679":"","Quest 680":"","Quest 681":"","Quest 682":"","Quest 683":"","Quest 684":"","Quest 685":"","Quest 686":"","Quest 687":"","Quest 688":"","Quest 689":"","Quest 690":"","Quest 691":"","Quest 692":"","Quest 693":"","Quest 694":"","Quest 695":"","Quest 696":"","Quest 697":"","Quest 698":"","Quest 699":"","Quest 700":"","---Quests 701 to 800---":"","Category: 701 to 800":"Mastery Quests","Difficulty: 701 to 800":"Hard","From: 701 to 800":"Elmer","Location: 701 to 800":"RPG Maker Power Tennis","Quest 701":"","Quest 702":"","Quest 703":"","Quest 704":"","Quest 705":"","Quest 706":"","Quest 707":"","Quest 708":"","Quest 709":"","Quest 710":"","Quest 711":"","Quest 712":"","Quest 713":"","Quest 714":"","Quest 715":"","Quest 716":"","Quest 717":"","Quest 718":"","Quest 719":"","Quest 720":"","Quest 721":"","Quest 722":"","Quest 723":"","Quest 724":"","Quest 725":"","Quest 726":"","Quest 727":"","Quest 728":"","Quest 729":"","Quest 730":"","Quest 731":"","Quest 732":"","Quest 733":"","Quest 734":"","Quest 735":"","Quest 736":"","Quest 737":"","Quest 738":"","Quest 739":"","Quest 740":"","Quest 741":"","Quest 742":"","Quest 743":"","Quest 744":"","Quest 745":"","Quest 746":"","Quest 747":"","Quest 748":"","Quest 749":"","Quest 750":"","Quest 751":"","Quest 752":"","Quest 753":"","Quest 754":"","Quest 755":"","Quest 756":"","Quest 757":"","Quest 758":"","Quest 759":"","Quest 760":"","Quest 761":"","Quest 762":"","Quest 763":"","Quest 764":"","Quest 765":"","Quest 766":"","Quest 767":"","Quest 768":"","Quest 769":"","Quest 770":"","Quest 771":"","Quest 772":"","Quest 773":"","Quest 774":"","Quest 775":"","Quest 776":"","Quest 777":"","Quest 778":"","Quest 779":"","Quest 780":"","Quest 781":"","Quest 782":"","Quest 783":"","Quest 784":"","Quest 785":"","Quest 786":"","Quest 787":"","Quest 788":"","Quest 789":"","Quest 790":"","Quest 791":"","Quest 792":"","Quest 793":"","Quest 794":"","Quest 795":"","Quest 796":"","Quest 797":"","Quest 798":"","Quest 799":"","Quest 800":"","---Quests 801 to 900---":"","Category: 801 to 900":"Extra Quests","Difficulty: 801 to 900":"Very Hard","From: 801 to 900":"Ruby","Location: 801 to 900":"RPG Maker Strikers","Quest 801":"","Quest 802":"","Quest 803":"","Quest 804":"","Quest 805":"","Quest 806":"","Quest 807":"","Quest 808":"","Quest 809":"","Quest 810":"","Quest 811":"","Quest 812":"","Quest 813":"","Quest 814":"","Quest 815":"","Quest 816":"","Quest 817":"","Quest 818":"","Quest 819":"","Quest 820":"","Quest 821":"","Quest 822":"","Quest 823":"","Quest 824":"","Quest 825":"","Quest 826":"","Quest 827":"","Quest 828":"","Quest 829":"","Quest 830":"","Quest 831":"","Quest 832":"","Quest 833":"","Quest 834":"","Quest 835":"","Quest 836":"","Quest 837":"","Quest 838":"","Quest 839":"","Quest 840":"","Quest 841":"","Quest 842":"","Quest 843":"","Quest 844":"","Quest 845":"","Quest 846":"","Quest 847":"","Quest 848":"","Quest 849":"","Quest 850":"","Quest 851":"","Quest 852":"","Quest 853":"","Quest 854":"","Quest 855":"","Quest 856":"","Quest 857":"","Quest 858":"","Quest 859":"","Quest 860":"","Quest 861":"","Quest 862":"","Quest 863":"","Quest 864":"","Quest 865":"","Quest 866":"","Quest 867":"","Quest 868":"","Quest 869":"","Quest 870":"","Quest 871":"","Quest 872":"","Quest 873":"","Quest 874":"","Quest 875":"","Quest 876":"","Quest 877":"","Quest 878":"","Quest 879":"","Quest 880":"","Quest 881":"","Quest 882":"","Quest 883":"","Quest 884":"","Quest 885":"","Quest 886":"","Quest 887":"","Quest 888":"","Quest 889":"","Quest 890":"","Quest 891":"","Quest 892":"","Quest 893":"","Quest 894":"","Quest 895":"","Quest 896":"","Quest 897":"","Quest 898":"","Quest 899":"","Quest 900":"","---Quests 901 to 1000---":"","Category: 901 to 1000":"Post-Game Quests","Difficulty: 901 to 1000":"Super Hard","From: 901 to 1000":"Love","Location: 901 to 1000":"RPG Maker Galaxy","Quest 901":"","Quest 902":"","Quest 903":"","Quest 904":"","Quest 905":"","Quest 906":"","Quest 907":"","Quest 908":"","Quest 909":"","Quest 910":"","Quest 911":"","Quest 912":"","Quest 913":"","Quest 914":"","Quest 915":"","Quest 916":"","Quest 917":"","Quest 918":"","Quest 919":"","Quest 920":"","Quest 921":"","Quest 922":"","Quest 923":"","Quest 924":"","Quest 925":"","Quest 926":"","Quest 927":"","Quest 928":"","Quest 929":"","Quest 930":"","Quest 931":"","Quest 932":"","Quest 933":"","Quest 934":"","Quest 935":"","Quest 936":"","Quest 937":"","Quest 938":"","Quest 939":"","Quest 940":"","Quest 941":"","Quest 942":"","Quest 943":"","Quest 944":"","Quest 945":"","Quest 946":"","Quest 947":"","Quest 948":"","Quest 949":"","Quest 950":"","Quest 951":"","Quest 952":"","Quest 953":"","Quest 954":"","Quest 955":"","Quest 956":"","Quest 957":"","Quest 958":"","Quest 959":"","Quest 960":"","Quest 961":"","Quest 962":"","Quest 963":"","Quest 964":"","Quest 965":"","Quest 966":"","Quest 967":"","Quest 968":"","Quest 969":"","Quest 970":"","Quest 971":"","Quest 972":"","Quest 973":"","Quest 974":"","Quest 975":"","Quest 976":"","Quest 977":"","Quest 978":"","Quest 979":"","Quest 980":"","Quest 981":"","Quest 982":"","Quest 983":"","Quest 984":"","Quest 985":"","Quest 986":"","Quest 987":"","Quest 988":"","Quest 989":"","Quest 990":"","Quest 991":"","Quest 992":"","Quest 993":"","Quest 994":"","Quest 995":"","Quest 996":"","Quest 997":"","Quest 998":"","Quest 999":"","Quest 1000":""}},
-{"name":"LiuYue_SeniorChest","status":true,"description":"v1.04 LiuYue_SeniorChest 高级箱子","parameters":{"---设置---":"","OverlapMode":"Overlap","ShowMode":"YuanShen","IsFilterText":"false","CoinIcon":"313","CountNumWidth":"4444","CountCoinWidth":"22222","---Chest模式窗口---":"","CMaxCols":"2","IsCAllTake":"true","CAllTakeText":"全部取走","IsCClose":"true","CCloseText":"关闭宝箱","IsCAutoLine":"true","---YuanShen模式窗口---":"","YMaxCols":"2","YMaxList":"5","YWindowWidth":"400","YWindowOp":"125","YTakeRange":"1","YColor1":"rgba(0, 0, 0, 0.6)","YColor2":"rgba(0, 0, 0, 0)","YOffsetX":"20","YOffsetY":"-180","YFadeFrame":"10","YDistance":"2","YIsHorShow":"true","YIsAutoOpen":"true","YIsLimitWindow":"true","---道具设置---":"","CoinColor":"#ffff00","---音效---":"","TakeSound":"Cursor1","TakeVolume":"100","TakePitch":"100","TakePan":"0","NoItemSound":"Cancel1","NoItemVolume":"100","NoItemPitch":"100","NoItemPan":"0","ChangeItemSound":"Knock","ChangeItemVolume":"100","ChangeItemPitch":"100","ChangeItemPan":"0","AllTakeSound":"Equip2","AllTakeVolume":"100","AllTakePitch":"100","AllTakePan":"0","CloseSound":"Chest2","CloseVolume":"100","ClosePitch":"100","ClosePan":"0"}}
+{"name":"LiuYue_SeniorChest","status":true,"description":"v1.04 LiuYue_SeniorChest 高级箱子","parameters":{"---设置---":"","OverlapMode":"Overlap","ShowMode":"YuanShen","IsFilterText":"false","CoinIcon":"313","CountNumWidth":"4444","CountCoinWidth":"22222","---Chest模式窗口---":"","CMaxCols":"2","IsCAllTake":"true","CAllTakeText":"全部取走","IsCClose":"true","CCloseText":"关闭宝箱","IsCAutoLine":"true","---YuanShen模式窗口---":"","YMaxCols":"2","YMaxList":"5","YWindowWidth":"400","YWindowOp":"125","YTakeRange":"1","YColor1":"rgba(0, 0, 0, 0.6)","YColor2":"rgba(0, 0, 0, 0)","YOffsetX":"20","YOffsetY":"-180","YFadeFrame":"10","YDistance":"2","YIsHorShow":"true","YIsAutoOpen":"true","YIsLimitWindow":"true","---道具设置---":"","CoinColor":"#ffff00","---音效---":"","TakeSound":"Cursor1","TakeVolume":"100","TakePitch":"100","TakePan":"0","NoItemSound":"Cancel1","NoItemVolume":"100","NoItemPitch":"100","NoItemPan":"0","ChangeItemSound":"Knock","ChangeItemVolume":"100","ChangeItemPitch":"100","ChangeItemPan":"0","AllTakeSound":"Equip2","AllTakeVolume":"100","AllTakePitch":"100","AllTakePan":"0","CloseSound":"Chest2","CloseVolume":"100","ClosePitch":"100","ClosePan":"0"}},
+{"name":"VirtualButtons_OnlyForSelf","status":true,"description":"v3.0 Creates buttons on the screen for touch input","parameters":{"dPadSettings":"{\"rockerImage\":\"Directions\",\"pressedpointimage\":\"Points\",\"padImage\":\"4dir\",\"x\":\"40\",\"y\":\"Graphics.height-280\",\"soundEffect\":\"\",\"Use Dynamic roker\":\"true\",\"Dynamic rocker back img\":\"dynamic\",\"Rectangle X\":\"0\",\"Rectangle Y\":\"Graphics.height-450\"}","keyButtonSettings":"[\"{\\\"name\\\":\\\"ok\\\",\\\"inputMethod\\\":\\\"0\\\",\\\"inputTrigger\\\":\\\"ok\\\",\\\"image\\\":\\\"OK1\\\",\\\"hotImage\\\":\\\"OK2\\\",\\\"activeScenes\\\":\\\"[\\\\\\\"Scene_Title\\\\\\\",\\\\\\\"Scene_Map\\\\\\\"]\\\",\\\"x\\\":\\\"Graphics.width-180\\\",\\\"y\\\":\\\"Graphics.height-200\\\",\\\"soundEffect\\\":\\\"\\\",\\\"commonEvent\\\":\\\"0\\\",\\\"customCode\\\":\\\"\\\",\\\"vibratePattern\\\":\\\"0\\\"}\",\"{\\\"name\\\":\\\"menu\\\",\\\"inputMethod\\\":\\\"0\\\",\\\"inputTrigger\\\":\\\"escape\\\",\\\"image\\\":\\\"Menu1\\\",\\\"hotImage\\\":\\\"Menu2\\\",\\\"activeScenes\\\":\\\"[\\\\\\\"Scene_Title\\\\\\\",\\\\\\\"Scene_Map\\\\\\\"]\\\",\\\"x\\\":\\\"40\\\",\\\"y\\\":\\\"40\\\",\\\"soundEffect\\\":\\\"\\\",\\\"commonEvent\\\":\\\"0\\\",\\\"customCode\\\":\\\"\\\",\\\"vibratePattern\\\":\\\"0\\\"}\",\"{\\\"name\\\":\\\"debug\\\",\\\"inputMethod\\\":\\\"0\\\",\\\"inputTrigger\\\":\\\"\\\",\\\"image\\\":\\\"DEBUG1\\\",\\\"hotImage\\\":\\\"DEBUG2\\\",\\\"x\\\":\\\"Graphics.width/2-50\\\",\\\"y\\\":\\\"0\\\",\\\"soundEffect\\\":\\\"\\\",\\\"commonEvent\\\":\\\"0\\\",\\\"customCode\\\":\\\"\\\\\\\"window.DebugBaseButton=window.DebugBaseButton||{};\\\\\\\\nTouchInput.clear();\\\\\\\\nTouchInput.removeEventHandlers();\\\\\\\\nInput.clear();\\\\\\\\nInput.removeEventHandlers();\\\\\\\\nvar canvas=document.getElementById(\\\\\\\\\\\\\\\"UpperCanvas\\\\\\\\\\\\\\\");\\\\\\\\n DebugBaseButton.debugDiv=DebugBaseButton.debugDiv||document.createElement(\\\\\\\\\\\\\\\"div\\\\\\\\\\\\\\\");\\\\\\\\n DebugBaseButton.debugInput=DebugBaseButton.debugInput||document.createElement(\\\\\\\\\\\\\\\"textarea\\\\\\\\\\\\\\\");\\\\\\\\n DebugBaseButton.enterInput=DebugBaseButton.enterInput||document.createElement(\\\\\\\\\\\\\\\"input\\\\\\\\\\\\\\\");\\\\\\\\n DebugBaseButton.exitInput=DebugBaseButton.exitInput||document.createElement(\\\\\\\\\\\\\\\"input\\\\\\\\\\\\\\\");\\\\\\\\n DebugBaseButton.resultDiv=DebugBaseButton.resultDiv||document.createElement(\\\\\\\\\\\\\\\"div\\\\\\\\\\\\\\\");\\\\\\\\n if(!DebugBaseButton.OpenedOnce){\\\\\\\\n DebugBaseButton.OpenedOnce=true;\\\\\\\\n DebugBaseButton.RunJavaScript=function(src,result){\\\\\\\\n try{\\\\\\\\n result.innerHTML=\\\\\\\\\\\\\\\"\\\\\\\\\\\\\\\";\\\\\\\\n var code=src.value;\\\\\\\\n var r=eval(code);\\\\\\\\n result.innerHTML+='[eval result:]'+r+'
';\\\\\\\\n } catch (e){\\\\\\\\n result.innerHTML+=\\\\\\\\\\\\\\\"[catch Error!]
\\\\\\\\\\\\\\\"+\\\\\\\\n \\\\\\\\\\\\\\\"[Error Name:]\\\\\\\\\\\\\\\"+e.name+'
'+\\\\\\\\n \\\\\\\\\\\\\\\"[Error Meaasge:]\\\\\\\\\\\\\\\"+e.message+\\\\\\\\\\\\\\\"
\\\\\\\\\\\\\\\";\\\\\\\\n }\\\\\\\\n };\\\\\\\\n\\\\\\\\n DebugBaseButton.clacTextWidth=function(text,fontSize){\\\\\\\\n DebugBaseButton.clacCanvas=DebugBaseButton.clacCanvas||document.createElement(\\\\\\\\\\\\\\\"canvas\\\\\\\\\\\\\\\");\\\\\\\\n var context=DebugBaseButton.clacCanvas.getContext(\\\\\\\\\\\\\\\"2d\\\\\\\\\\\\\\\");\\\\\\\\n context.font=context.font.replace(/\\\\\\\\\\\\\\\\d+px/, fontSize+\\\\\\\\\\\\\\\"px\\\\\\\\\\\\\\\");\\\\\\\\n return context.measureText(text).width;\\\\\\\\n }\\\\\\\\n\\\\\\\\n var console_log=console.log;\\\\\\\\n console.log=function(message){\\\\\\\\n var fontSize=parseInt(DebugBaseButton.resultDiv.style.fontSize);\\\\\\\\n if (typeof message == 'object') {\\\\\\\\n DebugBaseButton.resultDiv.innerHTML += ('[Console log:]'+\\\\\\\\n MakeObjectInnerHtmlIndent(message,DebugBaseButton.clacTextWidth('[Console log:]',fontSize),fontSize));\\\\\\\\n } else {\\\\\\\\n DebugBaseButton.resultDiv.innerHTML += '[Console log:]'+message + '
';\\\\\\\\n }\\\\\\\\n console_log(message);\\\\\\\\n };\\\\\\\\n\\\\\\\\n MakeObjectInnerHtmlIndent=function(object,indent,fontSize){\\\\\\\\n var innerHTML=\\\\\\\\\\\\\\\"
\\\\\\\\\\\\\\\";\\\\\\\\n for(var i in object){\\\\\\\\n innerHTML+=\\\\\\\\\\\\\\\"\\\\\\\\\\\\\\\"+i+\\\\\\\\\\\\\\\" :\\\\\\\\\\\\\\\";\\\\\\\\n if(typeof object[i] =='object'){\\\\\\\\n innerHTML+=MakeObjectInnerHtmlIndent(object[i],DebugBaseButton.clacTextWidth(i,fontSize),fontSize);\\\\\\\\n } else {\\\\\\\\n innerHTML+=\\\\\\\\\\\\\\\"\\\\\\\\\\\\\\\"+object[i]+\\\\\\\\\\\\\\\"
\\\\\\\\\\\\\\\"\\\\\\\\n }\\\\\\\\n }\\\\\\\\n innerHTML+=\\\\\\\\\\\\\\\"
\\\\\\\\\\\\\\\";\\\\\\\\n return innerHTML;\\\\\\\\n }\\\\\\\\n\\\\\\\\n DebugBaseButton.ExitDebug=function(Debug){\\\\\\\\n this.removeChild(Debug);\\\\\\\\n TouchInput._setupEventHandlers();\\\\\\\\n Input._setupEventHandlers();\\\\\\\\n DebugBaseButton.enterInput.removeEventListener(\\\\\\\\\\\\\\\"click\\\\\\\\\\\\\\\",DebugBaseButton.enterInput_bind);\\\\\\\\n DebugBaseButton.exitInput.removeEventListener(\\\\\\\\\\\\\\\"click\\\\\\\\\\\\\\\",DebugBaseButton.exitInput_bind);\\\\\\\\n };\\\\\\\\n\\\\\\\\n DebugBaseButton.debugDiv.setAttribute(\\\\\\\\\\\\\\\"style\\\\\\\\\\\\\\\",\\\\\\\\\\\\\\\"position: absolute;margin: auto; top: 0px; left: 0px; right: 0px; bottom: 0px;z-index: 1000; height:\\\\\\\\\\\\\\\"+\\\\\\\\n canvas.offsetHeight+\\\\\\\\\\\\\\\"px; width:\\\\\\\\\\\\\\\"+canvas.offsetWidth+\\\\\\\\\\\\\\\"px; background-color: rgba(0, 0, 0, 0.3); color: #FFFFFF; user-select:text;\\\\\\\\\\\\\\\");\\\\\\\\n DebugBaseButton.debugDiv.setAttribute(\\\\\\\\\\\\\\\"id\\\\\\\\\\\\\\\",\\\\\\\\\\\\\\\"DebugDiv\\\\\\\\\\\\\\\");\\\\\\\\n document.body.appendChild(DebugBaseButton.debugDiv);\\\\\\\\n\\\\\\\\n //input.setAttribute(\\\\\\\\\\\\\\\"type\\\\\\\\\\\\\\\",\\\\\\\\\\\\\\\"text\\\\\\\\\\\\\\\");\\\\\\\\n DebugBaseButton.debugInput.setAttribute(\\\\\\\\\\\\\\\"style\\\\\\\\\\\\\\\",\\\\\\\\\\\\\\\"width:\\\\\\\\\\\\\\\"+(canvas.offsetWidth-150*Graphics._realScale)+\\\\\\\\\\\\\\\"px; background-color: rgba(0,0,0,0.3);\\\\\\\\\\\\\\\"+\\\\\\\\n \\\\\\\\\\\\\\\"height: \\\\\\\\\\\\\\\"+(150*Graphics._realScale)+\\\\\\\\\\\\\\\"px; font-size: 30px; color: rgba(255,255,255,1); resize: none;\\\\\\\\\\\\\\\");\\\\\\\\n DebugBaseButton.debugInput.setAttribute(\\\\\\\\\\\\\\\"cols\\\\\\\\\\\\\\\",canvas.offsetWidth-150*Graphics._realScale);\\\\\\\\n DebugBaseButton.debugInput.setAttribute(\\\\\\\\\\\\\\\"rows\\\\\\\\\\\\\\\",\\\\\\\\\\\\\\\"10\\\\\\\\\\\\\\\");\\\\\\\\n DebugBaseButton.debugDiv.appendChild(DebugBaseButton.debugInput);\\\\\\\\n\\\\\\\\n DebugBaseButton.enterInput.setAttribute(\\\\\\\\\\\\\\\"type\\\\\\\\\\\\\\\",\\\\\\\\\\\\\\\"button\\\\\\\\\\\\\\\");\\\\\\\\n DebugBaseButton.enterInput.setAttribute(\\\\\\\\\\\\\\\"value\\\\\\\\\\\\\\\",\\\\\\\\\\\\\\\"执行\\\\\\\\\\\\\\\");\\\\\\\\n DebugBaseButton.enterInput.setAttribute(\\\\\\\\\\\\\\\"style\\\\\\\\\\\\\\\",\\\\\\\\\\\\\\\"position: absolute; left:\\\\\\\\\\\\\\\"+DebugBaseButton.debugInput.offsetWidth+\\\\\\\\\\\\\\\"px;\\\\\\\\\\\\\\\"+\\\\\\\\n \\\\\\\\\\\\\\\"width: \\\\\\\\\\\\\\\"+(canvas.offsetWidth-DebugBaseButton.debugInput.offsetWidth)+\\\\\\\\\\\\\\\"px; height:\\\\\\\\\\\\\\\"+(DebugBaseButton.debugInput.offsetHeight/2)+\\\\\\\\\\\\\\\"px;\\\\\\\\\\\\\\\"+\\\\\\\\n \\\\\\\\\\\\\\\"background-color: rgba(0,0,0,0.3); font-size: \\\\\\\\\\\\\\\"+40*Graphics._realScale+\\\\\\\\\\\\\\\"px; color: rgba(255,255,255,0.7);\\\\\\\\\\\\\\\");\\\\\\\\n DebugBaseButton.enterInput_bind=DebugBaseButton.RunJavaScript.bind(DebugBaseButton.enterInput,DebugBaseButton.debugInput,DebugBaseButton.resultDiv)\\\\\\\\n DebugBaseButton.enterInput.addEventListener(\\\\\\\\\\\\\\\"click\\\\\\\\\\\\\\\",DebugBaseButton.enterInput_bind);\\\\\\\\n DebugBaseButton.debugDiv.appendChild(DebugBaseButton.enterInput);\\\\\\\\n\\\\\\\\n DebugBaseButton.exitInput.setAttribute(\\\\\\\\\\\\\\\"type\\\\\\\\\\\\\\\",\\\\\\\\\\\\\\\"button\\\\\\\\\\\\\\\");\\\\\\\\n DebugBaseButton.exitInput.setAttribute(\\\\\\\\\\\\\\\"value\\\\\\\\\\\\\\\",\\\\\\\\\\\\\\\"退出\\\\\\\\\\\\\\\");\\\\\\\\n DebugBaseButton.exitInput.setAttribute(\\\\\\\\\\\\\\\"style\\\\\\\\\\\\\\\",\\\\\\\\\\\\\\\"position: absolute; left:\\\\\\\\\\\\\\\"+DebugBaseButton.debugInput.offsetWidth+\\\\\\\\\\\\\\\"px;\\\\\\\\\\\\\\\"+\\\\\\\\n \\\\\\\\\\\\\\\"width: \\\\\\\\\\\\\\\"+(canvas.offsetWidth-DebugBaseButton.debugInput.offsetWidth)+\\\\\\\\\\\\\\\"px; top:\\\\\\\\\\\\\\\"+(DebugBaseButton.debugInput.offsetHeight/2)+\\\\\\\\\\\\\\\"px; height:\\\\\\\\\\\\\\\"+(DebugBaseButton.debugInput.offsetHeight/2)+\\\\\\\\\\\\\\\"px;\\\\\\\\\\\\\\\"+\\\\\\\\n \\\\\\\\\\\\\\\"background-color: rgba(0,0,0,0.3); font-size: \\\\\\\\\\\\\\\"+40*Graphics._realScale+\\\\\\\\\\\\\\\"px; color: rgba(255,255,255,0.7);\\\\\\\\\\\\\\\");\\\\\\\\n DebugBaseButton.exitInput_bind=DebugBaseButton.ExitDebug.bind(document.body,DebugBaseButton.debugDiv);\\\\\\\\n DebugBaseButton.exitInput.addEventListener(\\\\\\\\\\\\\\\"click\\\\\\\\\\\\\\\",DebugBaseButton.exitInput_bind);\\\\\\\\n DebugBaseButton.debugDiv.appendChild(DebugBaseButton.exitInput);\\\\\\\\n\\\\\\\\n DebugBaseButton.resultDiv.setAttribute(\\\\\\\\\\\\\\\"style\\\\\\\\\\\\\\\",\\\\\\\\\\\\\\\"position: absolute; width: \\\\\\\\\\\\\\\"+canvas.offsetWidth+\\\\\\\\\\\\\\\"px; height:\\\\\\\\\\\\\\\"+(canvas.offsetHeight-DebugBaseButton.debugInput.offsetHeight)+\\\\\\\\\\\\\\\"px;\\\\\\\\\\\\\\\"+\\\\\\\\n \\\\\\\\\\\\\\\"top:\\\\\\\\\\\\\\\"+DebugBaseButton.debugInput.offsetHeight+\\\\\\\\\\\\\\\"px; font-size: 20px; overflow: scroll\\\\\\\\\\\\\\\");\\\\\\\\n DebugBaseButton.resultDiv.innerHTML=\\\\\\\\\\\\\\\"输出结果在这,只在某种程度上支持console.log
\\\\\\\\\\\\\\\";\\\\\\\\n DebugBaseButton.debugDiv.appendChild(DebugBaseButton.resultDiv);\\\\\\\\n} else {\\\\\\\\n DebugBaseButton.enterInput_bind=DebugBaseButton.RunJavaScript.bind(DebugBaseButton.enterInput,DebugBaseButton.debugInput,DebugBaseButton.resultDiv)\\\\\\\\n DebugBaseButton.enterInput.addEventListener(\\\\\\\\\\\\\\\"click\\\\\\\\\\\\\\\",DebugBaseButton.enterInput_bind);\\\\\\\\n DebugBaseButton.exitInput_bind=DebugBaseButton.ExitDebug.bind(document.body,DebugBaseButton.debugDiv);\\\\\\\\n DebugBaseButton.exitInput.addEventListener(\\\\\\\\\\\\\\\"click\\\\\\\\\\\\\\\",DebugBaseButton.exitInput_bind);\\\\\\\\n DebugBaseButton.resultDiv.innerHTML=\\\\\\\\\\\\\\\"输出结果在这,只在某种程度上支持console.log
\\\\\\\\\\\\\\\";\\\\\\\\n document.body.appendChild(DebugBaseButton.debugDiv);\\\\\\\\n}\\\\\\\"\\\",\\\"vibratePattern\\\":\\\"0\\\"}\"]","controlButtonSettings":"{\"image\":\"Control\",\"activeScenes\":\"[\\\"Scene_Title\\\",\\\"Scene_Map\\\"]\",\"x\":\"10\",\"y\":\"260\",\"soundEffect\":\"\",\"buttonsToHide\":\"[]\",\"hideDPad\":\"true\",\"inputMethod\":\"0\"}","fadeDuration":"20","fadeDelay":"1","enableDiagonalInput":"false","hideButtonsDuringDialogue":"true","enableDPadDebugWindow":"false"}}
];
diff --git a/js/plugins/VirtualButtons_OnlyForSelf.js b/js/plugins/VirtualButtons_OnlyForSelf.js
new file mode 100644
index 0000000..29e3ad0
--- /dev/null
+++ b/js/plugins/VirtualButtons_OnlyForSelf.js
@@ -0,0 +1,1884 @@
+//Change for use d-pad
+
+/*:
+ * @plugindesc v3.0 Creates buttons on the screen for touch input
+ * @author Aloe Guvner
+ *
+ *
+ * @param dPadSettings
+ * @text D-Pad Settings
+ * @type struct
+ * @desc Settings for the D-Pad.
+ *
+ * @param keyButtonSettings
+ * @text Key Button Settings
+ * @type struct[]
+ * @desc Settings for on-screen buttons that simulate key presses.
+ *
+ * @param controlButtonSettings
+ * @text Control Button Settings
+ * @type struct
+ * @desc A "toggle" button that allows players to turn the UI
+ * on and off.
+ *
+ * @param fadeDuration
+ * @text Fade Duration
+ * @desc Duration of hiding the buttons (number of frames)
+ * for the buttons to fade and un-fade.
+ * @default 20
+ * @type number
+ *
+ * @param fadeDelay
+ * @text Fade Delay
+ * @desc Delay before hiding and unhiding buttons (number
+ * of frames)
+ * @default 1
+ * @type number
+ *
+ *
+ *
+ * @param enableDiagonalInput
+ * @text Enable Diagonal Input
+ * @type boolean
+ * @desc If the player touches in the corners of the D-Pad, both
+ * direction inputs are recorded. See info in help file.
+ * @default false
+ *
+ * @param hideButtonsDuringDialogue
+ * @text Hide Buttons During Dialogue
+ * @type boolean
+ * @desc Hide the virtual buttons during event dialogue.
+ * @default true
+ *
+ * @param enableDPadDebugWindow
+ * @text Enable DPad Debug Window
+ * @type boolean
+ * @desc Shows a window with the current D-Pad state. For
+ * plugin debugging only.
+ * @default false
+ *
+ * @help
+ *
+ * //=============================================================================
+ * // Background:
+ * //=============================================================================
+ * This plugin focuses on improving the user interface for mobile games created
+ * in RPG Maker MV. This plugin allows the developer to have virtual buttons
+ * on the screen that interact with touch input.
+ *
+ * This plugin allows maximum flexibility for the developer, you can add
+ * as many or as few buttons as you want to the screen, and you can add these buttons
+ * on whichever screens you would like (i.e. map, menu, credits, title, etc.).
+ *
+ * //=============================================================================
+ * // Functionality:
+ * //=============================================================================
+ *
+ * This plugin can create 3 different types of buttons:
+ * -Directional Pad
+ * --A single picture which is used for up, left, right, and down movement.
+ * --The picture is divided into 9 sections. The top 3 sections trigger the "up"
+ * input, the left 3 sections trigger the "left" input, the right 3 sections
+ * trigger the "right" input, and the bottom 3 section triggers the "down" input.
+ * --The middle section does not trigger any input.
+ * --The scenes that this button appears in can be defined.
+ * --This button is not mandatory.
+ *
+ * -Key buttons
+ * --These buttons can be used to represent any key. Common keys to use would be
+ * "ok" , "escape", "pagedown", "pageup".
+ * --However, these can be any key, and there can be as many or as few as the developer
+ * would like.
+ * --Additionally, the scenes that these buttons appear in can be controlled individually.
+ *
+ *
+ * -Control button
+ * --The control button, if pressed, will collapse and hide other buttons on the screen.
+ * --If pressed again, it will expand and show other buttons on the screen.
+ * --You can configure which other buttons are affected. This can allow you to create
+ * a dynamic menu where pressing this button opens other buttons for "Items", "Save",
+ * etc., while leaving the DPad or any other button active all of the time.
+ * --The scenes that this button appears in can be defined.
+ * --This button is not mandatory.
+ *
+ * //=============================================================================
+ * // Touch Input Methods:
+ * //=============================================================================
+ *
+ * The following methods can be chosen for any of the key buttons. The default
+ * method is "triggered".
+ *
+ * Triggered:
+ * This input method occurs when the button is just pressed down. It occurs only
+ * once, in the same frame that the button was pressed.
+ *
+ * Pressed:
+ * This input method occurs every frame while the button is pressed down. Any action
+ * that this button is doing will execute every frame (60 frames per second)
+ *
+ * Repeated:
+ * This input method occurs after 24 frames from when the button is pressed, and
+ * then occurs every 6 frames while the button is still pressed.
+ *
+ * Long Pressed:
+ * This input method occurs after 24 frames from when the button is pressed, and
+ * then occurs every frame while the button is still pressed.
+ *
+ * Released:
+ * This input method occurs when the button is no longer being pressed.
+ *
+ * //=============================================================================
+ * // Setup:
+ * //=============================================================================
+ * This plugin requires a new folder to be created within the project "img" folder.
+ * The folder must be titled "VirtualButtons".
+ * Place all UI button images into this folder, and they can be accessed from the
+ * plugin parameters.
+ *
+ * //=============================================================================
+ * // Vibrate Parameter
+ * //=============================================================================
+ * Buttons can trigger a vibrate on the mobile device when pressed, controlled by
+ * a parameter.
+ * This parameter follows a pattern of vibrate,pause,vibrate,pause, etc.
+ * Separate each time interval by a comma.
+ * Examples:
+ * 200 --> vibrate for 200ms
+ * 100,30,100,30,100,30 --> vibrate for 100ms, pause for 30ms; repeat 2 more times
+ *
+ * Note that most devices support the Vibration API, but not all.
+ * Additionally, this may not work in all methods of deployment.
+ *
+ *
+ *
+ * //=============================================================================
+ * Diagonal Movement Parameter
+ * //=============================================================================
+ *
+ * There is a parameter that controls whether diagonal input is recorded from the
+ * D-Pad. This is not a diagonal movement plugin! This parameter merely controls
+ * whether touching on the top left will add the input values of both "top" and
+ * "left" to the input state. Other diagonal movement plugins would consume these
+ * input values to move the character diagonally.
+ *
+ * If your game uses diagonal movement, this parameter must be on. If your game
+ * does not use diagonal movement, it is recommended to turn this parameter off.
+ *
+ * //=============================================================================
+ * Terms of Use:
+ * //=============================================================================
+ * Free for use in commercial or non-commercial projects.
+ * Credits required to: Aloe Guvner
+ *
+ * //=============================================================================
+ * Version History:
+ * //=============================================================================
+ * v2.0.1 (May 13 2019)
+ * --Fix bug where DPad got stuck in menus
+ * v2.0.0 (May 4 2019)
+ * --Clears input state on transfer to mitigate stuck DPad input bug
+ * --Improves clearing of input state each frame to mitigate bug
+ * --Fix bug where the DPad would not clear the direction after a parallel event
+ * checking for a input direction triggered a Show Choices event command
+ * --Add plugin parameter to toggle whether the buttons are hidden during dialogue
+ * --Plugin command to change button opacity
+ * --Plugin command option to hide all buttons
+ * --Plugin command option to show all buttons
+ * --Delay parameter to fade-in
+ * --Option to use a "hot" image that shows when the button is pressed
+ * --Key buttons can trigger common events
+ * --Buttons hidden via plugin command will stay hidden until the show plugin command
+ * v1.4.0 (December 13 2018)
+ * --Added ability to configure which buttons are affected by the "control" button
+ * Can be used to create dynamic menus.
+ * v1.3.1 (October 30 2018)
+ * --Added a parameter to control whether diagonal movement is detected as a
+ * possible fix for a hard to reproduce movement bug.
+ * v1.3.0 (September 27 2018)
+ * --Added a parameter to choose to disable the normal touch input on any chosen
+ * scene. The only touch input enabled on these scenes is the mobile UI.
+ * v1.2.3 (September 27 2018)
+ * --Fixed a bug where buttons that the player had chosen to hide would reappear
+ * after a game message.
+ * v1.2.2 (September 27 2018)
+ * --Fixed a bug where buttons could be pressed before they were fully visible
+ * v1.2.1 (September 27 2018)
+ * --Added an "instant" feature to hide/show for smoother cutscene transitions
+ * v1.2.0 (August 26 2018)
+ * --Added ability to vibrate when button is pressed
+ * v1.1.0 (June 27 2018)
+ * --Fixed bug with awkward player movement on the DPad
+ * --Added ability to specify the type of touch input on key buttons
+ * v1.0.3 (May 14 2018)
+ * --Added ability to run custom code when a key button is pressed
+ * v1.0.2 (May 9 2018)
+ * --Added ability to play a sound effect when a button is pressed
+ * --Fixed a bug where the parameters weren't read correctly due to plugin name change
+ * --Fixed a bug where the control button didn't hide the dpad properly
+ * v1.0.1 (May 8 2018)
+ * --Added a version compatible with MV earlier than 1.6.0 using Babel.js
+ * v1.0.0 (April 17 2018)
+ * --Initial release
+ *
+ * //=============================================================================
+ * End of Help File
+ * //=============================================================================
+ */
+
+/*~struct~dpad:
+ * @param rockerImage
+ * @text rockerImage
+ * @type file
+ * @dir img/VirtualButtons
+ * @desc File path for the D-Pad rocker image
+ * @require 1
+ *
+ * @param pressedpointimage
+ * @text pressedpointimage
+ * @type file
+ * @dir img/VirtualButtons
+ * @desc File path for the D-Pad rocker point image
+ * @require 1
+ *
+ * @param padImage
+ * @text padImage
+ * @type file
+ * @dir img/VirtualButtons
+ * @desc File path for the button image
+ * @require 1
+ * *
+ * @param x
+ * @text X
+ * @desc X position of the D-Pad. Formulas are allowed.
+ * (ex. Graphics.width - 96)
+ * @type text
+ * @default 0
+ *
+ * @param y
+ * @text Y
+ * @desc Y position of the D-Pad. Formulas are allowed.
+ * (ex. Graphics.height - 96)
+ * @type text
+ * @default 0
+ *
+ * @param soundEffect
+ * @text Sound Effect
+ * @type struct
+ * @desc Sound Effect to play when button is pressed.
+ * Depending on scenario, SE might already play. Test first.
+ *
+ * @param Use Dynamic roker
+ * @text Use Dynamic roker(need)
+ * @desc Use Dynamic roker need pressedPoint (must set true)
+ * @type boolean
+ * @default false
+ *
+ * @param Dynamic rocker back img
+ * @text Dynamic rocker back img
+ * @desc Dynamic rocker Rectangle limit (must set it)
+ * @type file
+ * @dir img/VirtualButtons
+ * @require 1
+ *
+ * @param Rectangle X
+ * @text Rectangle Left position
+ * @type text
+ * @default 0
+ * @desc Rectangle left position use for Dynamic rocker
+ *
+ * @param Rectangle Y
+ * @text Rectangle Top position
+ * @type text
+ * @default 0
+ * @desc Rectangle top position use for Dynamic rocker
+ *
+ *
+ */
+
+/*~struct~keyButton:
+ * @param name
+ * @text Name
+ * @type text
+ * @desc The name of the button
+ *
+ * @param inputMethod
+ * @text Input Method
+ * @type select
+ * @option Triggered
+ * @value 0
+ * @option Pressed
+ * @value 1
+ * @option Repeated
+ * @value 2
+ * @option Long Pressed
+ * @value 3
+ * @option Released
+ * @value 4
+ * @desc The type of touch input that will trigger the button.
+ * See the help file for full descriptions of the options.
+ * @default 0
+ *
+ * @param inputTrigger
+ * @text Input Code
+ * @type text
+ * @desc The input code triggered when the button is pressed.
+ * ex. ok / escape / pagedown / pageup
+ *
+ * @param image
+ * @text Image
+ * @type file
+ * @dir img/VirtualButtons
+ * @desc File path for the button image
+ * @require 1
+ *
+ * @param hotImage
+ * @text Hot Image
+ * @type file
+ * @dir img/VirtualButtons
+ * @desc File path for the "Hot" button image
+ * This image shows while the button is being pressed
+ * @require 1
+ *
+ *
+ * @param x
+ * @text X
+ * @type text
+ * @desc X position of the button. Formulas are allowed.
+ * (ex. Graphics.width - 96)
+ * @default 0
+ *
+ * @param y
+ * @text Y
+ * @type text
+ * @desc Y position of the button. Formulas are allowed.
+ * (ex. Graphics.height - 96)
+ * @default 0
+ *
+ * @param soundEffect
+ * @text Sound Effect
+ * @type struct
+ * @desc Sound Effect to play when button is pressed.
+ * Depending on scenario, SE might already play. Test first.
+ *
+ * @param commonEvent
+ * @text Common Event
+ * @type number
+ * @desc Common Event to trigger when the button is pressed.
+ * @default 0
+ * @min 0
+ *
+ * @param customCode
+ * @text Custom Code
+ * @type note
+ * @desc Custom Javascript code to run on button press.
+ * Use the 'this' keyword to refer to the current scene.
+ *
+ * @param vibratePattern
+ * @text Vibrate Pattern
+ * @type text
+ * @default 0
+ * @desc Pattern of miliseconds to vibrate on press.
+ * Use 0 for no vibration. See help for more info.
+ */
+
+/*~struct~controlButton:
+ * @param image
+ * @text Image
+ * @type file
+ * @dir img/VirtualButtons
+ * @desc File path for the button image
+ * @require 1
+ * *
+ * @param x
+ * @text X
+ * @type text
+ * @desc X position of the button. Formulas are allowed.
+ * (ex. Graphics.width - 96)
+ * @default 0
+ *
+ * @param y
+ * @text Y
+ * @type text
+ * @desc Y position of the button. Formulas are allowed.
+ * (ex. Graphics.height - 96)
+ * @default 0
+ *
+ * @param soundEffect
+ * @text Sound Effect
+ * @type struct
+ * @desc Sound Effect to play when button is pressed.
+ * Depending on scenario, SE might already play. Test first.
+ *
+ * @param buttonsToHide
+ * @text Buttons To Show / Hide
+ * @type text[]
+ * @desc A list of the Key Buttons to show and hide when
+ * this button is pressed. Leave empty to hide all.
+ * @default []
+ *
+ * @param hideDPad
+ * @text Show / Hide DPad?
+ * @type boolean
+ * @desc Controls whether the DPad is affected when
+ * this button is pressed.
+ * @default true
+ *
+ * @param inputMethod
+ * @text Input Method
+ * @type select
+ * @option Triggered
+ * @value 0
+ * @option Pressed
+ * @value 1
+ * @option Repeated
+ * @value 2
+ * @option Long Pressed
+ * @value 3
+ * @option Released
+ * @value 4
+ * @desc The type of touch input that will trigger the button.May can't use
+ * See the help file for full descriptions of the options.
+ * @default 0
+ *
+ */
+
+/*~struct~soundEffect:
+ * @param name
+ * @text Sound Effect Name
+ * @type file
+ * @dir audio/se
+ * @desc Sound effect to play when the button is pressed.
+ * @default
+ * @require 1
+ *
+ * @param volume
+ * @text Volume
+ * @type number
+ * @min 0
+ * @max 100
+ * @desc Volume of the sound effect, in %
+ * Allowed values: 0% - 100%
+ * @default 90
+ *
+ * @param pitch
+ * @text Pitch
+ * @type number
+ * @min 50
+ * @max 150
+ * @desc Pitch of the sound effect, in %
+ * Allowed values: 50% - 150%
+ * @default 100
+ *
+ * @param pan
+ * @text Pan
+ * @type number
+ * @min -100
+ * @max 100
+ * @desc Pan of the sound effect
+ * Allowed values: -100 - 100
+ * @default 0
+ *
+ */
+var Imported=Imported||{};
+Imported.VituralButtons_OnlyForSelf=true;
+var ALOE=ALOE||{};
+(function () {
+ "use strict";
+
+ var Alias = {};
+ var Parameters = {};
+ //=============================================================================
+ // Utils
+ //=============================================================================
+ // Create a utility function to parse complex parameters.
+ //=============================================================================
+
+ ALOE.recursiveParse = function (param) {
+ try {
+ return JSON.parse(param, function (key, value) {
+ try {
+ return this.recursiveParse(value);
+ } catch (e) {
+ return value;
+ }
+ }.bind(this));
+ } catch (e) {
+ return param;
+ }
+ }; //=============================================================================
+ // Parameters
+ //=============================================================================
+ // Read and parse parameters into a locally scoped Parameters object.
+ //=============================================================================
+
+
+ Object.keys(PluginManager.parameters("VirtualButtons_OnlyForSelf")).forEach(function (a) {
+ return (Parameters[a] = ALOE.recursiveParse(PluginManager.parameters("VirtualButtons_OnlyForSelf")[a]));
+ }); //=============================================================================
+ // ImageManager
+ //=============================================================================
+ // Load and reserve virtual button images.
+ //=============================================================================
+
+ ImageManager.loadVirtualButton = function (filename, hue) {
+ return this.loadBitmap('img/VirtualButtons/', filename, hue, true);
+ };
+
+ ImageManager.reserveVirtualButton = function (filename, hue, reservationId) {
+ return this.reserveBitmap('img/VirtualButtons/', filename, hue, true, reservationId);
+ }; //=============================================================================
+ // Sprite_VirtualButton
+ //=============================================================================
+ // Sprite for the UI button(s)
+ // Parent class for Sprite_DirectionalPad, Sprite_KeyButton, Sprite_ControlButton
+ //=============================================================================
+
+
+ function Sprite_VirtualButton() {
+ this.initialize.apply(this, arguments);
+ }
+
+ Sprite_VirtualButton.prototype = Object.create(Sprite_Base.prototype);
+ Sprite_VirtualButton.prototype.constructor = Sprite_VirtualButton;
+
+ Sprite_VirtualButton.prototype.initialize = function (x, y, normalImage, soundEffect, vibratePattern, hotImage) {
+ Sprite_Base.prototype.initialize.call(this);
+
+ if (normalImage) {
+ this.bitmap = ImageManager.loadVirtualButton(normalImage);
+ this.normalImage = this.bitmap;
+ }
+
+ if (hotImage) {
+ this.hotImage = ImageManager.loadVirtualButton(hotImage);
+ }
+
+ if (soundEffect) {
+ this._soundEffect = soundEffect;
+ }
+
+ if (vibratePattern) {
+ if (!window.navigator.vibrate) {
+ this._vibratePattern = 0;
+ } else if (typeof vibratePattern === 'number') {
+ this._vibratePattern = vibratePattern;
+ } else {
+ this._vibratePattern = vibratePattern.split(',').map(Number);
+ }
+ }
+
+ if (isNaN(x)) {
+ x = eval(x);
+ }
+
+ if (isNaN(y)) {
+ y = eval(y);
+ }
+
+ this.move(x, y);
+ this._start = new Point(null, null);
+ this._distance = new Point(null, null);
+ this._destination = new Point(null, null);
+ this._velocity = new Point(null, null);
+ this._origin = new Point(x, y);
+ this._hiding = false;
+ this._showing = false;
+ this._duration = Parameters.fadeDuration;
+ this._delay = Parameters.fadeDelay;
+ this._delayCounter = 0;
+ this.active = true;
+ this._pluginHidden = false;
+ this.z = 5;
+
+ this._point = null;
+ this._lastPoint = null;
+ this._TouchID=null;
+ };
+
+ Sprite_VirtualButton.prototype.update = function () {
+ Sprite_Base.prototype.update.call(this);
+
+ if(this.active) this.updatePressPoint();
+ else {
+ if(this._TouchID!=null){
+ delete Alias.TouchIdUsed[this._TouchID];
+ }
+ this._TouchID=null;
+ this._lastPoint=null;
+ this._point=null;
+ }
+
+ if (this.active && !this.moving) {
+ this.updateTouchInput();
+ }
+
+ if (this.active && this.updateHotImage) {
+ this.updateHotImage();
+ }
+
+ if (this.moving) {
+ this.updatePosition();
+ }
+
+ if (!this.active) {
+ this.updateActive();
+ }
+ };
+
+ Sprite_VirtualButton.prototype.updatePressPoint = function () {
+ this._lastPoint = this._point;
+ this._point = this.GetPressPoint();
+ if (this._point) {
+ if (!!this._lastPoint) {
+ this._trigger = false;
+ } else {
+ this._trigger = true;
+ }
+ this._pressed = true;
+ this._pressCount++;
+ } else {
+ this._pressed = false;
+ this._pressCount = 0;
+ if (!!this._lastPoint) {
+ this._released = true;
+ } else {
+ this._released = false;
+ }
+ }
+ };
+
+ Sprite_VirtualButton.prototype.updateTouchInput = function () {};
+
+ Sprite_VirtualButton.prototype.updateHotImage = function () {
+ if (this._pressed) {
+ var point = this._point;
+
+ if (this.containsPoint(point)) {
+ if (this.hotImage) {
+ this.bitmap = this.hotImage;
+ }
+ }
+ } else {
+ if (this.bitmap !== this.normalImage) {
+ this.bitmap = this.normalImage;
+ }
+ }
+ };
+
+ Sprite_VirtualButton.prototype.updateVisibility = function () {
+ if (this._hiding && this.opacity > 0) {
+ if (this._delayCounter < this._delay) {
+ this._delayCounter++;
+ } else {
+ this.opacity -= 255 / this._duration;
+ if (this.opacity <= 0) {
+ this._delayCounter = 0;
+ this._showing = false;
+ }
+ }
+ } else if (this._showing && this.opacity < 255) {
+ if (this._delayCounter < this._delay) {
+ this._delayCounter++;
+ } else {
+ this.opacity += 255 / this._duration;
+ if (this.opacity >= 255) this._delayCounter = 0;
+ }
+ }
+ };
+
+ Sprite_VirtualButton.prototype.updateActive = function () {
+ if (this.opacity === 255 && !this.moving && !this._pluginHidden &&!this._hiding) {
+ this.active = true;
+ }
+ };
+
+ Sprite_VirtualButton.prototype.updatePosition = function () {
+ this.x += this._velocity.x;
+ this.y += this._velocity.y;
+ var currentPos = new Point(this.x, this.y);
+ var currentDistance = this.absDistance(this._start, currentPos);
+
+ if (currentDistance >= this._distance.abs) {
+ this.x = this._destination.x;
+ this.y = this._destination.y;
+ this._velocity.x = 0;
+ this._velocity.y = 0;
+ this.moving = false;
+ }
+ };
+
+ Sprite_VirtualButton.prototype.hide = function () {
+ this._hiding = true;
+ this.active = false;
+ };
+
+ Sprite_VirtualButton.prototype.show = function () {
+ this._hiding = false;
+ this._showing = true;
+ };
+
+ Sprite_VirtualButton.prototype.hideInstant = function () {
+ this._hiding = true;
+ this.opacity = 0;
+ this.active = false;
+ this._delayCounter = this._delay;
+ };
+
+ Sprite_VirtualButton.prototype.showInstant = function () {
+ this._hiding = false;
+ this._showing = true;
+ this.opacity = 255;
+ this.active = true;
+ this._delayCounter = this._delay;
+ };
+
+ Sprite_VirtualButton.prototype.collapse = function (x, y) {
+ this._destination.x = x;
+ this._destination.y = y;
+ this._start.x = this.x;
+ this._start.y = this.y;
+ this._distance.x = this._destination.x - this._start.x;
+ this._distance.y = this._destination.y - this._start.y;
+ this._distance.abs = this.absDistance(this._destination, this._start);
+ this._velocity.x = this._distance.x / this._duration;
+ this._velocity.y = this._distance.y / this._duration;
+ this.moving = true;
+ };
+
+ Sprite_VirtualButton.prototype.expand = function () {
+ this._destination.x = this._origin.x;
+ this._destination.y = this._origin.y;
+ this._start.x = this.x;
+ this._start.y = this.y;
+ this._distance.x = this._destination.x - this._start.x;
+ this._distance.y = this._destination.y - this._start.y;
+ this._distance.abs = this.absDistance(this._destination, this._start);
+ this._velocity.x = this._distance.x / this._duration;
+ this._velocity.y = this._distance.y / this._duration;
+ this.moving = true;
+ };
+
+ Sprite_VirtualButton.prototype.absDistance = function (pos1, pos2) {
+ return Math.sqrt(Math.pow(pos1.x - pos2.x, 2) + Math.pow(pos1.y - pos2.y, 2));
+ };
+
+
+ Sprite_VirtualButton.prototype.GetPressPoint = function () {
+ var i;
+ var touches = TouchInput._event;
+ var touch = null;
+ var point = null;
+ var x=null;
+ var y=null;
+ if (window.TouchEvent && touches instanceof TouchEvent) {
+ if (this._TouchID!=null) {
+ touches = TouchInput._event.targetTouches;
+ for (i = 0; i < touches.length; i++) {
+ touch = touches.item(i);
+ if (this._TouchID != touch.identifier) {
+ continue;
+ }
+ x = Graphics.pageToCanvasX(touch.pageX);
+ y = Graphics.pageToCanvasY(touch.pageY);
+ return new Point(x, y);
+ }
+ }
+ if(SceneManager._scene._directionalPadDynamic&&
+ SceneManager._scene._directionalPadDynamic.active&&
+ (this==SceneManager._scene._directionalPad||
+ this==SceneManager._scene._directionalPadPoint)){
+ //Nothing to do
+ //console.log("skip");
+ } else {
+ touches = TouchInput._event.targetTouches;
+ for (i = 0; i < touches.length; i++) {
+ touch = touches.item(i);
+ if (!touch) continue;
+ x = Graphics.pageToCanvasX(touch.pageX);
+ y = Graphics.pageToCanvasY(touch.pageY);
+ point = new Point(x, y);
+ if (this.containsPoint(point)&&!Alias.TouchIdUsed[touch.identifier]) {
+ if((SceneManager._scene._controlButton&&
+ SceneManager._scene._controlButton.active&&
+ SceneManager._scene._controlButton.containsPoint(point)&&
+ SceneManager._scene._controlButton!=this)) {continue ;}
+ Alias.TouchIdUsed[touch.identifier]=this;
+ this._TouchID=touch.identifier;
+ return point;
+ }
+ }
+ }
+ } else if (touches instanceof MouseEvent && TouchInput.isPressed()) {
+ touch = touches;
+ x = Graphics.pageToCanvasX(touch.pageX);
+ y = Graphics.pageToCanvasY(touch.pageY);
+ point = new Point(x, y);
+ if(TouchInput.isPressed()&&Alias.MouseUsed==this){
+ return point;
+ } else if(SceneManager._scene._directionalPadDynamic&&
+ SceneManager._scene._directionalPadDynamic.active&&
+ (this==SceneManager._scene._directionalPad||
+ this==SceneManager._scene._directionalPadPoint)){
+ //Noting to do
+ }else if(!Alias.MouseUsed&&TouchInput.isPressed()&&this.containsPoint(point)){
+ if((SceneManager._scene._controlButton&&
+ SceneManager._scene._controlButton.active&&
+ (SceneManager._scene._controlButton==Alias.MouseUsed||
+ SceneManager._scene._controlButton.containsPoint(point))&&
+ SceneManager._scene._controlButton!=this)) {
+ //Nothing to do
+ } else {
+ Alias.MouseUsed=this;
+ return point;
+ }
+ }
+ return;
+ }
+ Alias.MouseUsed=null;
+ delete Alias.TouchIdUsed[this._TouchID];
+ this._TouchID=null;
+ return;
+ };
+
+
+ Sprite_VirtualButton.prototype.GetCenterPoint = function () {
+ return new Point(this.x + this.width / 2, this.y + this.height / 2);
+ };
+
+ Sprite_VirtualButton.prototype.isTouchTriggered = function () {
+ switch (this._inputMethod) {
+ case 0:
+ // Was just pressed
+ return this._trigger;
+
+ case 1:
+ //Currently pressed down
+ return this._pressed;
+
+ case 2:
+ //Is repeated
+ return this._pressed && (this._trigger ||
+ (this._pressCount >= TouchInput.keyRepeatWait &&
+ this._pressCount % TouchInput.keyRepeatInterval === 0));
+
+ case 3:
+ //Is kept pressed
+ return this._pressed && this._pressCount >= TouchInput.keyRepeatWait;
+
+ case 4:
+ //Was just released
+ return this._released;
+
+ default:
+ return this._trigger;
+ }
+ };
+
+ //=============================================================================
+ // Sprite_DirectionalPad
+ //=============================================================================
+ // Sprite for the Directional Pad
+ //=============================================================================
+
+
+ function Sprite_DirectionalPad() {
+ this.initialize.apply(this, arguments);
+ }
+
+ Sprite_DirectionalPad.prototype = Object.create(Sprite_VirtualButton.prototype);
+ Sprite_DirectionalPad.prototype.constructor = Sprite_DirectionalPad;
+
+ Sprite_DirectionalPad.prototype.initialize = function (x, y, image, hotImage, soundEffect) {
+ Sprite_VirtualButton.prototype.initialize.call(this, x, y, image, soundEffect, undefined, hotImage);
+ this._lastInput = "";
+ this._hiding = false;
+ };
+
+ Sprite_DirectionalPad.prototype.updateTouchInput = function () {
+ this.clearLastDirection();
+ var point = null;
+ if (Alias.globalShowStates.controlMethod=="fixed rocker"||
+ Alias.globalShowStates.controlMethod=="dynamic rocker") {
+ point = SceneManager._scene._directionalPadPoint._point;
+ } else if (Alias.globalShowStates.controlMethod=="fixed button"){ //否则
+ point = this._point;
+ }
+ if (point) {
+ if (this._soundEffect) {
+ AudioManager.playSe(this._soundEffect);
+ }
+ var index = this.whichIndex(point);
+ switch (index) {
+ case 0:
+ if (Parameters.enableDiagonalInput) {
+ Input._currentState.up = true;
+ Input._currentState.left = true;
+ this._lastInput = "up-left";
+ }
+ break;
+ case 1:
+ Input._currentState.up = true;
+ this._lastInput = "up";
+ break;
+ case 2:
+ if (Parameters.enableDiagonalInput) {
+ Input._currentState.right = true;
+ Input._currentState.up = true;
+ this._lastInput = "up-right";
+ }
+ break;
+ case 3:
+ Input._currentState.left = true;
+ this._lastInput = "left";
+ break;
+ case 4:
+ break;
+ case 5:
+ Input._currentState.right = true;
+ this._lastInput = "right";
+ break;
+ case 6:
+ if (Parameters.enableDiagonalInput) {
+ Input._currentState.left = true;
+ Input._currentState.down = true;
+ this._lastInput = "down-left";
+ }
+ break;
+ case 7:
+ Input._currentState.down = true;
+ this._lastInput = "down";
+ break;
+ case 8:
+ if (Parameters.enableDiagonalInput) {
+ Input._currentState.down = true;
+ Input._currentState.right = true;
+ this._lastInput = "down-right";
+ }
+ break;
+ default:
+ break;
+ }
+ }
+ };
+
+ Sprite_DirectionalPad.prototype.whichIndex = function (point) {
+ // 2 1 0
+ // 5 4 3
+ // 8 7 6
+ var index = 0;
+ if (Alias.globalShowStates.controlMethod=="fixed rocker"||
+ Alias.globalShowStates.controlMethod=="dynamic rocker") {
+ var centerX = this.x + this.width / 2;
+ var centerY = this.y + this.height / 2;
+ var range = this.absDistance(point, this.GetCenterPoint());
+ if (range < Math.max(this.width / 6, this.height / 6)) {
+ return 4;
+ }
+ if (centerX == point.x) {
+ return centerY == point.y ? 4 : (centerY > point.y ? 7 : 1);
+ }
+ var rad = Math.atan((point.y - centerY) / (point.x - centerX)) / Math.PI * 180;
+ rad = point.x < centerX ? rad : rad + 180;
+ rad = rad < 0 ? rad + 360 : rad;
+ if (rad < 22.5 || rad > 360 - 22.5) {
+ return 3;
+ } else if (rad > 22.5 && rad < 22.5 + 45) {
+ return 0;
+ } else if (rad > 22.5 + 45 && rad < 22.5 + 45 * 2) {
+ return 1;
+ } else if (rad > 22.5 + 45 * 2 && rad < 22.5 + 45 * 3) {
+ return 2;
+ } else if (rad > 22.5 + 45 * 3 && rad < 22.5 + 45 * 4) {
+ return 5;
+ } else if (rad > 22.5 + 45 * 4 && rad < 22.5 + 45 * 5) {
+ return 8;
+ } else if (rad > 22.5 + 45 * 5 && rad < 22.5 + 45 * 6) {
+ return 7;
+ } else if (rad > 22.5 + 45 * 6 && rad < 22.5 + 45 * 7) {
+ return 6;
+ } else {
+ return 4;
+ }
+ } else if (Alias.globalShowStates.controlMethod=="fixed button"){ //否则
+ index += point.x - this.x > this.width / 3 ? point.x - this.x > this.width * 2 / 3 ? 2 : 1 : 0;
+ index += point.y - this.y > this.height / 3 ? point.y - this.y > this.height * 2 / 3 ? 6 : 3 : 0;
+ }
+ return index;
+ };
+
+ Sprite_DirectionalPad.prototype.clearLastDirection = function () {
+ if (this._lastInput) {
+ this._lastInput.split("-").forEach(function (direction) {
+ return (Input._currentState[direction] = false);
+ });
+ this._lastInput = "";
+ }
+ };
+
+ //=============================================================================
+ // Sprite_DirectionalPadPoint
+ //=============================================================================
+ // Sprite for the Directional Pad Press Point
+ //=============================================================================
+ function Sprite_DirectionalPadPoint() {
+ this.initialize.apply(this, arguments);
+ }
+
+ Sprite_DirectionalPadPoint.prototype = Object.create(Sprite_VirtualButton.prototype);
+ Sprite_DirectionalPadPoint.prototype.constructor = Sprite_DirectionalPad;
+
+ Sprite_DirectionalPadPoint.prototype.initialize = function (image) {
+ Sprite_VirtualButton.prototype.initialize.call(this, 0, 0, image, undefined, undefined, undefined);
+ this.followLeft = 10;
+ var x = SceneManager._scene._directionalPad.x;
+ var y = SceneManager._scene._directionalPad.y;
+ var width = SceneManager._scene._directionalPad.width;
+ var height = SceneManager._scene._directionalPad.height;
+ this._origin = new Point(x + width / 2 - this.width / 2, y + height / 2 - this.height / 2);
+ this._TouchID = null;
+ };
+
+ Sprite_DirectionalPadPoint.prototype.updateTouchInput = function () {
+ var x = SceneManager._scene._directionalPad.x;
+ var y = SceneManager._scene._directionalPad.y;
+ var width = SceneManager._scene._directionalPad.width;
+ var height = SceneManager._scene._directionalPad.height;
+ var point = this._point;
+ if (point) {
+ this.x = point.x - this.width / 2;
+ this.y = point.y - this.height / 2;
+ } else {
+ this.x = x + width / 2 - this.width / 2;
+ this.y = y + height / 2 - this.height / 2;
+ }
+ };
+
+ Sprite_DirectionalPadPoint.prototype.updatePosition = function () {
+ var x = SceneManager._scene._directionalPad.x;
+ var y = SceneManager._scene._directionalPad.y;
+ var width = SceneManager._scene._directionalPad.width;
+ var height = SceneManager._scene._directionalPad.height;
+ var currentPos = new Point(x + width / 2 - this.width / 2, y + height / 2 - this.height / 2);
+ var currentDistance = this.absDistance(this._start, currentPos);
+ this.x = currentPos.x;
+ this.y = currentPos.y;
+
+ if (currentDistance >= this._distance.abs) {
+ this.x = this._destination.x;
+ this.y = this._destination.y;
+ this._velocity.x = 0;
+ this._velocity.y = 0;
+ this.moving = false;
+ }
+ };
+
+ //=============================================================================
+ // Sprite_DirectionalPadDynamic
+ //=============================================================================
+ // Sprite for the Directional Pad Dynamic
+ //=============================================================================
+ function Sprite_DirectionalPadDynamic() {
+ this.initialize.apply(this, arguments);
+ }
+
+ Sprite_DirectionalPadDynamic.prototype = Object.create(Sprite_VirtualButton.prototype);
+ Sprite_DirectionalPadDynamic.prototype.constructor = Sprite_DirectionalPad;
+
+ Sprite_DirectionalPadDynamic.prototype.initialize = function (x,y,image) {
+ Sprite_VirtualButton.prototype.initialize.call(this, x, y, image, undefined, undefined, undefined);
+ this._TouchID=null;
+ };
+
+ Sprite_DirectionalPadDynamic.prototype.updateTouchInput = function () {
+ var padPoint=SceneManager._scene._directionalPadPoint;
+ var pad = SceneManager._scene._directionalPad;
+ var button = SceneManager._scene._directionalPadButton;
+ if(Alias.globalShowStates.controlMethod=="dynamic rocker"){
+ if(this._TouchID!=null&&padPoint._TouchID==null){
+ padPoint._TouchID=this._TouchID;
+ Alias.TouchIdUsed[this._TouchID]=padPoint;
+ pad.x=this._point.x-pad.width/2;
+ pad.y=this._point.y-pad.height/2;
+ padPoint.update();
+ } else if(Alias.MouseUsed==this){
+ Alias.MouseUsed=padPoint;
+ pad.x=this._point.x-pad.width/2;
+ pad.y=this._point.y-pad.height/2;
+ padPoint.update();
+ }
+ } else if(Alias.globalShowStates.controlMethod=="fixed rocker"){
+ if(this._TouchID!=null&&padPoint._TouchID==null){
+ padPoint._TouchID=this._TouchID;
+ Alias.TouchIdUsed[this._TouchID]=padPoint;
+ pad.x=isNaN(Parameters.dPadSettings.x)?eval(Parameters.dPadSettings.x):Parameters.dPadSettings.x;
+ pad.y=isNaN(Parameters.dPadSettings.y)?eval(Parameters.dPadSettings.y):Parameters.dPadSettings.y;
+ this._TouchID=null;
+ padPoint.update();
+ } else if(Alias.MouseUsed==this){
+ Alias.MouseUsed=padPoint;
+ pad.x=isNaN(Parameters.dPadSettings.x)?eval(Parameters.dPadSettings.x):Parameters.dPadSettings.x;
+ pad.y=isNaN(Parameters.dPadSettings.y)?eval(Parameters.dPadSettings.y):Parameters.dPadSettings.y;
+ padPoint.update();
+ }
+ } else if(Alias.globalShowStates.controlMethod=="fixed button"){
+ if(this._TouchID!=null&&button._TouchID==null){
+ button._TouchID=this._TouchID;
+ Alias.TouchIdUsed[this._TouchID]=padPoint;
+ this._TouchID=null;
+ button.update();
+ } else if(Alias.MouseUsed==this){
+ Alias.MouseUsed=button;
+ button.update();
+ }
+ }else if(Alias.globalShowStates.controlMethod=="touch input"){
+ SceneManager._scene.setControlMethod("touch input");
+ }
+ };
+
+
+ //=============================================================================
+ // Sprite_KeyButton
+ //=============================================================================
+ // Sprite for the buttons that simulate a key input (besides arrow keys).
+ // Ex. "ok", "cancel", "pageup", "pagedown"
+ //=============================================================================
+
+
+ function Sprite_KeyButton() {
+ this.initialize.apply(this, arguments);
+ }
+
+ Sprite_KeyButton.prototype = Object.create(Sprite_VirtualButton.prototype);
+ Sprite_KeyButton.prototype.constructor = Sprite_KeyButton;
+
+ Sprite_KeyButton.prototype.initialize = function (x, y, image, hotImage, soundEffect, inputTrigger, customCode, vibratePattern) {
+ var inputMethod = arguments.length > 8 && arguments[8] !== undefined ? arguments[8] : 0;
+ var commonEvent = arguments.length > 9 && arguments[9] !== undefined ? arguments[9] : 0;
+ Sprite_VirtualButton.prototype.initialize.call(this, x, y, image, soundEffect, vibratePattern, hotImage);
+
+ if (inputTrigger) {
+ this._inputTrigger = inputTrigger;
+ }
+
+ if (customCode) {
+ this._customCode = customCode;
+ this._customFunction = new Function(customCode).bind(SceneManager._scene);
+ }
+
+ this._commonEvent = commonEvent;
+ this._inputMethod = inputMethod;
+ this._point = null;
+ };
+
+
+ Sprite_KeyButton.prototype.updateTouchInput = function () {
+
+ if (this.isTouchTriggered()) {
+ var point = this._point;
+
+ if (!!point && this.containsPoint(point)) {
+ if (this._soundEffect) {
+ AudioManager.playSe(this._soundEffect);
+ }
+
+ if (this._vibratePattern) {
+ window.navigator.vibrate(this._vibratePattern);
+ }
+
+ if (this._customFunction) {
+ this._customFunction();
+ }
+
+ if (this._commonEvent && $gameTemp) {
+ $gameTemp.reserveCommonEvent(this._commonEvent);
+ }
+
+ if (this._inputTrigger) {
+ Input._currentState[this._inputTrigger] = true;
+ }
+ } else {
+ Input._currentState[this._inputTrigger] = false;
+ }
+ } else {
+ Input._currentState[this._inputTrigger] = false;
+ }
+ }; //=============================================================================
+ // Sprite_ControlButton
+ //=============================================================================
+ // Sprite for the button that activates / deactivates all other buttons.
+ //=============================================================================
+
+
+ function Sprite_ControlButton() {
+ this.initialize.apply(this, arguments);
+ }
+
+ Sprite_ControlButton.prototype = Object.create(Sprite_VirtualButton.prototype);
+ Sprite_ControlButton.prototype.constructor = Sprite_ControlButton;
+
+ Sprite_ControlButton.prototype.initialize = function (x, y, image, soundEffect) {
+ Sprite_VirtualButton.prototype.initialize.call(this, x, y, image, soundEffect);
+ this._buttonsHidden = !(Alias.globalShowStates.dPadSettings &&
+ Alias.globalShowStates.controlButtonSettings &&
+ Object.keys(Alias.globalShowStates.keyButtonSettings).some(function (a) {
+ return Alias.globalShowStates.keyButtonSettings[a];
+ }));
+ this.inputMethod = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : 0;
+ this._moveDistance = 0;
+ };
+
+ Sprite_ControlButton.prototype.updateTouchInput = function () {
+ var point = this._point;
+ var moveDistance = 0;
+ if (!!point) {
+ this._lastx = this.x;
+ this._lasty = this.y;
+ this.x = (point.x - this.width / 2) < 0 ? 0 : (((point.x - this.width / 2) > Graphics.width - this.width) ? Graphics.width - this.width : point.x - this.width / 2);
+ this.y = (point.y - this.height / 2) < 0 ? 0 : (((point.y - this.height / 2) > Graphics.height - this.height) ? Graphics.height - this.height : point.y - this.height / 2);
+ }
+ if (this._trigger) {
+ this._dstx = this.x;
+ this._dsty = this.y;
+ }
+ if (this._released) {
+ moveDistance = this.absDistance(new Point(this._dstx, this._dsty), new Point(this.x, this.y));
+ Alias.globalShowStates.controlButtonX = this.x;
+ Alias.globalShowStates.controlButtonY = this.y;
+ if (moveDistance > 40) {
+ return;
+ }
+ }
+ if (this._released) {
+ if (this._soundEffect) {
+ AudioManager.playSe(this._soundEffect);
+ }
+ SceneManager._scene.hideVirtualButtonsInstant.call(SceneManager._scene);
+ this.changeControlMethod();
+ }
+
+ };
+
+ Sprite_ControlButton.prototype.changeControlMethod = function(){
+ var method=['fixed button','fixed rocker','dynamic rocker','touch input'];
+ var index=method.indexOf(Alias.globalShowStates.controlMethod);
+ if(index==-1) index=3;
+ index=(index+1)%method.length;
+ SceneManager._scene.setControlMethod.call(SceneManager._scene,method[index]);
+ };
+
+ //=============================================================================
+ // Scene_Base
+ //=============================================================================
+ // Methods to create the buttons in any scene.
+ //=============================================================================
+
+
+ Alias.Scene_Boot_create = Scene_Boot.prototype.create;
+
+ Scene_Boot.prototype.create = function () {
+ Alias.Scene_Boot_create.call(this);
+ var params = null;
+ Alias.globalShowStates = {};
+ Alias.TouchIdUsed=[];
+ Alias.MouseUsed=null;
+ Alias.globalShowStates.controlMethod = "touch input";// fixed rocker , dynamic rocker , touch input , fixed button
+ Alias.globalShowStates.dPadSettings = true;
+ Alias.globalShowStates.keyButtonSettings = {};
+ params = Parameters.keyButtonSettings;
+ for (var i = 0; i < params.length; i++) {
+ Alias.globalShowStates.keyButtonSettings[params[i].name.toLowerCase()] = true;
+ }
+ Alias.globalShowStates.controlButtonSettings = true;
+ Alias.globalShowStates.controlButtonX = Parameters.controlButtonSettings.x;
+ Alias.globalShowStates.controlButtonY = Parameters.controlButtonSettings.y;
+
+ window.VituralButtons=Alias.globalShowStates;
+
+ };
+
+ Alias.Scene_Base_start = Scene_Base.prototype.start;
+
+ Scene_Base.prototype.start = function () {
+ Alias.Scene_Base_start.call(this);
+ if(this instanceof Scene_Boot){return ;}
+ TouchInput.clear();
+ Input.clear();
+ Alias.MouseUsed=null;
+ Alias.TouchIdUsed=[];
+ this.createDirPad();
+ this.createKeyButtons();
+ this.createControlButton();
+ this.hideVirtualButtonsInstant();
+ this.setControlMethod(Alias.globalShowStates.controlMethod);
+ };
+
+ Scene_Base.prototype.createDirPad = function () {
+ var params = Parameters.dPadSettings;
+
+ if (params) {
+ //if (params.activeScenes.length > 0 && params.activeScenes.contains(this.constructor)) {
+ if (this instanceof Scene_Base) {
+ var x = params.x;
+ var y = params.y;
+ var image = params.rockerImage || "";
+ var hotImage="";
+ var soundEffect = params.soundEffect;
+ var pressedpointimage = params.pressedpointimage || "";
+ var buttonImage = params.padImage||"";
+ this._directionalPad = new Sprite_DirectionalPad(x, y, image, hotImage, soundEffect);
+ this.addChild(this._directionalPad);
+ this._directionalPadButton = new Sprite_DirectionalPad(x,y,buttonImage,hotImage,soundEffect);
+ this.addChild(this._directionalPadButton);
+ this._directionalPadPoint = new Sprite_DirectionalPadPoint(pressedpointimage);
+ this.addChild(this._directionalPadPoint);
+ this._directionalPadDynamic = new Sprite_DirectionalPadDynamic(params["Rectangle X"],params["Rectangle Y"],params["Dynamic rocker back img"]);
+ this.addChild(this._directionalPadDynamic);
+
+ }
+ }
+ };
+
+ Scene_Base.prototype.createKeyButtons = function () {
+ var params = Parameters.keyButtonSettings;
+
+ if (params) {
+ if (params.length > 0) {
+ this._keyButtons = {};
+ for (var i = 0; i < params.length; i++) {
+ //if (params[i].activeScenes.length > 0 && params[i].activeScenes.contains(this.constructor)) {
+ if (this instanceof Scene_Base) {
+ var a = params[i];
+ this._keyButtons[a.name.toLowerCase()] = new Sprite_KeyButton(a.x, a.y, a.image, a.hotImage, a.soundEffect, a.inputTrigger.toLowerCase(), a.customCode, a.vibratePattern, a.inputMethod, a.commonEvent);
+ this._keyButtons[a.name.toLowerCase()].name = a.name.toLowerCase();
+ this.addChild(this._keyButtons[a.name.toLowerCase()]);
+ }
+ }
+ }
+ }
+ };
+
+ Scene_Base.prototype.createControlButton = function () {
+ var params = Parameters.controlButtonSettings;
+
+ if (params) {
+ //if (params.activeScenes.length > 0 && params.activeScenes.contains(this.constructor)) {
+ if (this instanceof Scene_Base) {
+ var x = Alias.globalShowStates.controlButtonX;
+ var y = Alias.globalShowStates.controlButtonY;
+ var image = params.image || "";
+ var soundEffect = params.soundEffect;
+ this._controlButton = new Sprite_ControlButton(x, y, image, soundEffect, params.inputMethod);
+ this.addChild(this._controlButton);
+ this._controlButton._keyButtons = this._keyButtons;
+ this._controlButton._directionalPad = this._directionalPad;
+ }
+ }
+ };
+
+ Scene_Base.prototype.hideVirtualButtons = function () {
+ var _this3 = this;
+
+ if (this._directionalPad) {
+ this._directionalPad.hide();
+ this._directionalPadPoint.hide();
+ this._directionalPadDynamic.hide();
+ this._directionalPadButton.hide();
+ }
+
+ if (this._keyButtons) {
+ Object.keys(this._keyButtons).forEach(function (a) {
+ return _this3._keyButtons[a].hide();
+ });
+ }
+
+ if (this._controlButton) {
+ this._controlButton.hide();
+ }
+ };
+
+ Scene_Base.prototype.hideVirtualButtonsInstant = function () {
+ var _this3 = this;
+
+ if (this._directionalPad) {
+ this._directionalPad.hideInstant();
+ this._directionalPadPoint.hideInstant();
+ this._directionalPadDynamic.hideInstant();
+ this._directionalPadButton.hideInstant();
+ }
+
+ if (this._keyButtons) {
+ Object.keys(this._keyButtons).forEach(function (a) {
+ return _this3._keyButtons[a].hideInstant();
+ });
+ }
+
+ if (this._controlButton) {
+ this._controlButton.hideInstant();
+ }
+ };
+
+ Alias.Scene_Base_terminate = Scene_Base.prototype.terminate;
+
+ Scene_Base.prototype.terminate = function () {
+ var _this5 = this;
+
+ Alias.Scene_Base_terminate.call(this);
+
+ if (this._directionalPad) {
+ this.removeChild(this._directionalPad);
+ this.removeChild(this._directionalPadPoint);
+ this.removeChild(this._directionalPadDynamic);
+ this.removeChild(this._directionalPadButton);
+ }
+
+ if (this._keyButtons) {
+ Object.keys(this._keyButtons).forEach(function (a) {
+ return _this5.removeChild(_this5._keyButtons[a]);
+ });
+ }
+
+ if (this._controlButton) {
+ this.removeChild(this._controlButton);
+ }
+ };
+
+ Scene_Base.prototype.setControlMethod = function(method){
+ this.hideVirtualButtonsInstant();
+ switch(method){
+ case "touch input":
+ if(this._controlButton) this._controlButton.show();
+ break;
+ case "fixed rocker": case "dynamic rocker":
+ if(this._controlButton && Alias.globalShowStates.controlButtonSettings) this._controlButton.show();
+ if(this._directionalPadDynamic && Alias.globalShowStates.dPadSettings) this._directionalPadDynamic.show();
+ if(this._directionalPadPoint && Alias.globalShowStates.dPadSettings) this._directionalPadPoint.show();
+ if(this._directionalPad && Alias.globalShowStates.dPadSettings){
+ this._directionalPad.show();
+ this._directionalPad.x=isNaN(Parameters.dPadSettings.x)?eval(Parameters.dPadSettings.x):Parameters.dPadSettings.x;
+ this._directionalPad.y=isNaN(Parameters.dPadSettings.y)?eval(Parameters.dPadSettings.y):Parameters.dPadSettings.y;
+ }
+ Object.keys(this._keyButtons).forEach(function(key){
+ if(Alias.globalShowStates.keyButtonSettings[key]) SceneManager._scene._keyButtons[key].show();
+ });
+ break;
+ case "fixed button":
+ if(this._controlButton && Alias.globalShowStates.controlButtonSettings) this._controlButton.show();
+ //if(this._directionalPadDynamic && Alias.globalShowStates.dPadSettings) this._directionalPadDynamic.show();
+ //if(this._directionalPadPoint && Alias.globalShowStates.dPadSettings) this._directionalPadPoint.show();
+ if(this._directionalPadButton && Alias.globalShowStates.dPadSettings) this._directionalPadButton.show();
+ Object.keys(this._keyButtons).forEach(function(key){
+ if(Alias.globalShowStates.keyButtonSettings[key]) SceneManager._scene._keyButtons[key].show();
+ });
+ break;
+ default:
+ if(this._controlButton) this._controlButton.show();
+ }
+ Alias.globalShowStates.controlMethod=method;
+ };
+
+ //=============================================================================
+ // Scene_Map
+ //=============================================================================
+ // If map movement is disabled from the parameters, return.
+ // If an active button is pressed, don't do the usual map movement.
+ //=============================================================================
+
+
+ Alias.Scene_Map_processMapTouch = Scene_Map.prototype.processMapTouch;
+
+ Scene_Map.prototype.processMapTouch = function () {
+ var point=new Point(TouchInput.x,TouchInput.y);
+ if(Alias.globalShowStates.controlMethod=="touch input"&&
+ !SceneManager._scene._controlButton.containsPoint(point))
+ Alias.Scene_Map_processMapTouch.call(this);
+ };
+
+ Alias.Scene_Map_isMenuCalled = Scene_Map.prototype.isMenuCalled;
+ Scene_Map.prototype.isMenuCalled = function () {
+ if (Alias.globalShowStates.controlMethod=="touch input") {
+ return Alias.Scene_Map_isMenuCalled.call(this);
+ } else {
+ return Input.isTriggered('menu');
+ }
+ };
+
+ //=============================================================================
+ // Window_Selectable
+ //=============================================================================
+ // Disable Touch Input on selectable windows if configured in the parameters.
+ //=============================================================================
+
+
+ Alias.Window_Selectable_processTouch = Window_Selectable.prototype.processTouch;
+
+ Window_Selectable.prototype.processTouch = function () {
+ var point=new Point(TouchInput.x,TouchInput.y);
+ if(SceneManager._scene._controlButton&&
+ SceneManager._scene._controlButton.active&&
+ (Alias.globalShowStates.controlMethod!="touch input"||
+ SceneManager._scene._controlButton.containsPoint(point))) return;
+
+ Alias.Window_Selectable_processTouch.call(this);
+ };
+ //=============================================================================
+ // Window_Message
+ //=============================================================================
+ // Control UI visibility when the dialogue window is activated.
+ //=============================================================================
+
+
+ if (Parameters.hideButtonsDuringDialogue) {
+ Alias.Window_Message_startMessage = Window_Message.prototype.startMessage;
+
+ Window_Message.prototype.startMessage = function () {
+ SceneManager._scene.hideVirtualButtons();
+ if(SceneManager._scene._keyButtons["debug"]){//&&Alias.globalShowStates.controlMethod!='touch input'){
+ SceneManager._scene._keyButtons["debug"].showInstant();
+ }
+ ALOE.clearDpadInput();
+ Alias.Window_Message_startMessage.call(this);
+ };
+
+ Alias.Window_Message_terminateMessage = Window_Message.prototype.terminateMessage;
+
+ Window_Message.prototype.terminateMessage = function () {
+ Alias.Window_Message_terminateMessage.call(this);
+ SceneManager._scene.setControlMethod(Alias.globalShowStates.controlMethod);
+ };
+ }
+
+ if (Parameters.enableDPadDebugWindow) {
+ //=============================================================================
+ // Window_TouchInputTest
+ //=============================================================================
+ // The window to test what inputs are currently pressed on the D-Pad
+ //=============================================================================
+ var Window_TouchInputTest = function Window_TouchInputTest() {
+ this.initialize.apply(this, arguments);
+ };
+
+ Window_TouchInputTest.prototype = Object.create(Window_Base.prototype);
+ Window_TouchInputTest.prototype.constructor = Window_TouchInputTest;
+
+ Window_TouchInputTest.prototype.initialize = function () {
+ Window_Base.prototype.initialize.call(this, Graphics.width - 300, 0, 300, 200);
+ this._lastState = {
+ up: false,
+ right: false,
+ down: false,
+ left: false
+ };
+ this.refresh();
+ };
+
+ Window_TouchInputTest.prototype.update = function () {
+ Window_Base.prototype.update.call(this);
+
+ if (this.stateHasChanged()) {
+ this.refresh();
+ }
+ };
+
+ Window_TouchInputTest.prototype.refresh = function () {
+ this.contents.clear();
+ this.drawText("Up: ".concat(Input._currentState.up), 6, 0);
+ this.drawText("Right: ".concat(Input._currentState.right), 6, this.lineHeight());
+ this.drawText("Down: ".concat(Input._currentState.down), 6, this.lineHeight() * 2);
+ this.drawText("Left: ".concat(Input._currentState.left), 6, this.lineHeight() * 3);
+ };
+
+ Window_TouchInputTest.prototype.stateHasChanged = function () {
+ if (this._lastState.up !== Input._currentState.up) {
+ this._lastState.up = Input._currentState.up;
+ return true;
+ }
+
+ if (this._lastState.right !== Input._currentState.right) {
+ this._lastState.right = Input._currentState.right;
+ return true;
+ }
+
+ if (this._lastState.down !== Input._currentState.down) {
+ this._lastState.down = Input._currentState.down;
+ return true;
+ }
+
+ if (this._lastState.left !== Input._currentState.left) {
+ this._lastState.left = Input._currentState.left;
+ return true;
+ }
+
+ return false;
+ };
+
+ var Scene_Map_createMapNameWindow = Scene_Map.prototype.createMapNameWindow;
+
+ Scene_Map.prototype.createMapNameWindow = function () {
+ this._touchInputTestWindow = new Window_TouchInputTest();
+ this.addChild(this._touchInputTestWindow);
+ Scene_Map_createMapNameWindow.call(this);
+ };
+ } // end if Parameters.enableDPadDebugWindow
+ //=============================================================================
+ // Game_Player
+ //=============================================================================
+ // Help solve bug with stuck movement by clearing input on map transfer.
+ //=============================================================================
+
+
+ var Game_Player_performTransfer = Game_Player.prototype.performTransfer;
+
+ Game_Player.prototype.performTransfer = function () {
+ if (this.isTransferring()) {
+ Game_Player_performTransfer.call(this);
+ ALOE.clearDpadInput();
+ }
+ };
+
+ ALOE.clearDpadInput = function () {
+ delete Input._currentState.left;
+ delete Input._currentState.right;
+ delete Input._currentState.up;
+ delete Input._currentState.down;
+ };
+ //==============================================================================
+ // Array.prototype.includes
+ // Array.prototype.find
+ //==============================================================================
+ // Polyfill for old versions of MV (1.5 and earlier)
+ //==============================================================================
+ // https://tc39.github.io/ecma262/#sec-array.prototype.includes
+
+
+ if (!Array.prototype.includes) {
+ Object.defineProperty(Array.prototype, 'includes', {
+ value: function value(valueToFind, fromIndex) {
+ if (this == null) {
+ throw new TypeError('"this" is null or not defined');
+ } // 1. Let O be ? ToObject(this value).
+
+
+ var o = Object(this); // 2. Let len be ? ToLength(? Get(O, "length")).
+
+ var len = o.length >>> 0; // 3. If len is 0, return false.
+
+ if (len === 0) {
+ return false;
+ } // 4. Let n be ? ToInteger(fromIndex).
+ // (If fromIndex is undefined, this step produces the value 0.)
+
+
+ var n = fromIndex | 0; // 5. If n ≥ 0, then
+ // a. Let k be n.
+ // 6. Else n < 0,
+ // a. Let k be len + n.
+ // b. If k < 0, let k be 0.
+
+ var k = Math.max(n >= 0 ? n : len - Math.abs(n), 0);
+
+ function sameValueZero(x, y) {
+ return x === y || typeof x === 'number' && typeof y === 'number' && isNaN(x) && isNaN(y);
+ } // 7. Repeat, while k < len
+
+
+ while (k < len) {
+ // a. Let elementK be the result of ? Get(O, ! ToString(k)).
+ // b. If SameValueZero(valueToFind, elementK) is true, return true.
+ if (sameValueZero(o[k], valueToFind)) {
+ return true;
+ } // c. Increase k by 1.
+
+
+ k++;
+ } // 8. Return false
+
+
+ return false;
+ }
+ });
+ } // https://tc39.github.io/ecma262/#sec-array.prototype.find
+
+
+ if (!Array.prototype.find) {
+ Object.defineProperty(Array.prototype, 'find', {
+ value: function value(predicate) {
+ // 1. Let O be ? ToObject(this value).
+ if (this == null) {
+ throw new TypeError('"this" is null or not defined');
+ }
+
+ var o = Object(this); // 2. Let len be ? ToLength(? Get(O, "length")).
+
+ var len = o.length >>> 0; // 3. If IsCallable(predicate) is false, throw a TypeError exception.
+
+ if (typeof predicate !== 'function') {
+ throw new TypeError('predicate must be a function');
+ } // 4. If thisArg was supplied, let T be thisArg; else let T be undefined.
+
+
+ var thisArg = arguments[1]; // 5. Let k be 0.
+
+ var k = 0; // 6. Repeat, while k < len
+
+ while (k < len) {
+ // a. Let Pk be ! ToString(k).
+ // b. Let kValue be ? Get(O, Pk).
+ // c. Let testResult be ToBoolean(? Call(predicate, T, « kValue, k, O »)).
+ // d. If testResult is true, return kValue.
+ var kValue = o[k];
+
+ if (predicate.call(thisArg, kValue, k, o)) {
+ return kValue;
+ } // e. Increase k by 1.
+
+
+ k++;
+ } // 7. Return undefined.
+
+
+ return undefined;
+ },
+ configurable: true,
+ writable: true
+ });
+ }
+ //Rewrite TouchInput
+
+ Alias.TouchInput_update = TouchInput.update;
+ TouchInput.update = function () {
+ Alias.TouchInput_update.call(this);
+ this._event = this._events._event;
+ //this._events._event = null;
+ };
+
+ Alias.TouchInput_clear = TouchInput.clear;
+ TouchInput.clear = function () {
+ Alias.TouchInput_clear.call(this);
+ this._events._event = null;
+ };
+
+ Alias.TouchInput_onMouseDown = TouchInput._onMouseDown;
+ TouchInput._onMouseDown = function (event) {
+ this._events._event = event;
+ Alias.TouchInput_onMouseDown.call(this, event);
+ };
+
+ Alias.TouchInput_onMouseMove = TouchInput._onMouseMove;
+ TouchInput._onMouseMove = function (event) {
+ this._events._event = event;
+ Alias.TouchInput_onMouseMove.call(this, event);
+ };
+
+ Alias.TouchInput_onMouseUp = TouchInput._onMouseUp;
+ TouchInput._onMouseUp = function (event) {
+ this._events._event = event;
+ Alias.TouchInput_onMouseUp.call(this, event);
+ };
+
+ Alias.TouchInput_onWheel = TouchInput._onWheel;
+ TouchInput._onWheel = function (event) {
+ this._events._event = event;
+ Alias.TouchInput_onWheel.call(this, event);
+ };
+
+ Alias.TouchInput_onTouchStart = TouchInput._onTouchStart;
+ TouchInput._onTouchStart = function (event) {
+ this._events._event = event;
+ Alias.TouchInput_onTouchStart.call(this, event);
+ this._screenPressed = event.targetTouches.length !== 0;
+ };
+
+ Alias.TouchInput_onTouchMove = TouchInput._onTouchMove;
+ TouchInput._onTouchMove = function (event) {
+ this._events._event = event;
+ Alias.TouchInput_onTouchMove.call(this, event);
+ this._screenPressed = event.targetTouches.length !== 0;
+ };
+
+ Alias.TouchInput_onTouchEnd = TouchInput._onTouchEnd;
+ TouchInput._onTouchEnd = function (event) {
+ this._events._event = event;
+ Alias.TouchInput_onTouchEnd.call(this, event);
+ this._screenPressed = event.targetTouches.length !== 0;
+ };
+
+ Alias.TouchInput_onTouchCancel = TouchInput._onTouchCancel;
+ TouchInput._onTouchCancel = function (event) {
+ this._events._event = event;
+ Alias.TouchInput_onTouchCancel.call(this, event);
+ this._screenPressed = event.targetTouches.length !== 0;
+ };
+
+ Alias.TouchInput_onPointerDown = TouchInput._onPointerDown;
+ TouchInput._onPointerDown = function (event) {
+ this._events._event = event;
+ Alias.TouchInput_onPointerDown.call(this, event);
+ };
+
+ Alias.DataManager_makeSaveContents = DataManager.makeSaveContents;
+ DataManager.makeSaveContents = function () {
+ var contents = Alias.DataManager_makeSaveContents.call(this);
+ contents.virtualButtonSates = Alias.globalShowStates;
+ return contents;
+ };
+
+ Alias.DataManager_extractSaveContents = DataManager.extractSaveContents;
+ DataManager.extractSaveContents = function (contents) {
+ Alias.DataManager_extractSaveContents.call(this, contents);
+ Alias.globalShowStates = contents.virtualButtonSates;
+ if (!Alias.globalShowStates) {
+ var params = null;
+ Alias.globalShowStates = {};
+
+ if (Parameters.dPadSettings.activeScenes) {
+ Alias.globalShowStates.dPadSettings = true;
+ }
+
+ if (Parameters.keyButtonSettings) {
+ Alias.globalShowStates.keyButtonSettings = {};
+ params = Parameters.keyButtonSettings;
+ for (var i = 0; i < params.length; i++) {
+ Alias.globalShowStates.keyButtonSettings[params[i].name.toLowerCase()] = true;
+ }
+ }
+
+ if (Parameters.controlButtonSettings.activeScenes) {
+ Alias.globalShowStates.controlButtonSettings = true;
+ Alias.globalShowStates.controlButtonX = Parameters.controlButtonSettings.x;
+ Alias.globalShowStates.controlButtonY = Parameters.controlButtonSettings.y;
+ }
+
+ Alias.globalShowStates.controlMethod='touch input';
+ }
+
+ window.VituralButtons=Alias.globalShowStates;
+ };
+
+ Object.defineProperties(Game_CharacterBase.prototype, {
+ '_moveSpeed': {
+ get: function () {
+ if (SceneManager._scene && SceneManager._scene._directionalPadPoint && SceneManager._scene._directionalPadPoint.active) {
+ var point1 = SceneManager._scene._directionalPadPoint._point;
+ var center = SceneManager._scene._directionalPad.GetCenterPoint();
+ if (!(center && point1)) {
+ return this._ALOE_maxMoveSpeed;
+ }
+ var range = SceneManager._scene._directionalPad.absDistance(point1, center);
+ var width = Math.max(SceneManager._scene._directionalPad.width, SceneManager._scene._directionalPad.height);
+ if (range > width / 2 || range < width / 6) {
+ return this._ALOE_maxMoveSpeed;
+ } else {
+ return (range - width / 6) / (width / 3) * this._ALOE_maxMoveSpeed;
+ }
+ } else {
+ return this._ALOE_maxMoveSpeed;
+ }
+ },
+ set: function (value) {
+ this._ALOE_maxMoveSpeed = value;
+ return value;
+ },
+ configurable: true
+ }
+ });
+})();
\ No newline at end of file