查看: 1381|回复: 0

[有事请教] 将定义脚本输入命令装换成选项命令然后在窗口执行

[复制链接]
梦石
0
星屑
7296
在线时间
1244 小时
注册时间
2015-8-15
回帖
473
发表于 2023-5-22 10:45:06 | 显示全部楼层 |阅读模式

加入我们,或者,欢迎回来。

您需要 登录 才可以下载或查看,没有账号?注册会员

×
本帖最后由 金芒芒 于 2023-5-22 11:02 编辑

选项命令=10个  命令1=图中的1 命令2=图中的2  命令3=图中的3  命令4=图中的4  命令5 =图中的5 命令6 =图中的6 命令7=图中的7 命令8 =图中的8 命令9 =图中的9  命令10 =图中的10
图片是窗口的背景图  
命令1= $game_player.x+4,$game_player.y+11
display_move_able_groups(group)#↓关联  这段脚本不能少

[pre lang="ruby"]  def _update_comand_input_for_spawn(group)#定义 _更新生成(组)的命令和输入 ↑关联
  #-<方向键>------------   
      if Input.repeat?(Input::UP) #如果输入重复?(输入::向上)
        #p $game_screen.tone.red
        #如果@efs团队出生点。包括?([$游戏玩家.x,$游戏玩家.y-1])
        if @efs_team_spawn.include?([$game_player.x,$game_player.y-1])
        #$游戏系统。se播放($数据系统。光标se)
        $game_system.se_play($data_system.cursor_se)
        #取消使地图移动(@团队显示区域)
        cancel_make_map_move(@team_display_area)
        #$游戏玩家。移动到($游戏玩家.x,$游戏玩家.y-1)
          $game_player.moveto($game_player.x,$game_player.y-1)
          #显示可移动组(组)
          display_move_able_groups(group)#↓关联
        else#否则
        #$游戏系统。se播放($数据 系统.蜂鸣器se)
        $game_system.se_play($data_system.buzzer_se)
        end  
        return#返回
      end
      if Input.repeat?(Input::DOWN)
        if @efs_team_spawn.include?([$game_player.x,$game_player.y+1])  
        $game_system.se_play($data_system.cursor_se)
        cancel_make_map_move(@team_display_area)
        $game_player.moveto($game_player.x,$game_player.y+1)  
        display_move_able_groups(group)#↓关联
        else  
       $game_system.se_play($data_system.buzzer_se)
       end  
      return
      end
      if Input.repeat?(Input::RIGHT)  
       if @efs_team_spawn.include?([$game_player.x+1,$game_player.y])  
        $game_system.se_play($data_system.cursor_se)
        cancel_make_map_move(@team_display_area)
          $game_player.moveto($game_player.x+1,$game_player.y)  
         display_move_able_groups(group)#↓关联
       else  
       $game_system.se_play($data_system.buzzer_se)
       end  
        return
      end
      if Input.repeat?(Input::LEFT)
        if @efs_team_spawn.include?([$game_player.x-1,$game_player.y])  
        $game_system.se_play($data_system.cursor_se)
        cancel_make_map_move(@team_display_area)
          $game_player.moveto($game_player.x-1,$game_player.y)  
         display_move_able_groups(group)#↓关联
        else  
        $game_system.se_play($data_system.buzzer_se)
        end  
       return
      end  
  end[/pre]
布阵窗口背景图.png
您需要登录后才可以回帖 登录 | 注册会员

本版积分规则

Powered by Discuz! X5.0 © 2001-2026 Discuz! Team.

在本版发帖返回顶部