设为首页收藏本站|繁體中文

Project1

 找回密码
 注册会员
搜索
查看: 10271|回复: 30
打印 上一主题 下一主题

[RM脚本] 脚本以及工程预留帖

 关闭 [复制链接]

Lv1.梦旅人

查无此人

梦石
0
星屑
50
在线时间
9 小时
注册时间
2006-5-8
帖子
1399
跳转到指定楼层
1
发表于 2006-7-17 17:49:22 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式

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

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

x
7月17日更新
模仿FF7的制作群字幕
用事件做总觉得麻烦,现在提供一个已有的脚本(不是主站上那个)。动态效果不错。
来源  http://rpgcreative.free.fr/ (论坛里的,不知道能不能进去)
名字: - Final Fantasy VII opening Credits Script
  
#   使用方法:
#   调用场景:$scene = FFVII_Credits.new
#   脚本的后半部分就是自己设内容的,华文行楷是字体,其他的先看一遍效果,然后就知道怎么回事了。

  1. #  http://rpgcreative.free.fr/forum/viewtopic.php?p=50564#50564
  2. # - Final Fantasy VII opening Credits Script
  3. #  
  4. #   使用方法:
  5. #   调用场景:$scene = FFVII_Credits.new
  6. #   脚本的后半部分就是自己设内容的,华文行楷是字体,其他的先看一遍效果,然后就知道怎么回事了。
  7. #   除了最上面的出处,所有注释以及显示的汉字都是我加的........


  8.     class FFVII_Credits
  9.     def main
  10.     $data_system = load_data("Data/System.rxdata")
  11.     $game_system = Game_System.new
  12.     @Background = Sprite.new
  13. # 这个是背景图片,要放在pictures里#
  14.     @Background.bitmap = RPG::Cache.picture("001-Title01")
  15.     @Background.opacity = 255
  16.     @sprite1 = Window1.new
  17.     @sprite1.x =   120
  18.     @sprite1.y =   320
  19.     @sprite2 = Window2.new
  20.     @sprite2.x =   321
  21.     @sprite2.y = - 60
  22. # 这个是音乐,BGM里的.............#
  23.     Audio.bgm_play("Audio/BGM/" + "012-Theme01", 200, 100)
  24.     @sprite3 = Window3.new
  25.     @sprite3.x = - 200
  26.     @sprite3.y =   60
  27.     @sprite4 = Window4.new  
  28.     @sprite4.x =   20
  29.     @sprite4.y =   458
  30.     @sprite5 = Window5.new
  31.     @sprite5.x =   170
  32.     @sprite5.y = - 120
  33.     @sprite6 = Window6.new
  34.     @sprite6.x = - 120
  35.     @sprite6.y =   120
  36.     @sprite7 = Window7.new
  37.     @sprite7.x =   680
  38.     @sprite7.y =   110
  39.     @sprite8 = Window8.new
  40.     @sprite8.x =   450
  41.     @sprite8.y = - 90
  42.     @sprite9 = Window9.new
  43.     @sprite9.x = - 150
  44.     @sprite9.y =   400
  45.     @sprite10 = Window10.new
  46.     @sprite10.x =  30
  47.     @sprite10.y =  540
  48.     @sprite11 = Window11.new
  49.     @sprite11.x =  680
  50.     @sprite11.y =  90
  51.     @sprite12 = Window12.new
  52.     @sprite12.x =  460
  53.     @sprite12.y = - 90
  54.     @sprite13 = Window13.new
  55.     @sprite13.x =  - 142
  56.     @sprite13.y =   320
  57.     @sprite14 = Window14.new
  58.     @sprite14.x =   320
  59.     @sprite14.y = - 90
  60.     @Button = Window15.new
  61.     @Button.x = 220
  62.     @Button.y = 210
  63.     @Button.contents_opacity = 0
  64.     @Button.visible = false
  65.     Graphics.transition
  66.     loop do
  67.       Graphics.update
  68.       Input.update
  69.       update
  70.       if $scene != self
  71.         break
  72.       end
  73.     end
  74.     Graphics.freeze
  75.     @Background.dispose
  76.     @sprite1.dispose
  77.     @sprite2.dispose
  78.     @sprite3.dispose
  79.     @sprite4.dispose
  80.     @sprite5.dispose
  81.     @sprite6.dispose
  82.     @sprite7.dispose
  83.     @sprite8.dispose
  84.     @sprite9.dispose
  85.     @sprite10.dispose
  86.     @sprite11.dispose
  87.     @sprite12.dispose
  88.     @sprite13.dispose
  89.     @sprite14.dispose
  90.     @Button.dispose
  91.   end
  92.   def update
  93.     if @sprite1.x > 119
  94.        @sprite1.x += 2
  95.      end
  96.     if @sprite1.x > 319
  97.        @sprite1.x = 321
  98.      end
  99.     if @sprite1.x == 321
  100.        @sprite2.y += 2
  101.      end
  102.     if @sprite2.y > 298
  103.        @sprite2.y = 299
  104.      end
  105.     if @sprite2.y == 299 and
  106.        @sprite1.x == 321
  107.        @sprite1.contents_opacity -= 2
  108.        @sprite2.contents_opacity -= 2
  109.      end
  110.     if @sprite1.contents_opacity < 1
  111.        @sprite1.active = false
  112.        @sprite2.active = false
  113.        @sprite3.x += 1
  114.        @sprite4.y -= 2
  115.        if @sprite4.y < 40
  116.           @sprite4.y = 40
  117.        end
  118.      end
  119.      if @sprite3.x > 89
  120.         @sprite3.x = 90
  121.         @sprite3.contents_opacity -= 2
  122.         @sprite4.contents_opacity -= 2
  123.       end
  124.      if @sprite3.contents_opacity < 1
  125.         @sprite3.active = false
  126.         @sprite4.active = false
  127.         @sprite5.y += 1
  128.         @sprite6.x += 1
  129.         if @sprite5.y > 137 and
  130.            @sprite6.x > 137
  131.            @sprite5.y = 138
  132.            @sprite6.x = 138
  133.          end
  134.        end
  135.      if @sprite5.y == 138 and
  136.         @sprite6.x == 138
  137.         @sprite5.contents_opacity -= 2
  138.         @sprite6.contents_opacity -= 2
  139.       end
  140.      if @sprite5.contents_opacity < 1
  141.         @sprite7.x > 639
  142.         @sprite8.y < - 89
  143.         @sprite8.y += 1
  144.         @sprite7.x -= 1
  145.       end
  146.       if @sprite7.x < 461
  147.          @sprite7.x = 460
  148.          @sprite8.y = 130
  149.          @sprite7.contents_opacity -=2
  150.          @sprite8.contents_opacity -=2
  151.        end
  152.      if @sprite8.contents_opacity < 1
  153.         @sprite9.x += 1
  154.         @sprite10.y -= 1
  155.       end
  156.       if @sprite10.y < 381
  157.          @sprite10.y = 381
  158.          @sprite9.x = 10
  159.          @sprite9.contents_opacity -= 2
  160.          @sprite10.contents_opacity -= 2
  161.        end
  162.       if @sprite10.contents_opacity < 1
  163.         @sprite11.x > 639
  164.         @sprite12.y < - 89
  165.         @sprite12.y += 1
  166.         @sprite11.x -= 1
  167.       end
  168.       if @sprite11.x < 461
  169.          @sprite11.x = 460
  170.          @sprite12.y = 130
  171.          @sprite11.contents_opacity -=2
  172.          @sprite12.contents_opacity -=2
  173.        end
  174.            if @sprite12.contents_opacity < 1
  175.               @sprite13.x += 1
  176.               @sprite14.y += 1
  177.             end
  178.            if @sprite13.x > 300
  179.               @sprite13.x = 302
  180.               @sprite14.y = 341
  181.               @sprite13.contents_opacity -= 2
  182.               @sprite14.contents_opacity -= 2
  183.             end
  184.            if @sprite14.contents_opacity < 1
  185.               @Button.visible = true
  186.               @Button.contents_opacity +=1
  187.             end
  188.     if Input.trigger?(Input::C)
  189. ## 按决定键后回到标题画面##
  190.        $scene = Scene_Title.new
  191.      end
  192. end
  193. #==============================================
  194. # - Window_Text
  195. #==============================================
  196. class Your_Scene
  197.   
  198. def main

  199.     Graphics.freeze
  200.     @window1.dispose
  201.     @window2.dispose
  202.     @window3.dispose
  203.     @window4.dispose
  204.     @window5.dispose   
  205.     @window6.dispose   
  206.     @window7.dispose  
  207.     @window8.dispose
  208.     @window9.dispose
  209.     @window10.dispose
  210.   end
  211. end
  212. #==============================================
  213. # - Window Producer name text begins
  214. #==============================================

  215. class Window1 < Window_Base

  216.   def initialize
  217.     super(0, 0, 210,60)
  218.     self.contents = Bitmap.new(width - 32, height - 32)
  219.     self.contents.font.name = "华文行楷"
  220.     self.contents.font.size = 22
  221.     self.opacity = 0
  222.     self.contents.draw_text(0, 0, 110, 33, "66RPG")
  223.   end
  224. end
  225. #==============================================
  226. # - Window Producer Title Text Begins
  227. #==============================================

  228. class Window2 < Window_Base

  229.   def initialize
  230.     super(0, 0, 140,60)
  231.     self.contents = Bitmap.new(width - 32, height - 32)
  232.     self.contents.font.name = "华文行楷"
  233.     self.contents.font.size = 22
  234.     self.opacity = 0
  235.     self.contents.draw_text(0, 0, 133, 33, "伟大光荣的")
  236.   end
  237. end
  238. #==============================================
  239. # - Window Main Scripter Name text begins
  240. #==============================================

  241. class Window3 < Window_Base

  242.   def initialize
  243.     super(0, 0, 140,60)
  244.     self.contents = Bitmap.new(width - 32, height - 32)
  245.     self.contents.font.name = "华文行楷"
  246.     self.contents.font.size = 22
  247.     self.opacity = 0
  248.     self.contents.draw_text(0, 0, 133, 33, "九泪")
  249.   end
  250. end

  251. #==============================================
  252. # - Window Mian Scripter Title Text Begins
  253. #==============================================

  254. class Window4 < Window_Base

  255.   def initialize
  256.     super(0, 0, 290,60)
  257.     self.contents = Bitmap.new(width - 32, height - 32)
  258.     self.contents.font.name = "华文行楷"
  259.     self.contents.font.size = 22
  260.     self.opacity = 0
  261.     self.contents.draw_text(0, 0, 290, 33, "聪明漂亮的")
  262.   end
  263. end

  264. #==============================================
  265. # - Window Director Name Text Begins
  266. #==============================================

  267. class Window5 < Window_Base

  268.   def initialize
  269.     super(0, 0, 140,60)
  270.     self.contents = Bitmap.new(width - 32, height - 32)
  271.     self.contents.font.name = "华文行楷"
  272.     self.contents.font.size = 22
  273.     self.opacity = 0
  274.     self.contents.draw_text(0, 0, 133, 33, "某某")
  275.   end
  276. end

  277. #==============================================
  278. # - Window Director Name Title Begins
  279. #==============================================

  280. class Window6 < Window_Base

  281.   def initialize
  282.     super(0, 0, 140,60)
  283.     self.contents = Bitmap.new(width - 32, height - 32)
  284.     self.contents.font.name = "华文行楷"
  285.     self.contents.font.size = 22
  286.     self.opacity = 0
  287.     self.contents.draw_text(0, 0, 133, 33, "杀人眨眼的")
  288.   end
  289. end

  290. #==============================================
  291. # - Window Main Programmer Title Begins
  292. #==============================================

  293. class Window7 < Window_Base

  294.   def initialize
  295.     super(0, 0, 210,60)
  296.     self.contents = Bitmap.new(width - 32, height - 32)
  297.     self.contents.font.name = "华文行楷"
  298.     self.contents.font.size = 22
  299.     self.opacity = 0
  300.     self.contents.draw_text(0, 0, 210, 33, "世界杯冠军")
  301.   end
  302. end

  303. #==============================================
  304. # - Window Main Programmer Name Begins
  305. #==============================================

  306. class Window8 < Window_Base

  307.   def initialize
  308.     super(0, 0, 180,60)
  309.     self.contents = Bitmap.new(width - 32, height - 32)
  310.     self.contents.font.name = "华文行楷"
  311.     self.contents.font.size = 22
  312.     self.opacity = 0
  313.     self.contents.draw_text(0, 0, 178, 33, "阿根廷")
  314.   end
  315. end

  316. #==============================================
  317. # - Window Composer Title Begins
  318. #==============================================

  319. class Window9 < Window_Base

  320.   def initialize
  321.     super(0, 0, 240,60)
  322.     self.contents = Bitmap.new(width - 32, height - 32)
  323.     self.contents.font.name = "宋体"
  324.     self.contents.font.size = 22
  325.     self.opacity = 0
  326.     self.contents.draw_text(0, 0, 233, 33, "齐达内^0^")
  327.   end
  328. end

  329. #==============================================
  330. # - Window Composer name Begins
  331. #==============================================

  332. class Window10 < Window_Base

  333.   def initialize
  334.     super(0, 0, 240,60)
  335.     self.contents = Bitmap.new(width - 32, height - 32)
  336.     self.contents.font.name = "华文行楷"
  337.     self.contents.font.size = 22
  338.     self.opacity = 0
  339.     self.contents.draw_text(0, 0, 233, 33, "我的偶像")
  340.   end
  341. end

  342. #==============================================
  343. # - Window Battle Script designer Title Begins
  344. #==============================================

  345. class Window11 < Window_Base

  346.   def initialize
  347.     super(0, 0, 240,240)
  348.     self.contents = Bitmap.new(width - 32, height - 32)
  349.     self.contents.font.name = "华文行楷"
  350.     self.contents.font.size = 22
  351.     self.opacity = 0
  352.     self.contents.draw_text(0, 0, 133, 33, "伟大的阿根")
  353.     self.contents.draw_text(0, 0, 143, 63, "廷的左后卫")
  354.   end
  355. end

  356. #==============================================
  357. # - Window Battle Script Designer Name Begins
  358. #==============================================

  359. class Window12 < Window_Base

  360.   def initialize
  361.     super(0, 0, 240,60)
  362.     self.contents = Bitmap.new(width - 32, height - 32)
  363.     self.contents.font.name = "华文行楷"
  364.     self.contents.font.size = 22
  365.     self.opacity = 0
  366.     self.contents.draw_text(0, 0, 233, 33, "他不是one!")
  367.   end
  368. end
  369. #==============================================
  370. # - Window Special thanks Begins
  371. #==============================================

  372. class Window13 < Window_Base

  373.   def initialize
  374.     super(0, 0, 340,240)
  375.     self.contents = Bitmap.new(width - 32, height - 32)
  376.     self.contents.font.name = "华文行楷"
  377.     self.contents.font.size = 22
  378.     self.opacity = 0
  379.     self.contents.draw_text(0, 0, 333, 33, "莎士比亚说")
  380.     self.contents.draw_text(0, 20, 333, 33, "liao")
  381.   end
  382. end

  383. #==============================================
  384. # - Window Special Thanks Names begins
  385. #==============================================

  386. class Window14 < Window_Base

  387.   def initialize
  388.     super(0, 0, 240,60)
  389.     self.contents = Bitmap.new(width - 32, height - 32)
  390.     self.contents.font.name = "华文行楷"
  391.     self.contents.font.size = 22
  392.     self.opacity = 0
  393.     self.contents.draw_text(0, 0, 133, 33, "阿根廷!!")  
  394.   end
  395. end

  396. #==============================================
  397. # - This Creates the "Please Press Start" Screen -
  398. #  针对头上的话提出抗议,明明是按下去就回标题画面了,还"Start"个头啊=。=
  399. #  如果放在新游戏开始那里,先这个下,然后到新地图还说得过去....(跑题liao)
  400. #==============================================

  401. class Window15 < Window_Base

  402.   def initialize
  403.     super(0, 0, 440,360)
  404.     self.contents = Bitmap.new(width - 32, height - 32)
  405.     self.contents.font.name = "华文行楷"
  406.     self.contents.font.size = 28
  407.     self.opacity = 0
  408.     self.contents.draw_text(0, 0, 433, 33, "妈妈咪的 ")
  409.     self.contents.font.size = 24
  410.     self.contents.draw_text(0, 20, 433, 33, "想不出话了")
  411.     self.contents.draw_text(0, 40, 433, 33, "就这样了!!")
  412.   end
  413. end
  414. end
复制代码


KRKR + NS 学习中..........

Lv1.梦旅人

查无此人

梦石
0
星屑
50
在线时间
9 小时
注册时间
2006-5-8
帖子
1399
2
 楼主| 发表于 2006-7-17 17:49:22 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式

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

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

x
7月17日更新
模仿FF7的制作群字幕
用事件做总觉得麻烦,现在提供一个已有的脚本(不是主站上那个)。动态效果不错。
来源  http://rpgcreative.free.fr/ (论坛里的,不知道能不能进去)
名字: - Final Fantasy VII opening Credits Script
  
#   使用方法:
#   调用场景:$scene = FFVII_Credits.new
#   脚本的后半部分就是自己设内容的,华文行楷是字体,其他的先看一遍效果,然后就知道怎么回事了。

  1. #  http://rpgcreative.free.fr/forum/viewtopic.php?p=50564#50564
  2. # - Final Fantasy VII opening Credits Script
  3. #  
  4. #   使用方法:
  5. #   调用场景:$scene = FFVII_Credits.new
  6. #   脚本的后半部分就是自己设内容的,华文行楷是字体,其他的先看一遍效果,然后就知道怎么回事了。
  7. #   除了最上面的出处,所有注释以及显示的汉字都是我加的........


  8.     class FFVII_Credits
  9.     def main
  10.     $data_system = load_data("Data/System.rxdata")
  11.     $game_system = Game_System.new
  12.     @Background = Sprite.new
  13. # 这个是背景图片,要放在pictures里#
  14.     @Background.bitmap = RPG::Cache.picture("001-Title01")
  15.     @Background.opacity = 255
  16.     @sprite1 = Window1.new
  17.     @sprite1.x =   120
  18.     @sprite1.y =   320
  19.     @sprite2 = Window2.new
  20.     @sprite2.x =   321
  21.     @sprite2.y = - 60
  22. # 这个是音乐,BGM里的.............#
  23.     Audio.bgm_play("Audio/BGM/" + "012-Theme01", 200, 100)
  24.     @sprite3 = Window3.new
  25.     @sprite3.x = - 200
  26.     @sprite3.y =   60
  27.     @sprite4 = Window4.new  
  28.     @sprite4.x =   20
  29.     @sprite4.y =   458
  30.     @sprite5 = Window5.new
  31.     @sprite5.x =   170
  32.     @sprite5.y = - 120
  33.     @sprite6 = Window6.new
  34.     @sprite6.x = - 120
  35.     @sprite6.y =   120
  36.     @sprite7 = Window7.new
  37.     @sprite7.x =   680
  38.     @sprite7.y =   110
  39.     @sprite8 = Window8.new
  40.     @sprite8.x =   450
  41.     @sprite8.y = - 90
  42.     @sprite9 = Window9.new
  43.     @sprite9.x = - 150
  44.     @sprite9.y =   400
  45.     @sprite10 = Window10.new
  46.     @sprite10.x =  30
  47.     @sprite10.y =  540
  48.     @sprite11 = Window11.new
  49.     @sprite11.x =  680
  50.     @sprite11.y =  90
  51.     @sprite12 = Window12.new
  52.     @sprite12.x =  460
  53.     @sprite12.y = - 90
  54.     @sprite13 = Window13.new
  55.     @sprite13.x =  - 142
  56.     @sprite13.y =   320
  57.     @sprite14 = Window14.new
  58.     @sprite14.x =   320
  59.     @sprite14.y = - 90
  60.     @Button = Window15.new
  61.     @Button.x = 220
  62.     @Button.y = 210
  63.     @Button.contents_opacity = 0
  64.     @Button.visible = false
  65.     Graphics.transition
  66.     loop do
  67.       Graphics.update
  68.       Input.update
  69.       update
  70.       if $scene != self
  71.         break
  72.       end
  73.     end
  74.     Graphics.freeze
  75.     @Background.dispose
  76.     @sprite1.dispose
  77.     @sprite2.dispose
  78.     @sprite3.dispose
  79.     @sprite4.dispose
  80.     @sprite5.dispose
  81.     @sprite6.dispose
  82.     @sprite7.dispose
  83.     @sprite8.dispose
  84.     @sprite9.dispose
  85.     @sprite10.dispose
  86.     @sprite11.dispose
  87.     @sprite12.dispose
  88.     @sprite13.dispose
  89.     @sprite14.dispose
  90.     @Button.dispose
  91.   end
  92.   def update
  93.     if @sprite1.x > 119
  94.        @sprite1.x += 2
  95.      end
  96.     if @sprite1.x > 319
  97.        @sprite1.x = 321
  98.      end
  99.     if @sprite1.x == 321
  100.        @sprite2.y += 2
  101.      end
  102.     if @sprite2.y > 298
  103.        @sprite2.y = 299
  104.      end
  105.     if @sprite2.y == 299 and
  106.        @sprite1.x == 321
  107.        @sprite1.contents_opacity -= 2
  108.        @sprite2.contents_opacity -= 2
  109.      end
  110.     if @sprite1.contents_opacity < 1
  111.        @sprite1.active = false
  112.        @sprite2.active = false
  113.        @sprite3.x += 1
  114.        @sprite4.y -= 2
  115.        if @sprite4.y < 40
  116.           @sprite4.y = 40
  117.        end
  118.      end
  119.      if @sprite3.x > 89
  120.         @sprite3.x = 90
  121.         @sprite3.contents_opacity -= 2
  122.         @sprite4.contents_opacity -= 2
  123.       end
  124.      if @sprite3.contents_opacity < 1
  125.         @sprite3.active = false
  126.         @sprite4.active = false
  127.         @sprite5.y += 1
  128.         @sprite6.x += 1
  129.         if @sprite5.y > 137 and
  130.            @sprite6.x > 137
  131.            @sprite5.y = 138
  132.            @sprite6.x = 138
  133.          end
  134.        end
  135.      if @sprite5.y == 138 and
  136.         @sprite6.x == 138
  137.         @sprite5.contents_opacity -= 2
  138.         @sprite6.contents_opacity -= 2
  139.       end
  140.      if @sprite5.contents_opacity < 1
  141.         @sprite7.x > 639
  142.         @sprite8.y < - 89
  143.         @sprite8.y += 1
  144.         @sprite7.x -= 1
  145.       end
  146.       if @sprite7.x < 461
  147.          @sprite7.x = 460
  148.          @sprite8.y = 130
  149.          @sprite7.contents_opacity -=2
  150.          @sprite8.contents_opacity -=2
  151.        end
  152.      if @sprite8.contents_opacity < 1
  153.         @sprite9.x += 1
  154.         @sprite10.y -= 1
  155.       end
  156.       if @sprite10.y < 381
  157.          @sprite10.y = 381
  158.          @sprite9.x = 10
  159.          @sprite9.contents_opacity -= 2
  160.          @sprite10.contents_opacity -= 2
  161.        end
  162.       if @sprite10.contents_opacity < 1
  163.         @sprite11.x > 639
  164.         @sprite12.y < - 89
  165.         @sprite12.y += 1
  166.         @sprite11.x -= 1
  167.       end
  168.       if @sprite11.x < 461
  169.          @sprite11.x = 460
  170.          @sprite12.y = 130
  171.          @sprite11.contents_opacity -=2
  172.          @sprite12.contents_opacity -=2
  173.        end
  174.            if @sprite12.contents_opacity < 1
  175.               @sprite13.x += 1
  176.               @sprite14.y += 1
  177.             end
  178.            if @sprite13.x > 300
  179.               @sprite13.x = 302
  180.               @sprite14.y = 341
  181.               @sprite13.contents_opacity -= 2
  182.               @sprite14.contents_opacity -= 2
  183.             end
  184.            if @sprite14.contents_opacity < 1
  185.               @Button.visible = true
  186.               @Button.contents_opacity +=1
  187.             end
  188.     if Input.trigger?(Input::C)
  189. ## 按决定键后回到标题画面##
  190.        $scene = Scene_Title.new
  191.      end
  192. end
  193. #==============================================
  194. # - Window_Text
  195. #==============================================
  196. class Your_Scene
  197.   
  198. def main

  199.     Graphics.freeze
  200.     @window1.dispose
  201.     @window2.dispose
  202.     @window3.dispose
  203.     @window4.dispose
  204.     @window5.dispose   
  205.     @window6.dispose   
  206.     @window7.dispose  
  207.     @window8.dispose
  208.     @window9.dispose
  209.     @window10.dispose
  210.   end
  211. end
  212. #==============================================
  213. # - Window Producer name text begins
  214. #==============================================

  215. class Window1 < Window_Base

  216.   def initialize
  217.     super(0, 0, 210,60)
  218.     self.contents = Bitmap.new(width - 32, height - 32)
  219.     self.contents.font.name = "华文行楷"
  220.     self.contents.font.size = 22
  221.     self.opacity = 0
  222.     self.contents.draw_text(0, 0, 110, 33, "66RPG")
  223.   end
  224. end
  225. #==============================================
  226. # - Window Producer Title Text Begins
  227. #==============================================

  228. class Window2 < Window_Base

  229.   def initialize
  230.     super(0, 0, 140,60)
  231.     self.contents = Bitmap.new(width - 32, height - 32)
  232.     self.contents.font.name = "华文行楷"
  233.     self.contents.font.size = 22
  234.     self.opacity = 0
  235.     self.contents.draw_text(0, 0, 133, 33, "伟大光荣的")
  236.   end
  237. end
  238. #==============================================
  239. # - Window Main Scripter Name text begins
  240. #==============================================

  241. class Window3 < Window_Base

  242.   def initialize
  243.     super(0, 0, 140,60)
  244.     self.contents = Bitmap.new(width - 32, height - 32)
  245.     self.contents.font.name = "华文行楷"
  246.     self.contents.font.size = 22
  247.     self.opacity = 0
  248.     self.contents.draw_text(0, 0, 133, 33, "九泪")
  249.   end
  250. end

  251. #==============================================
  252. # - Window Mian Scripter Title Text Begins
  253. #==============================================

  254. class Window4 < Window_Base

  255.   def initialize
  256.     super(0, 0, 290,60)
  257.     self.contents = Bitmap.new(width - 32, height - 32)
  258.     self.contents.font.name = "华文行楷"
  259.     self.contents.font.size = 22
  260.     self.opacity = 0
  261.     self.contents.draw_text(0, 0, 290, 33, "聪明漂亮的")
  262.   end
  263. end

  264. #==============================================
  265. # - Window Director Name Text Begins
  266. #==============================================

  267. class Window5 < Window_Base

  268.   def initialize
  269.     super(0, 0, 140,60)
  270.     self.contents = Bitmap.new(width - 32, height - 32)
  271.     self.contents.font.name = "华文行楷"
  272.     self.contents.font.size = 22
  273.     self.opacity = 0
  274.     self.contents.draw_text(0, 0, 133, 33, "某某")
  275.   end
  276. end

  277. #==============================================
  278. # - Window Director Name Title Begins
  279. #==============================================

  280. class Window6 < Window_Base

  281.   def initialize
  282.     super(0, 0, 140,60)
  283.     self.contents = Bitmap.new(width - 32, height - 32)
  284.     self.contents.font.name = "华文行楷"
  285.     self.contents.font.size = 22
  286.     self.opacity = 0
  287.     self.contents.draw_text(0, 0, 133, 33, "杀人眨眼的")
  288.   end
  289. end

  290. #==============================================
  291. # - Window Main Programmer Title Begins
  292. #==============================================

  293. class Window7 < Window_Base

  294.   def initialize
  295.     super(0, 0, 210,60)
  296.     self.contents = Bitmap.new(width - 32, height - 32)
  297.     self.contents.font.name = "华文行楷"
  298.     self.contents.font.size = 22
  299.     self.opacity = 0
  300.     self.contents.draw_text(0, 0, 210, 33, "世界杯冠军")
  301.   end
  302. end

  303. #==============================================
  304. # - Window Main Programmer Name Begins
  305. #==============================================

  306. class Window8 < Window_Base

  307.   def initialize
  308.     super(0, 0, 180,60)
  309.     self.contents = Bitmap.new(width - 32, height - 32)
  310.     self.contents.font.name = "华文行楷"
  311.     self.contents.font.size = 22
  312.     self.opacity = 0
  313.     self.contents.draw_text(0, 0, 178, 33, "阿根廷")
  314.   end
  315. end

  316. #==============================================
  317. # - Window Composer Title Begins
  318. #==============================================

  319. class Window9 < Window_Base

  320.   def initialize
  321.     super(0, 0, 240,60)
  322.     self.contents = Bitmap.new(width - 32, height - 32)
  323.     self.contents.font.name = "宋体"
  324.     self.contents.font.size = 22
  325.     self.opacity = 0
  326.     self.contents.draw_text(0, 0, 233, 33, "齐达内^0^")
  327.   end
  328. end

  329. #==============================================
  330. # - Window Composer name Begins
  331. #==============================================

  332. class Window10 < Window_Base

  333.   def initialize
  334.     super(0, 0, 240,60)
  335.     self.contents = Bitmap.new(width - 32, height - 32)
  336.     self.contents.font.name = "华文行楷"
  337.     self.contents.font.size = 22
  338.     self.opacity = 0
  339.     self.contents.draw_text(0, 0, 233, 33, "我的偶像")
  340.   end
  341. end

  342. #==============================================
  343. # - Window Battle Script designer Title Begins
  344. #==============================================

  345. class Window11 < Window_Base

  346.   def initialize
  347.     super(0, 0, 240,240)
  348.     self.contents = Bitmap.new(width - 32, height - 32)
  349.     self.contents.font.name = "华文行楷"
  350.     self.contents.font.size = 22
  351.     self.opacity = 0
  352.     self.contents.draw_text(0, 0, 133, 33, "伟大的阿根")
  353.     self.contents.draw_text(0, 0, 143, 63, "廷的左后卫")
  354.   end
  355. end

  356. #==============================================
  357. # - Window Battle Script Designer Name Begins
  358. #==============================================

  359. class Window12 < Window_Base

  360.   def initialize
  361.     super(0, 0, 240,60)
  362.     self.contents = Bitmap.new(width - 32, height - 32)
  363.     self.contents.font.name = "华文行楷"
  364.     self.contents.font.size = 22
  365.     self.opacity = 0
  366.     self.contents.draw_text(0, 0, 233, 33, "他不是one!")
  367.   end
  368. end
  369. #==============================================
  370. # - Window Special thanks Begins
  371. #==============================================

  372. class Window13 < Window_Base

  373.   def initialize
  374.     super(0, 0, 340,240)
  375.     self.contents = Bitmap.new(width - 32, height - 32)
  376.     self.contents.font.name = "华文行楷"
  377.     self.contents.font.size = 22
  378.     self.opacity = 0
  379.     self.contents.draw_text(0, 0, 333, 33, "莎士比亚说")
  380.     self.contents.draw_text(0, 20, 333, 33, "liao")
  381.   end
  382. end

  383. #==============================================
  384. # - Window Special Thanks Names begins
  385. #==============================================

  386. class Window14 < Window_Base

  387.   def initialize
  388.     super(0, 0, 240,60)
  389.     self.contents = Bitmap.new(width - 32, height - 32)
  390.     self.contents.font.name = "华文行楷"
  391.     self.contents.font.size = 22
  392.     self.opacity = 0
  393.     self.contents.draw_text(0, 0, 133, 33, "阿根廷!!")  
  394.   end
  395. end

  396. #==============================================
  397. # - This Creates the "Please Press Start" Screen -
  398. #  针对头上的话提出抗议,明明是按下去就回标题画面了,还"Start"个头啊=。=
  399. #  如果放在新游戏开始那里,先这个下,然后到新地图还说得过去....(跑题liao)
  400. #==============================================

  401. class Window15 < Window_Base

  402.   def initialize
  403.     super(0, 0, 440,360)
  404.     self.contents = Bitmap.new(width - 32, height - 32)
  405.     self.contents.font.name = "华文行楷"
  406.     self.contents.font.size = 28
  407.     self.opacity = 0
  408.     self.contents.draw_text(0, 0, 433, 33, "妈妈咪的 ")
  409.     self.contents.font.size = 24
  410.     self.contents.draw_text(0, 20, 433, 33, "想不出话了")
  411.     self.contents.draw_text(0, 40, 433, 33, "就这样了!!")
  412.   end
  413. end
  414. end
复制代码


KRKR + NS 学习中..........

Lv1.梦旅人

查无此人

梦石
0
星屑
50
在线时间
9 小时
注册时间
2006-5-8
帖子
1399
3
 楼主| 发表于 2006-7-17 17:49:44 | 只看该作者

7月17日更新
14种天气效果
地址同上
作者: ccoa
#with ideas by ScriptKitty and Mr.DJ
介绍:
# Weather Types:类型
# 1 - rain  雨
# 2 - storm 风
# 3 - snow 雪
# 4 - hail  冰雹
# 5 - rain with thunder and lightning  雷雨
# 6 - falling leaves (autumn) 秋天的落叶
# 7 - blowing leaves (autumn)         秋风扫落叶
# 8 - swirling leaves (autumn) 旋转的树叶
# 9 - falling leaves (green) 绿绿的落叶
# 10 - cherry blossom (sakura) petals 樱花飞舞
# 11 - rose petals 玫瑰花瓣雨
# 12 - feathers 羽毛
# 13 - blood rain 血雨
# 14 - sparkles 闪烁
# 15 - user defined 自己定义
其他自己看脚本前面注释
  1. #===========================
  2. # ccoa's weather script
  3. # with ideas by ScriptKitty and Mr.DJ

  4. #===========================
  5. # Weather Types:类型
  6. # 1 - rain  雨
  7. # 2 - storm 风
  8. # 3 - snow 雪
  9. # 4 - hail  冰雹
  10. # 5 - rain with thunder and lightning  雷雨
  11. # 6 - falling leaves (autumn) 秋天的落叶
  12. # 7 - blowing leaves (autumn)         秋风扫落叶
  13. # 8 - swirling leaves (autumn) 旋转的树叶
  14. # 9 - falling leaves (green) 绿绿的落叶
  15. # 10 - cherry blossom (sakura) petals 樱花飞舞
  16. # 11 - rose petals 玫瑰花瓣雨
  17. # 12 - feathers 羽毛
  18. # 13 - blood rain 血雨
  19. # 14 - sparkles 闪烁
  20. # 15 - user defined 自己定义
  21. #
  22. # Weather Power:  强度 0-40  0为无天气
  23. # An integer from 0-40. 0 = no weather, 40 = 400 sprites
  24. #
  25. # Usage:使用方法
  26. # Create a call script with the following:
  27. # 调用这个脚本
  28. # $game_screen.weather(type, power, hue)
  29. # 比如:$game_screen.weather(14, 35, 0)
  30. #
  31. # Usage of user-defined weather:
  32. # Look at the following globals:
  33. # 自定义天气看下面的

  34. $WEATHER_UPDATE = false
  35. # the $WEATHER_IMAGES array has changed, please update天气图象改变请改为true
  36. $WEATHER_IMAGES = []
  37. # the array of picture names to use用到的图片名字,默认无,所以上面不用刷新(他不是小方块!)
  38. $WEATHER_X = 0
  39. # the number of pixels the image should move horizontally (positive = right, negative = left)水平移动,正为右,负为左
  40. $WEATHER_Y = 0
  41. # the number of pizels the image should move vertically (positive = down, negative = up)垂直运动,正为下,负为上
  42. $WEATHER_FADE = 0
  43. # how much the image should fade each update (0 = no fade, 255 = fade instantly)淡出淡入,0为无,255为马上
  44. $WEATHER_ANIMATED = false
  45. # whether or not the image should cycle through all the images是否环绕?

  46. module RPG
  47. class Weather
  48. def initialize(viewport = nil)
  49. @type = 0
  50. @max = 0
  51. @ox = 0
  52. @oy = 0
  53. @count = 0
  54. @current_pose = []
  55. @info = []
  56. @countarray = []

  57. make_bitmaps

  58. # **** ccoa ****
  59. for i in 1..500
  60. sprite = Sprite.new(viewport)
  61. sprite.z = 1000
  62. sprite.visible = false
  63. sprite.opacity = 0
  64. @sprites.push(sprite)
  65. @current_pose.push(0)
  66. @info.push(rand(50))
  67. @countarray.push(rand(15))
  68. end
  69. end

  70. def dispose
  71. for sprite in @sprites
  72. sprite.dispose
  73. end
  74. @rain_bitmap.dispose
  75. @storm_bitmap.dispose
  76. @snow_bitmap.dispose
  77. @hail_bitmap.dispose
  78. @petal_bitmap.dispose
  79. @blood_rain_bitmap.dispose
  80. for image in @autumn_leaf_bitmaps
  81. image.dispose
  82. end
  83. for image in @green_leaf_bitmaps
  84. image.dispose
  85. end
  86. for image in @rose_bitmaps
  87. image.dispose
  88. end
  89. for image in @feather_bitmaps
  90. image.dispose
  91. end
  92. for image in @sparkle_bitmaps
  93. image.dispose
  94. end
  95. for image in @user_bitmaps
  96. image.dispose
  97. end
  98. $WEATHER_UPDATE = true
  99. end

  100. def type=(type)
  101. return if @type == type
  102. @type = type
  103. case @type
  104. when 1 # rain
  105. bitmap = @rain_bitmap
  106. when 2 # storm
  107. bitmap = @storm_bitmap
  108. when 3 # snow
  109. bitmap = @snow_bitmap
  110. when 4 # hail
  111. bitmap = @hail_bitmap
  112. when 5 # rain w/ thunder and lightning
  113. bitmap = @rain_bitmap
  114. @thunder = true
  115. when 6 # falling autumn leaves
  116. bitmap = @autumn_leaf_bitmaps[0]
  117. when 7 # blowing autumn leaves
  118. bitmap = @autumn_leaf_bitmaps[0]
  119. when 8 # swirling autumn leaves
  120. bitmap = @autumn_leaf_bitmaps[0]
  121. when 9 # falling green leaves
  122. bitmap = @green_leaf_bitmaps[0]
  123. when 10 # sakura petals
  124. bitmap = @petal_bitmap
  125. when 11 # rose petals
  126. bitmap = @rose_bitmaps[0]
  127. when 12 # feathers
  128. bitmap = @feather_bitmaps[0]
  129. when 13 # blood rain
  130. bitmap = @blood_rain_bitmap
  131. when 14 # sparkles
  132. bitmap = @sparkle_bitmaps[0]
  133. when 15 # user-defined
  134. bitmap = @user_bitmaps[rand(@user_bitmaps.size)]
  135. else
  136. bitmap = nil
  137. end
  138. if @type != 5
  139. @thunder = false
  140. end
  141. # **** ccoa ****
  142. for i in 1..500
  143. sprite = @sprites[i]
  144. if sprite != nil
  145. sprite.visible = (i <= @max)
  146. sprite.bitmap = bitmap
  147. end
  148. end
  149. end

  150. def ox=(ox)
  151. return if @ox == ox;
  152. @ox = ox
  153. for sprite in @sprites
  154. sprite.ox = @ox
  155. end
  156. end

  157. def oy=(oy)
  158. return if @oy == oy;
  159. @oy = oy
  160. for sprite in @sprites
  161. sprite.oy = @oy
  162. end
  163. end

  164. def max=(max)
  165. return if @max == max;
  166. # **** ccoa ****
  167. @max = [[max, 0].max, 500].min
  168. for i in 1..500
  169. sprite = @sprites[i]
  170. if sprite != nil
  171. sprite.visible = (i <= @max)
  172. end
  173. end
  174. end

  175. def update
  176. return if @type == 0
  177. for i in 1..@max
  178. sprite = @sprites[i]
  179. if sprite == nil
  180. break
  181. end
  182. if @type == 1 or @type == 5 or @type == 13 # rain
  183. sprite.x -= 2
  184. sprite.y += 16
  185. sprite.opacity -= 8
  186. if @thunder and (rand(8000 - @max) == 0)
  187. $game_screen.start_flash(Color.new(255, 255, 255, 255), 5)
  188. Audio.se_play("Audio/SE/061-Thunderclap01")
  189. end
  190. end
  191. if @type == 2 # storm
  192. sprite.x -= 8
  193. sprite.y += 16
  194. sprite.opacity -= 12
  195. end
  196. if @type == 3 # snow
  197. sprite.x -= 2
  198. sprite.y += 8
  199. sprite.opacity -= 8
  200. end
  201. if @type == 4 # hail
  202. sprite.x -= 1
  203. sprite.y += 18
  204. sprite.opacity -= 15
  205. end
  206. if @type == 6 # falling autumn leaves
  207. @count = rand(20)
  208. if @count == 0
  209. sprite.bitmap = @autumn_leaf_bitmaps[@current_pose[i]]
  210. @current_pose[i] = (@current_pose[i] + 1) % @autumn_leaf_bitmaps.size
  211. end
  212. sprite.x -= 1
  213. sprite.y += 1
  214. end
  215. if @type == 7 # blowing autumn leaves
  216. @count = rand(20)
  217. if @count == 0
  218. sprite.bitmap = @autumn_leaf_bitmaps[@current_pose[i]]
  219. @current_pose[i] = (@current_pose[i] + 1) % @autumn_leaf_bitmaps.size
  220. end
  221. sprite.x -= 10
  222. sprite.y += (rand(4) - 2)
  223. end
  224. if @type == 8 # swirling autumn leaves
  225. @count = rand(20)
  226. if @count == 0
  227. sprite.bitmap = @autumn_leaf_bitmaps[@current_pose[i]]
  228. @current_pose[i] = (@current_pose[i] + 1) % @autumn_leaf_bitmaps.size
  229. end
  230. if @info[i] != 0
  231. if @info[i] >= 1 and @info[i] <= 10
  232. sprite.x -= 3
  233. sprite.y -= 1
  234. elsif @info[i] >= 11 and @info[i] <= 16
  235. sprite.x -= 1
  236. sprite.y -= 2
  237. elsif @info[i] >= 17 and @info[i] <= 20
  238. sprite.y -= 3
  239. elsif @info[i] >= 21 and @info[i] <= 30
  240. sprite.y -= 2
  241. sprite.x += 1
  242. elsif @info[i] >= 31 and @info[i] <= 36
  243. sprite.y -= 1
  244. sprite.x += 3
  245. elsif @info[i] >= 37 and @info[i] <= 40
  246. sprite.x += 5
  247. elsif @info[i] >= 41 and @info[i] <= 46
  248. sprite.y += 1
  249. sprite.x += 3
  250. elsif @info[i] >= 47 and @info[i] <= 58
  251. sprite.y += 2
  252. sprite.x += 1
  253. elsif @info[i] >= 59 and @info[i] <= 64
  254. sprite.y += 3
  255. elsif @info[i] >= 65 and @info[i] <= 70
  256. sprite.x -= 1
  257. sprite.y += 2
  258. elsif @info[i] >= 71 and @info[i] <= 81
  259. sprite.x -= 3
  260. sprite.y += 1
  261. elsif @info[i] >= 82 and @info[i] <= 87
  262. sprite.x -= 5
  263. end
  264. @info[i] = (@info[i] + 1) % 88
  265. else
  266. if rand(200) == 0
  267. @info[i] = 1
  268. end
  269. sprite.x -= 5
  270. sprite.y += 1
  271. end
  272. end
  273. if @type == 9 # falling green leaves
  274. if @countarray[i] == 0
  275. @current_pose[i] = (@current_pose[i] + 1) % @green_leaf_bitmaps.size
  276. sprite.bitmap = @green_leaf_bitmaps[@current_pose[i]]
  277. @countarray[i] = rand(15)
  278. end
  279. @countarray[i] = (@countarray[i] + 1) % 15
  280. sprite.y += 1
  281. end
  282. if @type == 10 # sakura petals
  283. if @info[i] < 25
  284. sprite.x -= 1
  285. else
  286. sprite.x += 1
  287. end
  288. @info[i] = (@info[i] + 1) % 50
  289. sprite.y += 1
  290. end
  291. if @type == 11 # rose petals
  292. @count = rand(20)
  293. if @count == 0
  294. sprite.bitmap = @rose_bitmaps[@current_pose[i]]
  295. @current_pose[i] = (@current_pose[i] + 1) % @rose_bitmaps.size
  296. end
  297. if @info[i] % 2 == 0
  298. if @info[i] < 10
  299. sprite.x -= 1
  300. else
  301. sprite.x += 1
  302. end
  303. end
  304. sprite.y += 1
  305. end
  306. if @type == 12 # feathers
  307. if @countarray[i] == 0
  308. @current_pose[i] = (@current_pose[i] + 1) % @feather_bitmaps.size
  309. sprite.bitmap = @feather_bitmaps[@current_pose[i]]
  310. end
  311. @countarray[i] = (@countarray[i] + 1) % 15
  312. if rand(100) == 0
  313. sprite.x -= 1
  314. end
  315. if rand(100) == 0
  316. sprite.y -= 1
  317. end
  318. if @info[i] < 50
  319. if rand(2) == 0
  320. sprite.x -= 1
  321. else
  322. sprite.y -= 1
  323. end
  324. else
  325. if rand(2) == 0
  326. sprite.x += 1
  327. else
  328. sprite.y += 1
  329. end
  330. end
  331. @info[i] = (@info[i] + 1) % 100
  332. end
  333. if @type == 14 # sparkles
  334. if @countarray[i] == 0
  335. @current_pose[i] = (@current_pose[i] + 1) % @sparkle_bitmaps.size
  336. sprite.bitmap = @sparkle_bitmaps[@current_pose[i]]
  337. end
  338. @countarray[i] = (@countarray[i] + 1) % 15
  339. sprite.y += 1
  340. sprite.opacity -= 1
  341. end
  342. if @type == 15 # user-defined
  343. if $WEATHER_UPDATE
  344. update_user_defined
  345. $WEATHER_UPDATE = false
  346. end
  347. if $WEATHER_ANIMATED and @countarray[i] == 0
  348. @current_pose[i] = (@current_pose[i] + 1) % @user_bitmaps.size
  349. sprite.bitmap = @user_bitmaps[@current_pose[i]]
  350. end
  351. @countarray[i] = (@countarray[i] + 1) % 15
  352. sprite.x += $WEATHER_X
  353. sprite.y += $WEATHER_Y
  354. sprite.opacity -= $WEATHER_FADE
  355. end

  356. x = sprite.x - @ox
  357. y = sprite.y - @oy
  358. if sprite.opacity < 64 or x < -50 or x > 750 or y < -300 or y > 500
  359. sprite.x = rand(800) - 50 + @ox
  360. sprite.y = rand(800) - 200 + @oy
  361. sprite.opacity = 255
  362. end
  363. end
  364. end

  365. def make_bitmaps
  366. color1 = Color.new(255, 255, 255, 255)
  367. color2 = Color.new(255, 255, 255, 128)
  368. @rain_bitmap = Bitmap.new(7, 56)
  369. for i in 0..6
  370. @rain_bitmap.fill_rect(6-i, i*8, 1, 8, color1)
  371. end
  372. @storm_bitmap = Bitmap.new(34, 64)
  373. for i in 0..31
  374. @storm_bitmap.fill_rect(33-i, i*2, 1, 2, color2)
  375. @storm_bitmap.fill_rect(32-i, i*2, 1, 2, color1)
  376. @storm_bitmap.fill_rect(31-i, i*2, 1, 2, color2)
  377. end
  378. @snow_bitmap = Bitmap.new(6, 6)
  379. @snow_bitmap.fill_rect(0, 1, 6, 4, color2)
  380. @snow_bitmap.fill_rect(1, 0, 4, 6, color2)
  381. @snow_bitmap.fill_rect(1, 2, 4, 2, color1)
  382. @snow_bitmap.fill_rect(2, 1, 2, 4, color1)
  383. @sprites = []

  384. blueGrey = Color.new(215, 227, 227, 150)
  385. grey = Color.new(214, 217, 217, 150)
  386. lightGrey = Color.new(233, 233, 233, 250)
  387. lightBlue = Color.new(222, 239, 243, 250)
  388. @hail_bitmap = Bitmap.new(4, 4)
  389. @hail_bitmap.fill_rect(1, 0, 2, 1, blueGrey)
  390. @hail_bitmap.fill_rect(0, 1, 1, 2, blueGrey)
  391. @hail_bitmap.fill_rect(3, 1, 1, 2, grey)
  392. @hail_bitmap.fill_rect(1, 3, 2, 1, grey)
  393. @hail_bitmap.fill_rect(1, 1, 2, 2, lightGrey)
  394. @hail_bitmap.set_pixel(1, 1, lightBlue)


  395. color3 = Color.new(255, 167, 192, 255) # light pink
  396. color4 = Color.new(213, 106, 136, 255) # dark pink
  397. @petal_bitmap = Bitmap.new(4, 4) #This creates a new bitmap that is 4 x 4 pixels
  398. @petal_bitmap.fill_rect(0, 3, 1, 1, color3) # this makes a 1x1 pixel "rectangle" at the 0, 3 pixel of the image (upper left corner is 0, 0)
  399. @petal_bitmap.fill_rect(1, 2, 1, 1, color3)
  400. @petal_bitmap.fill_rect(2, 1, 1, 1, color3)
  401. @petal_bitmap.fill_rect(3, 0, 1, 1, color3)
  402. @petal_bitmap.fill_rect(1, 3, 1, 1, color4)
  403. @petal_bitmap.fill_rect(2, 2, 1, 1, color4)
  404. @petal_bitmap.fill_rect(3, 1, 1, 1, color4)


  405. brightOrange = Color.new(248, 88, 0, 255)
  406. orangeBrown = Color.new(144, 80, 56, 255)
  407. burntRed = Color.new(152, 0, 0, 255)
  408. paleOrange = Color.new(232, 160, 128, 255)
  409. darkBrown = Color.new(72, 40, 0, 255)
  410. @autumn_leaf_bitmaps = []
  411. @autumn_leaf_bitmaps.push(Bitmap.new(8, 8))
  412. # draw the first of the leaf1 bitmaps
  413. @autumn_leaf_bitmaps[0].set_pixel(5, 1, orangeBrown)
  414. @autumn_leaf_bitmaps[0].set_pixel(6, 1, brightOrange)
  415. @autumn_leaf_bitmaps[0].set_pixel(7, 1, paleOrange)
  416. @autumn_leaf_bitmaps[0].set_pixel(3, 2, orangeBrown)
  417. @autumn_leaf_bitmaps[0].fill_rect(4, 2, 2, 1, brightOrange)
  418. @autumn_leaf_bitmaps[0].set_pixel(6, 2, paleOrange)
  419. @autumn_leaf_bitmaps[0].set_pixel(2, 3, orangeBrown)
  420. @autumn_leaf_bitmaps[0].set_pixel(3, 3, brightOrange)
  421. @autumn_leaf_bitmaps[0].fill_rect(4, 3, 2, 1, paleOrange)
  422. @autumn_leaf_bitmaps[0].set_pixel(1, 4, orangeBrown)
  423. @autumn_leaf_bitmaps[0].set_pixel(2, 4, brightOrange)
  424. @autumn_leaf_bitmaps[0].set_pixel(3, 4, paleOrange)
  425. @autumn_leaf_bitmaps[0].set_pixel(1, 5, brightOrange)
  426. @autumn_leaf_bitmaps[0].set_pixel(2, 5, paleOrange)
  427. @autumn_leaf_bitmaps[0].set_pixel(0, 6, orangeBrown)
  428. @autumn_leaf_bitmaps[0].set_pixel(1, 6, paleOrange)
  429. @autumn_leaf_bitmaps[0].set_pixel(0, 7, paleOrange)

  430. # draw the 2nd of the leaf1 bitmaps
  431. @autumn_leaf_bitmaps.push(Bitmap.new(8, 8))
  432. @autumn_leaf_bitmaps[1].set_pixel(3, 0, brightOrange)
  433. @autumn_leaf_bitmaps[1].set_pixel(7, 0, brightOrange)
  434. @autumn_leaf_bitmaps[1].set_pixel(3, 1, orangeBrown)
  435. @autumn_leaf_bitmaps[1].set_pixel(4, 1, burntRed)
  436. @autumn_leaf_bitmaps[1].set_pixel(6, 1, brightOrange)
  437. @autumn_leaf_bitmaps[1].set_pixel(0, 2, paleOrange)
  438. @autumn_leaf_bitmaps[1].set_pixel(1, 2, brightOrange)
  439. @autumn_leaf_bitmaps[1].set_pixel(2, 2, orangeBrown)
  440. @autumn_leaf_bitmaps[1].set_pixel(3, 2, burntRed)
  441. @autumn_leaf_bitmaps[1].set_pixel(4, 2, orangeBrown)
  442. @autumn_leaf_bitmaps[1].set_pixel(5, 2, brightOrange)
  443. @autumn_leaf_bitmaps[1].fill_rect(1, 3, 3, 1, orangeBrown)
  444. @autumn_leaf_bitmaps[1].fill_rect(4, 3, 2, 1, brightOrange)
  445. @autumn_leaf_bitmaps[1].set_pixel(6, 3, orangeBrown)
  446. @autumn_leaf_bitmaps[1].set_pixel(2, 4, burntRed)
  447. @autumn_leaf_bitmaps[1].fill_rect(3, 4, 3, 1, brightOrange)
  448. @autumn_leaf_bitmaps[1].set_pixel(6, 4, burntRed)
  449. @autumn_leaf_bitmaps[1].set_pixel(7, 4, darkBrown)
  450. @autumn_leaf_bitmaps[1].set_pixel(1, 5, orangeBrown)
  451. @autumn_leaf_bitmaps[1].fill_rect(2, 5, 2, 1, brightOrange)
  452. @autumn_leaf_bitmaps[1].set_pixel(4, 5, orangeBrown)
  453. @autumn_leaf_bitmaps[1].set_pixel(5, 5, burntRed)
  454. @autumn_leaf_bitmaps[1].fill_rect(1, 6, 2, 1, brightOrange)
  455. @autumn_leaf_bitmaps[1].fill_rect(4, 6, 2, 1, burntRed)
  456. @autumn_leaf_bitmaps[1].set_pixel(0, 7, brightOrange)
  457. @autumn_leaf_bitmaps[1].set_pixel(5, 7, darkBrown)

  458. # draw the 3rd of the leaf1 bitmaps
  459. @autumn_leaf_bitmaps.push(Bitmap.new(8, 8))
  460. @autumn_leaf_bitmaps[2].set_pixel(7, 1, paleOrange)
  461. @autumn_leaf_bitmaps[2].set_pixel(6, 2, paleOrange)
  462. @autumn_leaf_bitmaps[2].set_pixel(7, 2, orangeBrown)
  463. @autumn_leaf_bitmaps[2].set_pixel(5, 3, paleOrange)
  464. @autumn_leaf_bitmaps[2].set_pixel(6, 3, brightOrange)
  465. @autumn_leaf_bitmaps[2].set_pixel(4, 4, paleOrange)
  466. @autumn_leaf_bitmaps[2].set_pixel(5, 4, brightOrange)
  467. @autumn_leaf_bitmaps[2].set_pixel(6, 4, orangeBrown)
  468. @autumn_leaf_bitmaps[2].fill_rect(2, 5, 2, 1, paleOrange)
  469. @autumn_leaf_bitmaps[2].set_pixel(4, 5, brightOrange)
  470. @autumn_leaf_bitmaps[2].set_pixel(5, 5, orangeBrown)
  471. @autumn_leaf_bitmaps[2].set_pixel(1, 6, paleOrange)
  472. @autumn_leaf_bitmaps[2].fill_rect(2, 6, 2, 1, brightOrange)
  473. @autumn_leaf_bitmaps[2].set_pixel(4, 6, orangeBrown)
  474. @autumn_leaf_bitmaps[2].set_pixel(0, 7, paleOrange)
  475. @autumn_leaf_bitmaps[2].set_pixel(1, 7, brightOrange)
  476. @autumn_leaf_bitmaps[2].set_pixel(2, 7, orangeBrown)

  477. # draw the 4th of the leaf1 bitmaps
  478. @autumn_leaf_bitmaps.push(Bitmap.new(8, 8))
  479. @autumn_leaf_bitmaps[3].set_pixel(3, 0, brightOrange)
  480. @autumn_leaf_bitmaps[3].set_pixel(7, 0, brightOrange)
  481. @autumn_leaf_bitmaps[3].set_pixel(3, 1, orangeBrown)
  482. @autumn_leaf_bitmaps[3].set_pixel(4, 1, burntRed)
  483. @autumn_leaf_bitmaps[3].set_pixel(6, 1, brightOrange)
  484. @autumn_leaf_bitmaps[3].set_pixel(0, 2, paleOrange)
  485. @autumn_leaf_bitmaps[3].set_pixel(1, 2, brightOrange)
  486. @autumn_leaf_bitmaps[3].set_pixel(2, 2, orangeBrown)
  487. @autumn_leaf_bitmaps[3].set_pixel(3, 2, burntRed)
  488. @autumn_leaf_bitmaps[3].set_pixel(4, 2, orangeBrown)
  489. @autumn_leaf_bitmaps[3].set_pixel(5, 2, brightOrange)
  490. @autumn_leaf_bitmaps[3].fill_rect(1, 3, 3, 1, orangeBrown)
  491. @autumn_leaf_bitmaps[3].fill_rect(4, 3, 2, 1, brightOrange)
  492. @autumn_leaf_bitmaps[3].set_pixel(6, 3, orangeBrown)
  493. @autumn_leaf_bitmaps[3].set_pixel(2, 4, burntRed)
  494. @autumn_leaf_bitmaps[3].fill_rect(3, 4, 3, 1, brightOrange)
  495. @autumn_leaf_bitmaps[3].set_pixel(6, 4, burntRed)
  496. @autumn_leaf_bitmaps[3].set_pixel(7, 4, darkBrown)
  497. @autumn_leaf_bitmaps[3].set_pixel(1, 5, orangeBrown)
  498. @autumn_leaf_bitmaps[3].fill_rect(2, 5, 2, 1, brightOrange)
  499. @autumn_leaf_bitmaps[3].set_pixel(4, 5, orangeBrown)
  500. @autumn_leaf_bitmaps[3].set_pixel(5, 5, burntRed)
  501. @autumn_leaf_bitmaps[3].fill_rect(1, 6, 2, 1, brightOrange)
  502. @autumn_leaf_bitmaps[3].fill_rect(4, 6, 2, 1, burntRed)
  503. @autumn_leaf_bitmaps[3].set_pixel(0, 7, brightOrange)
  504. @autumn_leaf_bitmaps[3].set_pixel(5, 7, darkBrown)

  505. @green_leaf_bitmaps = []
  506. darkGreen = Color.new(62, 76, 31, 255)
  507. midGreen = Color.new(76, 91, 43, 255)
  508. khaki = Color.new(105, 114, 66, 255)
  509. lightGreen = Color.new(128, 136, 88, 255)
  510. mint = Color.new(146, 154, 106, 255)

  511. # 1st leaf bitmap
  512. @green_leaf_bitmaps[0] = Bitmap.new(8, 8)
  513. @green_leaf_bitmaps[0].set_pixel(1, 0, darkGreen)
  514. @green_leaf_bitmaps[0].set_pixel(1, 1, midGreen)
  515. @green_leaf_bitmaps[0].set_pixel(2, 1, darkGreen)
  516. @green_leaf_bitmaps[0].set_pixel(2, 2, khaki)
  517. @green_leaf_bitmaps[0].set_pixel(3, 2, darkGreen)
  518. @green_leaf_bitmaps[0].set_pixel(4, 2, khaki)
  519. @green_leaf_bitmaps[0].fill_rect(2, 3, 3, 1, midGreen)
  520. @green_leaf_bitmaps[0].set_pixel(5, 3, khaki)
  521. @green_leaf_bitmaps[0].fill_rect(2, 4, 2, 1, midGreen)
  522. @green_leaf_bitmaps[0].set_pixel(4, 4, darkGreen)
  523. @green_leaf_bitmaps[0].set_pixel(5, 4, lightGreen)
  524. @green_leaf_bitmaps[0].set_pixel(6, 4, khaki)
  525. @green_leaf_bitmaps[0].set_pixel(3, 5, midGreen)
  526. @green_leaf_bitmaps[0].set_pixel(4, 5, darkGreen)
  527. @green_leaf_bitmaps[0].set_pixel(5, 5, khaki)
  528. @green_leaf_bitmaps[0].set_pixel(6, 5, lightGreen)
  529. @green_leaf_bitmaps[0].set_pixel(4, 6, midGreen)
  530. @green_leaf_bitmaps[0].set_pixel(5, 6, darkGreen)
  531. @green_leaf_bitmaps[0].set_pixel(6, 6, lightGreen)
  532. @green_leaf_bitmaps[0].set_pixel(6, 7, khaki)

  533. # 2nd leaf bitmap
  534. @green_leaf_bitmaps[1] = Bitmap.new(8, 8)
  535. @green_leaf_bitmaps[1].fill_rect(1, 1, 1, 2, midGreen)
  536. @green_leaf_bitmaps[1].fill_rect(2, 2, 2, 1, khaki)
  537. @green_leaf_bitmaps[1].set_pixel(4, 2, lightGreen)
  538. @green_leaf_bitmaps[1].fill_rect(2, 3, 2, 1, darkGreen)
  539. @green_leaf_bitmaps[1].fill_rect(4, 3, 2, 1, lightGreen)
  540. @green_leaf_bitmaps[1].set_pixel(2, 4, midGreen)
  541. @green_leaf_bitmaps[1].set_pixel(3, 4, darkGreen)
  542. @green_leaf_bitmaps[1].set_pixel(4, 4, khaki)
  543. @green_leaf_bitmaps[1].fill_rect(5, 4, 2, 1, lightGreen)
  544. @green_leaf_bitmaps[1].set_pixel(3, 5, midGreen)
  545. @green_leaf_bitmaps[1].set_pixel(4, 5, darkGreen)
  546. @green_leaf_bitmaps[1].set_pixel(5, 5, khaki)
  547. @green_leaf_bitmaps[1].set_pixel(6, 5, lightGreen)
  548. @green_leaf_bitmaps[1].set_pixel(5, 6, darkGreen)
  549. @green_leaf_bitmaps[1].fill_rect(6, 6, 2, 1, khaki)

  550. # 3rd leaf bitmap
  551. @green_leaf_bitmaps[2] = Bitmap.new(8, 8)
  552. @green_leaf_bitmaps[2].set_pixel(1, 1, darkGreen)
  553. @green_leaf_bitmaps[2].fill_rect(1, 2, 2, 1, midGreen)
  554. @green_leaf_bitmaps[2].set_pixel(2, 3, midGreen)
  555. @green_leaf_bitmaps[2].set_pixel(3, 3, darkGreen)
  556. @green_leaf_bitmaps[2].set_pixel(4, 3, midGreen)
  557. @green_leaf_bitmaps[2].fill_rect(2, 4, 2, 1, midGreen)
  558. @green_leaf_bitmaps[2].set_pixel(4, 4, darkGreen)
  559. @green_leaf_bitmaps[2].set_pixel(5, 4, lightGreen)
  560. @green_leaf_bitmaps[2].set_pixel(3, 5, midGreen)
  561. @green_leaf_bitmaps[2].set_pixel(4, 5, darkGreen)
  562. @green_leaf_bitmaps[2].fill_rect(5, 5, 2, 1, khaki)
  563. @green_leaf_bitmaps[2].fill_rect(4, 6, 2, 1, midGreen)
  564. @green_leaf_bitmaps[2].set_pixel(6, 6, lightGreen)
  565. @green_leaf_bitmaps[2].set_pixel(6, 7, khaki)

  566. # 4th leaf bitmap
  567. @green_leaf_bitmaps[3] = Bitmap.new(8, 8)
  568. @green_leaf_bitmaps[3].fill_rect(0, 3, 1, 2, darkGreen)
  569. @green_leaf_bitmaps[3].set_pixel(1, 4, midGreen)
  570. @green_leaf_bitmaps[3].set_pixel(2, 4, khaki)
  571. @green_leaf_bitmaps[3].set_pixel(3, 4, lightGreen)
  572. @green_leaf_bitmaps[3].set_pixel(4, 4, darkGreen)
  573. @green_leaf_bitmaps[3].set_pixel(7, 4, midGreen)
  574. @green_leaf_bitmaps[3].set_pixel(1, 5, darkGreen)
  575. @green_leaf_bitmaps[3].set_pixel(2, 5, midGreen)
  576. @green_leaf_bitmaps[3].set_pixel(3, 5, lightGreen)
  577. @green_leaf_bitmaps[3].set_pixel(4, 5, mint)
  578. @green_leaf_bitmaps[3].set_pixel(5, 5, lightGreen)
  579. @green_leaf_bitmaps[3].set_pixel(6, 5, khaki)
  580. @green_leaf_bitmaps[3].set_pixel(7, 5, midGreen)
  581. @green_leaf_bitmaps[3].fill_rect(2, 6, 2, 1, midGreen)
  582. @green_leaf_bitmaps[3].set_pixel(4, 6, lightGreen)
  583. @green_leaf_bitmaps[3].set_pixel(5, 6, khaki)
  584. @green_leaf_bitmaps[3].set_pixel(6, 6, midGreen)

  585. # 5th leaf bitmap
  586. @green_leaf_bitmaps[4] = Bitmap.new(8, 8)
  587. @green_leaf_bitmaps[4].set_pixel(6, 2, midGreen)
  588. @green_leaf_bitmaps[4].set_pixel(7, 2, darkGreen)
  589. @green_leaf_bitmaps[4].fill_rect(4, 3, 2, 1, midGreen)
  590. @green_leaf_bitmaps[4].set_pixel(6, 3, khaki)
  591. @green_leaf_bitmaps[4].set_pixel(2, 4, darkGreen)
  592. @green_leaf_bitmaps[4].fill_rect(3, 4, 2, 1, khaki)
  593. @green_leaf_bitmaps[4].set_pixel(5, 4, lightGreen)
  594. @green_leaf_bitmaps[4].set_pixel(6, 4, khaki)
  595. @green_leaf_bitmaps[4].set_pixel(1, 5, midGreen)
  596. @green_leaf_bitmaps[4].set_pixel(2, 5, khaki)
  597. @green_leaf_bitmaps[4].set_pixel(3, 5, lightGreen)
  598. @green_leaf_bitmaps[4].set_pixel(4, 5, mint)
  599. @green_leaf_bitmaps[4].set_pixel(5, 5, midGreen)
  600. @green_leaf_bitmaps[4].set_pixel(2, 6, darkGreen)
  601. @green_leaf_bitmaps[4].fill_rect(3, 6, 2, 1, midGreen)

  602. # 6th leaf bitmap
  603. @green_leaf_bitmaps[5] = Bitmap.new(8, 8)
  604. @green_leaf_bitmaps[5].fill_rect(6, 2, 2, 1, midGreen)
  605. @green_leaf_bitmaps[5].fill_rect(4, 3, 2, 1, midGreen)
  606. @green_leaf_bitmaps[5].set_pixel(6, 3, khaki)
  607. @green_leaf_bitmaps[5].set_pixel(3, 4, midGreen)
  608. @green_leaf_bitmaps[5].set_pixel(4, 4, khaki)
  609. @green_leaf_bitmaps[5].set_pixel(5, 4, lightGreen)
  610. @green_leaf_bitmaps[5].set_pixel(6, 4, mint)
  611. @green_leaf_bitmaps[5].set_pixel(1, 5, midGreen)
  612. @green_leaf_bitmaps[5].set_pixel(2, 5, khaki)
  613. @green_leaf_bitmaps[5].fill_rect(3, 5, 2, 1, mint)
  614. @green_leaf_bitmaps[5].set_pixel(5, 5, lightGreen)
  615. @green_leaf_bitmaps[5].set_pixel(2, 6, midGreen)
  616. @green_leaf_bitmaps[5].set_pixel(3, 6, khaki)
  617. @green_leaf_bitmaps[5].set_pixel(4, 6, lightGreen)

  618. # 7th leaf bitmap
  619. @green_leaf_bitmaps[6] = Bitmap.new(8, 8)
  620. @green_leaf_bitmaps[6].fill_rect(6, 1, 1, 2, midGreen)
  621. @green_leaf_bitmaps[6].fill_rect(4, 2, 2, 1, midGreen)
  622. @green_leaf_bitmaps[6].fill_rect(6, 2, 1, 2, darkGreen)
  623. @green_leaf_bitmaps[6].fill_rect(3, 3, 2, 1, midGreen)
  624. @green_leaf_bitmaps[6].set_pixel(5, 3, khaki)
  625. @green_leaf_bitmaps[6].set_pixel(2, 4, midGreen)
  626. @green_leaf_bitmaps[6].set_pixel(3, 4, khaki)
  627. @green_leaf_bitmaps[6].set_pixel(4, 4, lightGreen)
  628. @green_leaf_bitmaps[6].set_pixel(5, 4, midGreen)
  629. @green_leaf_bitmaps[6].set_pixel(1, 5, midGreen)
  630. @green_leaf_bitmaps[6].set_pixel(2, 5, khaki)
  631. @green_leaf_bitmaps[6].fill_rect(3, 5, 2, 1, midGreen)
  632. @green_leaf_bitmaps[6].set_pixel(1, 6, darkGreen)
  633. @green_leaf_bitmaps[6].set_pixel(2, 6, midGreen)

  634. # 8th leaf bitmap
  635. @green_leaf_bitmaps[7] = Bitmap.new(8, 8)
  636. @green_leaf_bitmaps[7].set_pixel(6, 1, midGreen)
  637. @green_leaf_bitmaps[7].fill_rect(4, 2, 3, 2, midGreen)
  638. @green_leaf_bitmaps[7].set_pixel(3, 3, darkGreen)
  639. @green_leaf_bitmaps[7].set_pixel(2, 4, darkGreen)
  640. @green_leaf_bitmaps[7].set_pixel(3, 4, midGreen)
  641. @green_leaf_bitmaps[7].fill_rect(4, 4, 2, 1, khaki)
  642. @green_leaf_bitmaps[7].set_pixel(1, 5, darkGreen)
  643. @green_leaf_bitmaps[7].set_pixel(2, 5, midGreen)
  644. @green_leaf_bitmaps[7].fill_rect(3, 5, 2, 1, lightGreen)
  645. @green_leaf_bitmaps[7].set_pixel(2, 6, midGreen)
  646. @green_leaf_bitmaps[7].set_pixel(3, 6, lightGreen)

  647. # 9th leaf bitmap
  648. @green_leaf_bitmaps[8] = Bitmap.new(8, 8)
  649. @green_leaf_bitmaps[8].fill_rect(6, 1, 1, 2, midGreen)
  650. @green_leaf_bitmaps[8].fill_rect(4, 2, 2, 1, midGreen)
  651. @green_leaf_bitmaps[8].fill_rect(6, 2, 1, 2, darkGreen)
  652. @green_leaf_bitmaps[8].fill_rect(3, 3, 2, 1, midGreen)
  653. @green_leaf_bitmaps[8].set_pixel(5, 3, khaki)
  654. @green_leaf_bitmaps[8].set_pixel(2, 4, midGreen)
  655. @green_leaf_bitmaps[8].set_pixel(3, 4, khaki)
  656. @green_leaf_bitmaps[8].set_pixel(4, 4, lightGreen)
  657. @green_leaf_bitmaps[8].set_pixel(5, 4, midGreen)
  658. @green_leaf_bitmaps[8].set_pixel(1, 5, midGreen)
  659. @green_leaf_bitmaps[8].set_pixel(2, 5, khaki)
  660. @green_leaf_bitmaps[8].fill_rect(3, 5, 2, 1, midGreen)
  661. @green_leaf_bitmaps[8].set_pixel(1, 6, darkGreen)
  662. @green_leaf_bitmaps[8].set_pixel(2, 6, midGreen)

  663. # 10th leaf bitmap
  664. @green_leaf_bitmaps[9] = Bitmap.new(8, 8)
  665. @green_leaf_bitmaps[9].fill_rect(6, 2, 2, 1, midGreen)
  666. @green_leaf_bitmaps[9].fill_rect(4, 3, 2, 1, midGreen)
  667. @green_leaf_bitmaps[9].set_pixel(6, 3, khaki)
  668. @green_leaf_bitmaps[9].set_pixel(3, 4, midGreen)
  669. @green_leaf_bitmaps[9].set_pixel(4, 4, khaki)
  670. @green_leaf_bitmaps[9].set_pixel(5, 4, lightGreen)
  671. @green_leaf_bitmaps[9].set_pixel(6, 4, mint)
  672. @green_leaf_bitmaps[9].set_pixel(1, 5, midGreen)
  673. @green_leaf_bitmaps[9].set_pixel(2, 5, khaki)
  674. @green_leaf_bitmaps[9].fill_rect(3, 5, 2, 1, mint)
  675. @green_leaf_bitmaps[9].set_pixel(5, 5, lightGreen)
  676. @green_leaf_bitmaps[9].set_pixel(2, 6, midGreen)
  677. @green_leaf_bitmaps[9].set_pixel(3, 6, khaki)
  678. @green_leaf_bitmaps[9].set_pixel(4, 6, lightGreen)

  679. # 11th leaf bitmap
  680. @green_leaf_bitmaps[10] = Bitmap.new(8, 8)
  681. @green_leaf_bitmaps[10].set_pixel(6, 2, midGreen)
  682. @green_leaf_bitmaps[10].set_pixel(7, 2, darkGreen)
  683. @green_leaf_bitmaps[10].fill_rect(4, 3, 2, 1, midGreen)
  684. @green_leaf_bitmaps[10].set_pixel(6, 3, khaki)
  685. @green_leaf_bitmaps[10].set_pixel(2, 4, darkGreen)
  686. @green_leaf_bitmaps[10].fill_rect(3, 4, 2, 1, khaki)
  687. @green_leaf_bitmaps[10].set_pixel(5, 4, lightGreen)
  688. @green_leaf_bitmaps[10].set_pixel(6, 4, khaki)
  689. @green_leaf_bitmaps[10].set_pixel(1, 5, midGreen)
  690. @green_leaf_bitmaps[10].set_pixel(2, 5, khaki)
  691. @green_leaf_bitmaps[10].set_pixel(3, 5, lightGreen)
  692. @green_leaf_bitmaps[10].set_pixel(4, 5, mint)
  693. @green_leaf_bitmaps[10].set_pixel(5, 5, midGreen)
  694. @green_leaf_bitmaps[10].set_pixel(2, 6, darkGreen)
  695. @green_leaf_bitmaps[10].fill_rect(3, 6, 2, 1, midGreen)



  696. # 12th leaf bitmap
  697. @green_leaf_bitmaps[11] = Bitmap.new(8, 8)
  698. @green_leaf_bitmaps[11].fill_rect(0, 3, 1, 2, darkGreen)
  699. @green_leaf_bitmaps[11].set_pixel(1, 4, midGreen)
  700. @green_leaf_bitmaps[11].set_pixel(2, 4, khaki)
  701. @green_leaf_bitmaps[11].set_pixel(3, 4, lightGreen)
  702. @green_leaf_bitmaps[11].set_pixel(4, 4, darkGreen)
  703. @green_leaf_bitmaps[11].set_pixel(7, 4, midGreen)
  704. @green_leaf_bitmaps[11].set_pixel(1, 5, darkGreen)
  705. @green_leaf_bitmaps[11].set_pixel(2, 5, midGreen)
  706. @green_leaf_bitmaps[11].set_pixel(3, 5, lightGreen)
  707. @green_leaf_bitmaps[11].set_pixel(4, 5, mint)
  708. @green_leaf_bitmaps[11].set_pixel(5, 5, lightGreen)
  709. @green_leaf_bitmaps[11].set_pixel(6, 5, khaki)
  710. @green_leaf_bitmaps[11].set_pixel(7, 5, midGreen)
  711. @green_leaf_bitmaps[11].fill_rect(2, 6, 2, 1, midGreen)
  712. @green_leaf_bitmaps[11].set_pixel(4, 6, lightGreen)
  713. @green_leaf_bitmaps[11].set_pixel(5, 6, khaki)
  714. @green_leaf_bitmaps[11].set_pixel(6, 6, midGreen)

  715. # 13th leaf bitmap
  716. @green_leaf_bitmaps[12] = Bitmap.new(8, 8)
  717. @green_leaf_bitmaps[12].set_pixel(1, 1, darkGreen)
  718. @green_leaf_bitmaps[12].fill_rect(1, 2, 2, 1, midGreen)
  719. @green_leaf_bitmaps[12].set_pixel(2, 3, midGreen)
  720. @green_leaf_bitmaps[12].set_pixel(3, 3, darkGreen)
  721. @green_leaf_bitmaps[12].set_pixel(4, 3, midGreen)
  722. @green_leaf_bitmaps[12].fill_rect(2, 4, 2, 1, midGreen)
  723. @green_leaf_bitmaps[12].set_pixel(4, 4, darkGreen)
  724. @green_leaf_bitmaps[12].set_pixel(5, 4, lightGreen)
  725. @green_leaf_bitmaps[12].set_pixel(3, 5, midGreen)
  726. @green_leaf_bitmaps[12].set_pixel(4, 5, darkGreen)
  727. @green_leaf_bitmaps[12].fill_rect(5, 5, 2, 1, khaki)
  728. @green_leaf_bitmaps[12].fill_rect(4, 6, 2, 1, midGreen)
  729. @green_leaf_bitmaps[12].set_pixel(6, 6, lightGreen)
  730. @green_leaf_bitmaps[12].set_pixel(6, 7, khaki)

  731. @rose_bitmaps = []
  732. brightRed = Color.new(255, 0, 0, 255)
  733. midRed = Color.new(179, 17, 17, 255)
  734. darkRed = Color.new(141, 9, 9, 255)

  735. # 1st rose petal bitmap
  736. @rose_bitmaps[0] = Bitmap.new(3, 3)
  737. @rose_bitmaps[0].fill_rect(1, 0, 2, 1, brightRed)
  738. @rose_bitmaps[0].fill_rect(0, 1, 1, 2, brightRed)
  739. @rose_bitmaps[0].fill_rect(1, 1, 2, 2, midRed)
  740. @rose_bitmaps[0].set_pixel(2, 2, darkRed)

  741. # 2nd rose petal bitmap
  742. @rose_bitmaps[1] = Bitmap.new(3, 3)
  743. @rose_bitmaps[1].set_pixel(0, 1, midRed)
  744. @rose_bitmaps[1].set_pixel(1, 1, brightRed)
  745. @rose_bitmaps[1].fill_rect(1, 2, 1, 2, midRed)

  746. @feather_bitmaps = []
  747. white = Color.new(255, 255, 255, 255)

  748. # 1st feather bitmap
  749. @feather_bitmaps[0] = Bitmap.new(3, 3)
  750. @feather_bitmaps[0].set_pixel(0, 2, white)
  751. @feather_bitmaps[0].set_pixel(1, 2, grey)
  752. @feather_bitmaps[0].set_pixel(2, 1, grey)

  753. # 2nd feather bitmap
  754. @feather_bitmaps[0] = Bitmap.new(3, 3)
  755. @feather_bitmaps[0].set_pixel(0, 0, white)
  756. @feather_bitmaps[0].set_pixel(0, 1, grey)
  757. @feather_bitmaps[0].set_pixel(1, 2, grey)

  758. # 3rd feather bitmap
  759. @feather_bitmaps[0] = Bitmap.new(3, 3)
  760. @feather_bitmaps[0].set_pixel(2, 0, white)
  761. @feather_bitmaps[0].set_pixel(1, 0, grey)
  762. @feather_bitmaps[0].set_pixel(0, 1, grey)

  763. # 4th feather bitmap
  764. @feather_bitmaps[0] = Bitmap.new(3, 3)
  765. @feather_bitmaps[0].set_pixel(2, 2, white)
  766. @feather_bitmaps[0].set_pixel(2, 1, grey)
  767. @feather_bitmaps[0].set_pixel(1, 0, grey)

  768. @blood_rain_bitmap = Bitmap.new(7, 56)
  769. for i in 0..6
  770. @blood_rain_bitmap.fill_rect(6-i, i*8, 1, 8, darkRed)
  771. end

  772. @sparkle_bitmaps = []

  773. lightBlue = Color.new(181, 244, 255, 255)
  774. midBlue = Color.new(126, 197, 235, 255)
  775. darkBlue = Color.new(77, 136, 225, 255)

  776. # 1st sparkle bitmap
  777. @sparkle_bitmaps[0] = Bitmap.new(7, 7)
  778. @sparkle_bitmaps[0].set_pixel(3, 3, darkBlue)

  779. # 2nd sparkle bitmap
  780. @sparkle_bitmaps[1] = Bitmap.new(7, 7)
  781. @sparkle_bitmaps[1].fill_rect(3, 2, 1, 3, darkBlue)
  782. @sparkle_bitmaps[1].fill_rect(2, 3, 3, 1, darkBlue)
  783. @sparkle_bitmaps[1].set_pixel(3, 3, midBlue)

  784. # 3rd sparkle bitmap
  785. @sparkle_bitmaps[2] = Bitmap.new(7, 7)
  786. @sparkle_bitmaps[2].set_pixel(1, 1, darkBlue)
  787. @sparkle_bitmaps[2].set_pixel(5, 1, darkBlue)
  788. @sparkle_bitmaps[2].set_pixel(2, 2, midBlue)
  789. @sparkle_bitmaps[2].set_pixel(4, 2, midBlue)
  790. @sparkle_bitmaps[2].set_pixel(3, 3, lightBlue)
  791. @sparkle_bitmaps[2].set_pixel(2, 4, midBlue)
  792. @sparkle_bitmaps[2].set_pixel(4, 4, midBlue)
  793. @sparkle_bitmaps[2].set_pixel(1, 5, darkBlue)
  794. @sparkle_bitmaps[2].set_pixel(5, 5, darkBlue)

  795. # 4th sparkle bitmap
  796. @sparkle_bitmaps[3] = Bitmap.new(7, 7)
  797. @sparkle_bitmaps[3].fill_rect(3, 1, 1, 5, darkBlue)
  798. @sparkle_bitmaps[3].fill_rect(1, 3, 5, 1, darkBlue)
  799. @sparkle_bitmaps[3].fill_rect(3, 2, 1, 3, midBlue)
  800. @sparkle_bitmaps[3].fill_rect(2, 3, 3, 1, midBlue)
  801. @sparkle_bitmaps[3].set_pixel(3, 3, lightBlue)

  802. # 5th sparkle bitmap
  803. @sparkle_bitmaps[4] = Bitmap.new(7, 7)
  804. @sparkle_bitmaps[4].fill_rect(2, 2, 3, 3, midBlue)
  805. @sparkle_bitmaps[4].fill_rect(3, 2, 1, 3, darkBlue)
  806. @sparkle_bitmaps[4].fill_rect(2, 3, 3, 1, darkBlue)
  807. @sparkle_bitmaps[4].set_pixel(3, 3, lightBlue)
  808. @sparkle_bitmaps[4].set_pixel(1, 1, darkBlue)
  809. @sparkle_bitmaps[4].set_pixel(5, 1, darkBlue)
  810. @sparkle_bitmaps[4].set_pixel(1, 5, darkBlue)
  811. @sparkle_bitmaps[4].set_pixel(5, 1, darkBlue)

  812. # 6th sparkle bitmap
  813. @sparkle_bitmaps[5] = Bitmap.new(7, 7)
  814. @sparkle_bitmaps[5].fill_rect(2, 1, 3, 5, darkBlue)
  815. @sparkle_bitmaps[5].fill_rect(1, 2, 5, 3, darkBlue)
  816. @sparkle_bitmaps[5].fill_rect(2, 2, 3, 3, midBlue)
  817. @sparkle_bitmaps[5].fill_rect(3, 1, 1, 5, midBlue)
  818. @sparkle_bitmaps[5].fill_rect(1, 3, 5, 1, midBlue)
  819. @sparkle_bitmaps[5].fill_rect(3, 2, 1, 3, lightBlue)
  820. @sparkle_bitmaps[5].fill_rect(2, 3, 3, 1, lightBlue)
  821. @sparkle_bitmaps[5].set_pixel(3, 3, white)

  822. # 7th sparkle bitmap
  823. @sparkle_bitmaps[6] = Bitmap.new(7, 7)
  824. @sparkle_bitmaps[6].fill_rect(2, 1, 3, 5, midBlue)
  825. @sparkle_bitmaps[6].fill_rect(1, 2, 5, 3, midBlue)
  826. @sparkle_bitmaps[6].fill_rect(3, 0, 1, 7, darkBlue)
  827. @sparkle_bitmaps[6].fill_rect(0, 3, 7, 1, darkBlue)
  828. @sparkle_bitmaps[6].fill_rect(2, 2, 3, 3, lightBlue)
  829. @sparkle_bitmaps[6].fill_rect(3, 2, 1, 3, midBlue)
  830. @sparkle_bitmaps[6].fill_rect(2, 3, 3, 1, midBlue)
  831. @sparkle_bitmaps[6].set_pixel(3, 3, white)

  832. @user_bitmaps = []
  833. update_user_defined
  834. end

  835. def update_user_defined
  836. for image in @user_bitmaps
  837. image.dispose
  838. end

  839. #user-defined bitmaps
  840. for name in $WEATHER_IMAGES
  841. @user_bitmaps.push(RPG::Cache.picture(name))
  842. end
  843. for sprite in @sprites
  844. sprite.bitmap = @user_bitmaps[rand(@user_bitmaps.size)]
  845. end
  846. end

  847. attr_reader :type
  848. attr_reader :max
  849. attr_reader :ox
  850. attr_reader :oy
  851. end
  852. end



复制代码


KRKR + NS 学习中..........
回复 支持 反对

使用道具 举报

Lv1.梦旅人

查无此人

梦石
0
星屑
50
在线时间
9 小时
注册时间
2006-5-8
帖子
1399
4
 楼主| 发表于 2006-7-17 17:55:23 | 只看该作者
7月17日

StarOcean Battle Aerena


介绍:来源同上
作者:SephirothSpawn

一个类似打擂台的战斗。使用方法见范例工程。

截图自己看:
http://ftp2.66rpg.com/3/临时� ... Battle Arena/sh.jpg

范例工程:
http://ftp2.66rpg.com/3/临时� ... Arena/starocean.rar

KRKR + NS 学习中..........
回复 支持 反对

使用道具 举报

Lv1.梦旅人

梦石
0
星屑
50
在线时间
37 小时
注册时间
2006-2-27
帖子
230
5
发表于 2006-7-17 17:57:45 | 只看该作者
好东西!!!(指天气的)
具体用法$game_screen.weather(14, 35, 0)
这个出现什么情况?
................
回复 支持 反对

使用道具 举报

Lv1.梦旅人

查无此人

梦石
0
星屑
50
在线时间
9 小时
注册时间
2006-5-8
帖子
1399
6
 楼主| 发表于 2006-7-17 18:00:35 | 只看该作者
以下引用千鸟于2006-7-17 9:57:45的发言:

好东西!!!(指天气的)
具体用法$game_screen.weather(14, 35, 0)
这个出现什么情况?



出现14号天气(闪烁),强度为35,色调为基本色

个人认为雷雨,闪烁,以及血雨这三种比较好看
KRKR + NS 学习中..........
回复 支持 反对

使用道具 举报

Lv1.梦旅人

梦石
0
星屑
50
在线时间
37 小时
注册时间
2006-2-27
帖子
230
7
发表于 2006-7-17 18:09:09 | 只看该作者
强度什么意思!
就是闪光的亮和暗吗?
................
回复 支持 反对

使用道具 举报

Lv1.梦旅人

梦石
0
星屑
50
在线时间
37 小时
注册时间
2006-2-27
帖子
230
8
发表于 2006-7-17 18:10:19 | 只看该作者
不错不错!顶~~~~~~

又一个口袋的脚本,太好了!哈哈!
................
回复 支持 反对

使用道具 举报

Lv5.捕梦者

梦石
0
星屑
27188
在线时间
1535 小时
注册时间
2006-1-10
帖子
2063

开拓者第一届地图绘制大赛RTP组第四名

9
发表于 2006-7-17 20:21:37 | 只看该作者
又有好东西了
回复 支持 反对

使用道具 举报

Lv1.梦旅人

风之塞尔达

梦石
0
星屑
50
在线时间
57 小时
注册时间
2005-10-22
帖子
2492

贵宾

10
发表于 2006-7-17 20:33:27 | 只看该作者
{/se}
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册会员

本版积分规则

拿上你的纸笔,建造一个属于你的梦想世界,加入吧。
 注册会员
找回密码

站长信箱:[email protected]|手机版|小黑屋|无图版|Project1游戏制作

GMT+8, 2024-12-4 16:43

Powered by Discuz! X3.1

© 2001-2013 Comsenz Inc.

快速回复 返回顶部 返回列表