Advertisement
Kakakadafi

Kadafi - Map Intro

Dec 24th, 2014
257
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Ruby 1.98 KB | None | 0 0
  1. #=============================================================================
  2. # Kadafi - Map Intro
  3. # Version : 1.0
  4. # Contact : http://www.facebook.com/xandalfi
  5. # =============================================================================
  6. ($imported ||= {})[:Kadafi_MapIntro] = true
  7. # =============================================================================
  8. # CHANGE LOGS:
  9. # -----------------------------------------------------------------------------
  10. # 2014.12.24 - Finished script
  11. # =============================================================================
  12. =begin
  13.  
  14.   Introduction :
  15.   This script allow you to make intro from map events.
  16.  
  17.   How to Use :
  18.   Don't forget to return the scene to the Scene Title after intro.
  19.   (SceneManager.goto(Scene_Title)
  20.  
  21.   Terms of Use :
  22.   1. Credit me as Kadafi
  23.  
  24. =end
  25. # =============================================================================
  26. # Configuration
  27. # =============================================================================
  28.   module Kadafi
  29.     module MapIntro
  30.       Map_ID = 2
  31.       Start_X  = 1
  32.       Start_Y  = 1
  33.     end
  34.   end
  35. # =============================================================================
  36. # Don't edit below this line unless you know what to do.
  37. # =============================================================================
  38.   module DataManager
  39.     def self.setup_intro
  40.       create_game_objects
  41.       $game_party.setup_starting_members
  42.       $game_map.setup(Kadafi::MapIntro::Map_ID)
  43.       $game_player.moveto(Kadafi::MapIntro::Start_X, Kadafi::MapIntro::Start_Y)
  44.       $game_player.refresh
  45.       Graphics.frame_count = 0
  46.     end
  47.   end
  48.  
  49.   module SceneManager
  50.     def self.first_scene_class
  51.       $BTEST ? Scene_Battle : Scene_MapIntro
  52.     end
  53.   end
  54.  
  55.   class Scene_MapIntro < Scene_Base
  56.     def start()
  57.       super
  58.       SceneManager.clear
  59.       Graphics.freeze
  60.       DataManager.setup_intro
  61.       $game_map.autoplay
  62.       SceneManager.goto(Scene_Map)
  63.     end
  64.   end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement