Project1

标题: 脚本不会用 [打印本页]

作者: 秋寒    时间: 2013-6-20 13:23
标题: 脚本不会用
其实,我不会用是有原因的,这个“白云飘飘‘脚本附件链接失效了,只留下脚本,连说明书都没有....
谁帮我看下怎么用
RUBY 代码复制
  1. class Cloud
  2.   def ready
  3.     $p1xx = 384
  4.     $p2xx = 380
  5.     $p3xx = 383
  6.     $p4xx = 480
  7.     $p5xx = 480
  8.     $p1s = 1
  9.     $p2s = 4
  10.     $p3s = 6
  11.     $p4s = 9
  12.     $p5s = 15
  13.     $p1x = 0
  14.     $p2x = $p1xx
  15.     $p3x = -$p1xx
  16.     $p4x = 0
  17.     $p5x = $p1xx
  18.     $p6x = -$p1xx
  19.     $p7x = 0
  20.     $p8x = $p1xx
  21.     $p9x = -$p1xx
  22.     $p10x = 0
  23.     $p11x = $p1xx
  24.     $p13x = 0
  25.     $p14x = $p1xx
  26.   end
  27.   def start
  28.     $p1x += $p1s
  29.     $p2x += $p1s
  30.     $p3x += $p1s
  31.     $p4x += $p2s
  32.     $p5x += $p2s
  33.     $p6x += $p2s
  34.     $p7x += $p3s
  35.     $p8x += $p3s
  36.     $p9x += $p3s
  37.     $p10x += $p4s
  38.     $p11x += $p4s
  39.     $p13x += $p5s
  40.     $p14x += $p5s
  41.     $game_screen.pictures[1].show("c1.png", 0, $p1x, 0, 100, 100, 255, 0)
  42.     $game_screen.pictures[2].show("c1.png", 0, $p2x, 0, 100, 100, 255, 0)
  43.     $game_screen.pictures[3].show("c1.png", 0, $p3x, 0, 100, 100, 255, 0)
  44.     $game_screen.pictures[4].show("c2.png", 0, $p4x, 27, 100, 100, 255, 0)
  45.     $game_screen.pictures[5].show("c2.png", 0, $p5x, 27, 100, 100, 255, 0)
  46.     $game_screen.pictures[6].show("c2.png", 0, $p6x, 27, 100, 100, 255, 0)
  47.     $game_screen.pictures[7].show("c3.png", 0, $p7x, 72, 100, 100, 255, 0)
  48.     $game_screen.pictures[8].show("c3.png", 0, $p8x, 72, 100, 100, 255, 0)
  49.     $game_screen.pictures[9].show("c3.png", 0, $p9x, 72, 100, 100, 255, 0)
  50.     $game_screen.pictures[10].show("c4.png", 0, $p10x, 97, 100, 100, 255, 0)
  51.     $game_screen.pictures[11].show("c4.png", 0, $p11x, 97, 100, 100, 255, 0)
  52.     $game_screen.pictures[13].show("c5.png", 0, $p13x, 112, 100, 100, 255, 0)
  53.     $game_screen.pictures[14].show("c5.png", 0, $p14x, 112, 100, 100, 255, 0)
  54.     #$game_screen.pictures[].show(name,原点,x,y,放大x,放大y,透明度,合成)
  55.     if $p1x >= 640
  56.       $p1x = 640-3 * $p1xx + 1
  57.     end
  58.     if $p2x >= 640
  59.       $p2x = 640-3 * $p1xx + 1
  60.     end
  61.     if $p3x >= 640
  62.       $p3x = 640-3 * $p1xx + 1
  63.     end
  64.     if $p4x >= 640
  65.       $p4x = 640-3 * $p2xx + 1
  66.     end
  67.     if $p5x >= 640
  68.       $p5x = 640-3 * $p2xx + 1
  69.     end
  70.     if $p6x >= 640
  71.       $p6x = 640-3 * $p2xx + 1
  72.     end
  73.     if $p7x >= 640
  74.       $p7x = 640-3 * $p3xx + 1
  75.     end
  76.     if $p8x >= 640
  77.       $p8x = 640-3 * $p3xx + 1
  78.     end
  79.     if $p9x >= 640
  80.       $p9x = 640-3 * $p3xx + 1
  81.     end
  82.     if $p10x >= 640
  83.       $p10x = 640-3 * $p4xx + 1
  84.     end
  85.     if $p11x >= 640
  86.       $p11x = 640-3 * $p4xx + 1
  87.     end
  88.     if $p13x >= 640
  89.       $p13x = 640-3 * $p5xx + 1
  90.     end
  91.     if $p14x >= 640
  92.       $p14x = 640-3 * $p5xx + 1
  93.     end
  94.   end
  95. end

作者: cinderelmini    时间: 2013-6-21 18:04
这真的是XP用的?
怎么觉得函数名什么的有点奇怪……
如果没错的话~
Main前Insert~
然后在游戏中用事件调用脚本:
$a = Cloud.new
$a.reday
$a.start
试试看?





欢迎光临 Project1 (https://rpg.blue/) Powered by Discuz! X3.1