Project1
标题:
新人的求助
[打印本页]
作者:
cinderelmini
时间:
2008-9-5 23:14
标题:
新人的求助
本人由于接触到RMXP有一段时间了,所以很喜欢这款软件,但是对于脚本的问题简直是一个白痴,所以求脚本高手帮帮我写个更换领队的脚本。
那个……嗯~谢谢了!!{/tp} [LINE]1,#dddddd[/LINE]
版务信息:本贴由楼主自主结贴~
作者:
Tabris_Air
时间:
2008-9-5 23:21
#主站上的换序脚本我稍微该了一下,领队更换后地图上将显示带头角色的行走图
#如果想不换把脚本最后那个$game_player.refresh删掉即可
#==============================================================================
# 本脚本来自www.66RPG.com,使用和转载请保留此信息
#==============================================================================
class Scene_Menu
# --------------------------------
def initialize(menu_index = 0)
@menu_index = menu_index
@changer = 0
@where = 0
@checker = 0
end
# --------------------------------
def main
s1 = $data_system.words.item
s2 = $data_system.words.skill
s3 = $data_system.words.equip
s4 = "状态"
s5 = "调整队伍"
s6 = "储存游戏"
s7 = "离开游戏"
@command_window = Window_Command.new(160, [s1, s2, s3, s4, s5, s6, s7])
@command_window.index = @menu_index
if $game_party.actors.size == 0
@command_window.disable_item(0)
@command_window.disable_item(1)
@command_window.disable_item(2)
@command_window.disable_item(3)
end
if $game_system.save_disabled
@command_window.disable_item(4)
end
if $game_party.actors.size == 1
@command_window.disable_item(6)
end
@playtime_window = Window_PlayTime.new
@playtime_window.x = 0
@playtime_window.y = 256
@gold_window = Window_Gold.new
@gold_window.x = 0
@gold_window.y = 416
@status_window = Window_MenuStatus.new
@status_window.x = 160
@status_window.y = 0
Graphics.transition
loop do
Graphics.update
Input.update
update
if $scene != self
break
end
end
Graphics.freeze
@command_window.dispose
@playtime_window.dispose
@gold_window.dispose
@status_window.dispose
end
# --------------------------------
def update
@command_window.update
@playtime_window.update
@gold_window.update
@status_window.update
if @command_window.active
update_command
return
end
if @status_window.active
update_status
return
end
end
# --------------------------------
def update_command
if Input.trigger?(Input::B)
$game_system.se_play($data_system.cancel_se)
$scene = Scene_Map.new
return
end
if Input.trigger?(Input::C)
if $game_party.actors.size == 0 and @command_window.index < 4
$game_system.se_play($data_system.buzzer_se)
return
end
if $game_party.actors.size == 1 and @command_window.index ==6
$game_system.se_play($data_system.buzzer_se)
return
end
case @command_window.index
when 0
$game_system.se_play($data_system.decision_se)
$scene = Scene_Item.new
when 1
$game_system.se_play($data_system.decision_se)
@command_window.active = false
@status_window.active = true
@status_window.index = 0
when 2
$game_system.se_play($data_system.decision_se)
@command_window.active = false
@status_window.active = true
@status_window.index = 0
when 3
$game_system.se_play($data_system.decision_se)
@command_window.active = false
@status_window.active = true
@status_window.index = 0
when 5
if $game_system.save_disabled
$game_system.se_play($data_system.buzzer_se)
return
end
$game_system.se_play($data_system.decision_se)
$scene = Scene_Save.new
when 6
$game_system.se_play($data_system.decision_se)
$scene = Scene_End.new
when 4
$game_system.se_play($data_system.decision_se)
@checker = 0
@command_window.active = false
@status_window.active = true
@status_window.index = 0
end
return
end
end
# --------------------------------
def update_status
if Input.trigger?(Input::B)
$game_system.se_play($data_system.cancel_se)
@command_window.active = true
@status_window.active = false
@status_window.index = -1
return
end
if Input.trigger?(Input::C)
case @command_window.index
when 1
if $game_party.actors[@status_window.index].restriction >= 2
$game_system.se_play($data_system.buzzer_se)
return
end
$game_system.se_play($data_system.decision_se)
$scene = Scene_Skill.new(@status_window.index)
when 2
$game_system.se_play($data_system.decision_se)
$scene = Scene_Equip.new(@status_window.index)
when 3
$game_system.se_play($data_system.decision_se)
$scene = Scene_Status.new(@status_window.index)
when 4
$game_system.se_play($data_system.decision_se)
if @checker == 0
@changer = $game_party.actors[@status_window.index]
@where = @status_window.index
@checker = 1
else
$game_party.actors[@where] = $game_party.actors[@status_window.index]
$game_party.actors[@status_window.index] = @changer
@checker = 0
@status_window.refresh
$game_player.refresh
end
end
return
end
end
end
#==============================================================================
# 本脚本来自www.66RPG.com,使用和转载请保留此信息
#==============================================================================
[LINE]1,#dddddd[/LINE]
系统信息:本贴由楼主认可为正确答案,66RPG感谢您的热情解答~
作者:
浩气青天
时间:
2008-9-5 23:22
领队脚本。。。。。已经有了,请在主站上搜索“领队”就能找到了。还有,以后楼主要学习脚本,要自己努力。不能说自己是脚本盲就什么都不用干了,坐着等别人给你,这样大家都不会帮助你的。一个好游戏是要付出努力的,没有人一生下来就是脚本天才。
作者:
浩气青天
时间:
2008-9-5 23:24
唉,用手机打字就是慢啊~~
作者:
CIS狂人
时间:
2008-9-5 23:27
- -楼主如果2楼的脚本能用的话,请认可答案(被T飞)
顺便,脚本是要自己摸索着来的哦
作者:
浩气青天
时间:
2008-9-5 23:34
汗,是说我的答案么?我用手机上的,给不了地址,需要楼主自己去搜索一下额。
作者:
cinderelmini
时间:
2008-9-5 23:43
各位,谢谢了。我也是在学着脚本,只是学得慢了点。
本人刚来这里,有什么不好的地方请指教。
还有我的第一个游戏在摸熟了软件后正在慢慢成长中,
以后可能还会麻烦大家了……呵呵
欢迎光临 Project1 (https://rpg.blue/)
Powered by Discuz! X3.1