Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- require "rubygems"
- require "gosu"
- #-------------General
- require "./SRC/General/Mode.rb"
- require "./SRC/General/Button.rb"
- require "./SRC/General/Box.rb"
- require "./SRC/General/Animation.rb"
- #-------------Communication
- require "./SRC/Communication/Word.rb"
- require "./SRC/Communication/Sentence.rb"
- require "./SRC/Communication/UpCom.rb"
- require "./SRC/Communication/Civilisation.rb"
- #-------------Exploration
- require "./SRC/Exploration/ModeSpace.rb"
- require "./SRC/Exploration/SpaceShip.rb"
- require "./SRC/Exploration/Shoot.rb"
- require "./SRC/Exploration/Scrolling.rb"
- require "./SRC/Exploration/IA.rb"
- require "./SRC/Exploration/Hud.rb"
- require "./SRC/Exploration/SSU.rb"
- class GameWindows < Gosu::Window
- attr_accessor :pointer_activated
- def initialize()
- super(640,480,false,20)
- @pointer = Gosu::Image.new(self,"Image/mouse.png",true)
- @pointer_activated = false
- end
- def update
- $mode.update
- end
- def draw
- $mode.draw
- @pointer.draw($window.mouse_x,$window.mouse_y,128) if @pointer_activated
- end
- def switch_mode(new_mode)
- $mode.delete unless @mode == nil
- $mode = new_mode
- $mode.start
- end
- def button_down(id)
- puts id
- #key pad
- #1=>65436
- #2=>65433
- #3=>65435
- #4=>65430
- #5=>65437
- #6=>65432
- #7=>65439
- #8=>65431
- #9=>65434
- end
- end
- puts "salut ", "entre dans l'ordre Z,Q,S,D,8,6,4","Les chifres sur le pave num s'il te plait"
- $window = GameWindows.new
- $window.switch_mode(ModeSpace.new)
- $window.show
Advertisement
Add Comment
Please, Sign In to add comment