经常用下google,你就会明白的,其实很简答的设置地图备注中写 <all restrict: x, x>则所有npc和玩家都无法通过x,x这几个区域(穿透时依然不通过),<npc restrict: x, x> npc无法通过(玩家可通过,穿透时可通过),<player restrict: x, x>玩家不可通过(npc可通过,穿透时可通过), |
到底要怎么使用啊~~~ |
吾不知 发表于 2012-8-30 12:53 #================================================= ============================= # ▼Yanfly发动机王牌 - 移动限制区域v1.02版 # - 最新更新时间:2012.01.03 - 等级:普通 - 要求:N / A # #================================================= ============================= 美元进口= {}如果$ imported.nil中? 美元进口[“YEA - MoveRestrictRegion”] =真 #================================================= ============================= #▼更新 #= - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = 2012.01.03 - 新增的功能:<all restrict: X> 2011.12.26 - 修正:球员受限制的地区。 #2011.12.15 - 开始脚本和成品。 # #================================================= ============================= #▼公司简介 #= - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = #不是每个人都希望全国人民代表大会所有的地方旅行。有了这个脚本,你 #可以设置NPC无法移动通瓷砖标记指定的地区。 #简单地绘制出地区要附上全国人民代表大会上,他们将 #无法过去,除非他们通过上移动。同样,也有 #地区,你可以阻止玩家移动到,太! # #================================================= ============================= #▼说明 #= - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = #如果要安装这个脚本,脚本编辑器打开你的复制/粘贴此脚本 #▼材料/素材,但高于▼主要的开放式插槽下面。记住要保存。 # #------------------------------------------------- ---------------------------- 在地图的属性的地图notebox在#地图Notetags的 - 这些notetags。 #------------------------------------------------- ---------------------------- #<all restrict: X> #<all restrict: x, X> #玩家和NPC在地图上无法移动过去的区域x即使 #他们有“通过”标志。唯一可以走过去的是,如果 #播放器使用调试通过标志。绘制出你要关闭的 #玩家和NPC在与各区域都将是无法将其移动到 这些瓷砖#任何标记的区域x。如果你想有更多的地区 限制NPC,插入这个标签的倍数。 # #<npc restrict: X> #<npc restrict: x, X> 全国人民代表大会上,地图将无法移动过去的区域x,除非他们有 #“通过”标志。你要关闭全国人民代表大会的绘制出区 地区和全国人民代表大会的,将不能移动到任何那些瓷砖标记的 #X区。如果你想有更多的地区限制NPC,插入 #这个标签的倍数。 # #<玩家restrict: X> #<玩家restrict: x, X> 玩家将无法移动标记的区域x的瓷砖,除非 #播放器有一个“直通”的标志。画出来的,你要关闭 #球员在地区和球员将无法移动过去任何 #砖标志的区域x。如果你想有更多的区域限制 #播放器,插入这个标签的倍数。 # #================================================= ============================= #▼兼容性 #= - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = #这个脚本是为RPG制作VX王牌的严格。这是极不可能的 #将运行与的RPG制造商VX没有调整。 # #================================================= ============================= 模块YEA 模块MOVE_RESTRICT #= - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - # - 默认完全限制地区 - #= - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - #如果你想始终是一个区域ID,将禁止 #玩家和NPC的通过,插入到该地区的ID #下面的数组。这个效果会完全阻止玩家和NPC #即使他们有“通过”标志。然而,它不阻止 #debug_through标志的球员。 #= - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - DEFAULT_ALL = [61] #= - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - # - 默认播放器受限制的地区 - #= - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - #如果你想始终是一个区域ID,将禁止球员 #通过,该地区的ID插入到数组中。 #= - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - DEFAULT_PLAYER = [62] #= - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - # - 默认全国人大受限制的地区 - #= - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - #如果你想始终是一个区域ID,将禁止全国人民代表大会 #通过插入到该地区的ID下面的阵列。 #= - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - = - DEFAULT_NPC = [63] 结束#MOVE_RESTRICT 结束#YEA #================================================= ============================= ▼过去,这点编辑工作的任何可能会导致造成 #电脑损伤,大小便失禁,使用者的头部,昏迷,死亡的爆炸,和/或 #口臭,编辑您自己的风险。 #================================================= ============================= 模块YEA 模块REGEXP 模块图 ALL_RESTRICT = / <(?ALL_RESTRICT所有限制):[] *(\ d +(?:\ * \ * \ d +)*)/ I NPC_RESTRICT = / <(?NPC_RESTRICT全国人民代表大会限制):[] *(\ d +(?:\ * \ * \ d +)*)/ I PLAYER_RESTRICT = / <(?PLAYER_RESTRICT |玩家限制):[] *(\ d +(?:\ * \ * \ d +)*)/ I 结束#地图 结束#REGEXP 结束#YEA #================================================= ============================= #■RPG ::地图 #================================================= ============================= 类RPG ::地图 #------------------------------------------------- ------------------------- #实例变量 #------------------------------------------------- ------------------------- attr_accessor中:all_restrict_regions attr_accessor中:npc_restrict_regions attr_accessor中:player_restrict_regions #------------------------------------------------- ------------------------- #常用的缓存:load_notetags_mrr #------------------------------------------------- ------------------------- 高清load_notetags_mrr @ all_restrict_regions = YEA :: MOVE_RESTRICT :: DEFAULT_ALL.clone @ npc_restrict_regions = YEA :: MOVE_RESTRICT :: DEFAULT_NPC.clone @ player_restrict_regions = YEA :: MOVE_RESTRICT :: DEFAULT_PLAYER.clone #--- self.note.split(/ [\ r \ n] + /)。每个{|生产线| 情况下,行 #--- 当YEA :: REGEXP ::地图:: NPC_RESTRICT $ 1。扫描(/ \ d + /)。每个{|数| @如果num.to_i npc_restrict_regions.push(num.to_i)> 0} 当YEA :: REGEXP ::地图:: PLAYER_RESTRICT $ 1。扫描(/ \ d + /)。每个{|数| @如果num.to_i player_restrict_regions.push(num.to_i)> 0} #--- 结束 }#self.note.split #--- 结束 结束RPG ::地图 #================================================= ============================= #■Game_Map #================================================= ============================= 类Game_Map #------------------------------------------------- ------------------------- #别名方法:设置 #------------------------------------------------- ------------------------- 别名game_map_setup_mrr设置 清晰度设置(MAP_ID) game_map_setup_mrr(MAP_ID) @ map.load_notetags_mrr 结束 #------------------------------------------------- ------------------------- #新方法:all_restrict_regions #------------------------------------------------- ------------------------- 高清all_restrict_regions [email protected]_restrict_regions 结束 #------------------------------------------------- ------------------------- #新方法:npc_restrict_regions #------------------------------------------------- ------------------------- 高清npc_restrict_regions [email protected]_restrict_regions 结束 #------------------------------------------------- ------------------------- #新方法:player_restrict_regions #------------------------------------------------- ------------------------- 高清player_restrict_regions [email protected]_restrict_regions 结束 结束#Game_Map #================================================= ============================= #■Game_CharacterBase #================================================= ============================= 类Game_CharacterBase #------------------------------------------------- ------------------------- #别名方法:过得去吗? #------------------------------------------------- ------------------------- 别名game_characterbase_passable_mrr过得去吗? 高清过得去吗?(X,Y,D)。 返回false,如果npc_region_forbid(X,Y,D)。 返回false,如果player_region_forbid(X,Y,D)。 公共返回game_characterbase_passable_mrr(X,Y,D) 结束 #------------------------------------------------- ------------------------- #新方法:npc_forbid的? #------------------------------------------------- ------------------------- DEF(X,Y,D npc_region_forbid?) 返回false,除非self.is_a?(Game_Event) 地区= 0 情况d 当1;区域= $ game_map.region_id(x-1和y +1中) 2区= $ game_map.region_id(X 0,Y +1) 3,区域= $ game_map.region_id(X +1,Y +1) 当4;区域= $ game_map.region_id(x-1的,Ŷ0) 5区= $ game_map.region_id(x 0,y 0) 6区= $ game_map.region_id(X +1,Y +0) 当7;区域= $ game_map.region_id(x-1的,γ-1) 当8个区域= $ game_map.region_id(X 0,Y-1) 9地区的= $ game_map.region_id(X +1,Y-1) 结束 返回TRUE,如果$ game_map.all_restrict_regions.include(地区)? @返回false,如果通过 返回game_map.npc_restrict_regions.include?(地区) 结束 #------------------------------------------------- ------------------------- #新方法:player_region_forbid的? #------------------------------------------------- ------------------------- DEF(X,Y,D player_region_forbid?) 返回false,除非self.is_a?(Game_Player) 返回false如果debug_through? 地区= 0 情况d 当1;区域= $ game_map.region_id(x-1和y +1中) 2区= $ game_map.region_id(X 0,Y +1) 3,区域= $ game_map.region_id(X +1,Y +1) 当4;区域= $ game_map.region_id(x-1的,Ŷ0) 5区= $ game_map.region_id(x 0,y 0) 6区= $ game_map.region_id(X +1,Y +0) 当7;区域= $ game_map.region_id(x-1的,γ-1) 当8个区域= $ game_map.region_id(X 0,Y-1) 9地区的= $ game_map.region_id(X +1,Y-1) 结束 返回TRUE,如果$ game_map.all_restrict_regions.include(地区)? @返回false,如果通过 返回game_map.player_restrict_regions.include?(地区) 结束 结束#Game_CharacterBase #================================================= ============================= # #▼文件结束 # #================================================= ============================= 我看不懂.. |
脚本:YEA移动区域限制 使用方法:用google翻译吧 ! 来源:http://yanflychannel.wordpress.com/rmvxa/
|
设置移动路线,让他在湖里绕圈就可以了 |
简单的办法 首先你得找个水中游鸭子行走图…… 然后设置移动路线……自定义(允许穿透)然后就左右左右木纳的移动吧……重复执行+不需要等待到移动结束 …………………… ![]() |
同学请看图![]() 打开VA【数据库】 找到【图块】 看见右边的【有害地形】了么? 如果是【△△】则是会扣血的有害地形图块,【 · 】就是不扣血的正常图块 你将你想设定的水属性图块按成【△△】就可以了! 至于想调节地形伤害 就打开脚本编辑器 按Ctrl+Shift+F全局搜索“地形”转至Game_Actor(649行) 然后调一下Return的伤害值就好! ![]() 不过相对麻烦。 所以方法在此不列出来了。。。 |
站长信箱:[email protected]|手机版|小黑屋|无图版|Project1游戏制作
GMT+8, 2025-7-17 15:01
Powered by Discuz! X3.1
© 2001-2013 Comsenz Inc.