• Log in or sign up for an account here: https://www.sythe.org/login

Space Dragon Adventure [Post your scores!]

Joined
May 6, 2005
Sythe Gold
0
Messages
4,425
Post screenshots of your high scores!

Space Dragon Adventure is a game I created in my Web Design and Game Programming class. I used a program called Game Maker which uses a language similar to Java, and Blender to create all the graphics.


Download:
http://www.filefactory.com/file/ag5c1g1/n/space_dragon_adventure_exe


Screenshots:
screenshot-qJvjt.jpg


In the distant future when dragons evolve and roam the universe, one man decides he will slay them all and become known as Zolarian, the greatest dragon slayer ever to set foot in this part of the galaxy.

Source:
Code:
Information about object: obj_ship

Sprite: spr_playership
Solid: false
Visible: true
Depth: 0
Persistent: false
Parent: <no parent>
Mask: <same as sprite>

Create Event:
set the mouse cursor to sprite <undefined> and don't show the windows cursor
execute code:

x = mouse_x;
y = mouse_y;
canfire = 1;
health = 100;
firerate = 10;
doublefire = 0;

set the health to 100

Alarm Event for alarm 0:
set variable canfire to 1

Alarm Event for alarm 2:
set variable doublefire relative to -1
if doublefire is larger than 0
      set Alarm 2 to 30

 Step Event:
execute code:

x = mouse_x;
y = mouse_y;
if expression x < obj_ship.sprite_xoffset is true
      execute code:

x = obj_ship.sprite_xoffset;
window_mouse_set(obj_ship.sprite_xoffset, mouse_y);
if expression x > room_width - obj_ship.sprite_xoffset is true
      execute code:

x = room_width - obj_ship.sprite_xoffset;
window_mouse_set(room_width - obj_ship.sprite_xoffset, mouse_y);
if expression y < 250 is true
      execute code:

y = 250;
window_mouse_set(mouse_x, 250);
if expression y > room_height - obj_ship.sprite_yoffset is true
      execute code:

y = room_height - obj_ship.sprite_yoffset;
window_mouse_set(mouse_x, y);
if health is smaller than 0
      show the highscore table
    background: <undefined>
     show the border
     new color: 255, other color: 0
     Font: "Times New Roman",10,0,0,0,0,0
      create a medium effect of type explosion relative at (0,0) of  color 255 below objects
      sleep 2000 milliseconds; redrawing the screen: true
      go to room Game Over Room with transition effect Blend

Collision Event with object obj_powerupx2:
for other object: destroy the instance
set variable doublefire to 10
set Alarm 2 to 30

Collision Event with object obj_straight_down_bulllet:
for other object: destroy the instance
for other object: create a medium effect of type explosion relative at (0,0) of  color 16777215 above objects
set the health relative to -5

Collision Event with object obj_heatseeking:
for other object: destroy the instance
for other object: create a medium effect of type explosion relative at (0,0) of  color 16777215 above objects
set the health relative to -10

Collision Event with object obj_poweruphealth:
for other object: destroy the instance
create a small effect of type ellipse relative at (0,0) of  color 16777215 below objects
if health is smaller than 80
      set variable health relative to 20
else
      set variable health to 100

Collision Event with object obj_boss:
destroy the instance
create instance of object obj_ship_explosion at position (0,0)
go to room Game Over Room with transition effect Fade out and in

Mouse Event for Left Button:
if expression canfire == 1 is true
      if doublefire is equal to 0
            create instance of object obj_bullet at relative position (0,0)
      else
            create instance of object obj_bullet at relative position (-14,0)
            create instance of object obj_bullet at relative position (14,0)
      set variable canfire to 0
      set Alarm 0 to firerate

Draw Event:
at relative position (0,0) draw image -1 of sprite spr_playership
draw the health bar with size (50,room_height - 10,room_width - 50,room_height) with back color green and bar color green to red
set the drawing color to 4259584
draw rectangle with relative vertices (-(sprite_xoffset+10),-20) and (-sprite_xoffset,-20+doublefire*4), filled
______________________________________________________

Information about object: obj_enemy

Sprite: spr_enemy
Solid: false
Visible: true
Depth: 0
Persistent: false
Parent: obj_enemy_parent
Mask: <same as sprite>

Create Event:
call the inherited event of the parent object
set the relative path to path_enemy1 with speed 4 and at the end reverse
set variable hits to 5

Draw Event:
at relative position (0,0) draw image -1 of sprite spr_enemy
call the inherited event of the parent object
______________________________________________________

Information about object: obj_largeenemy

Sprite: spr_largeenemy
Solid: false
Visible: true
Depth: 0
Persistent: false
Parent: obj_enemy_parent
Mask: <same as sprite>

Create Event:
call the inherited event of the parent object
set the relative path to path_enemy2 with speed 6 and at the end reverse
set variable hits to 10

Draw Event:
at relative position (0,0) draw image -1 of sprite spr_largeenemy
call the inherited event of the parent object
______________________________________________________

Information about object:  obj_controller

Sprite: <no sprite>
Solid: false
Visible: true
Depth: 0
Persistent: false
Parent: <no parent>
Mask: <same as sprite>

Create Event:
set variable level to 0
execute script scr_create_enemy with arguments (0,0,0,0,0)
set variable createnewwave to 0
set the score to 0

Alarm Event for alarm 0:
execute script scr_create_enemy with arguments (0,0,0,0,0)
set variable createnewwave to 0

 Step Event:
with a chance of 1 out of 800 do  perform the next action
      create instance of object obj_powerupx2 at position (random(550)+50,0)
      create instance of object obj_poweruphealth at position (random(550)+50,0)
if number of objects obj_enemy_parent is Equal to 0
      if createnewwave is equal to 0
      set variable createnewwave to 1
      set Alarm 0 to 30
if level is equal to 2
      if number of objects obj_boss is Equal to 0
            set the score relative to 1000
            go to room Win Room with transition effect Create from center

Draw Event:
at position (10,470) draw the value of score with caption Score: 
______________________________________________________

Information about object: obj_bullet

Sprite: spr_bullet
Solid: false
Visible: true
Depth: 10
Persistent: false
Parent: <no parent>
Mask: <same as sprite>

Create Event:
start moving in directions 000000010 with speed set to 8

Other Event: Outside Room:
destroy the instance

Draw Event:
create a small effect of type flare relative at (0,0) of  color 16777088 below objects
______________________________________________________

Information about object: obj_enemyexplode

Sprite: spr_enemyexplode
Solid: false
Visible: true
Depth: 0
Persistent: false
Parent: <no parent>
Mask: <same as sprite>

Other Event: Animation End:
destroy the instance
______________________________________________________

Information about object: obj_enemy_parent

Sprite: <no sprite>
Solid: false
Visible: true
Depth: 0
Persistent: false
Parent: <no parent>
Mask: <same as sprite>

Create Event:
set variable hits to 1
set variable showhealth to 0

Alarm Event for alarm 0:
set variable showhealth to 0

 Step Event:
if expression hits <= 0 is true
      destroy the instance
      create instance of object obj_ship_explosion at relative position (0,0)
      set the score relative to 100
with a chance of 1 out of 300 do  perform the next action
      create instance of object obj_straight_down_bulllet at relative position (0,64)
with a chance of 1 out of 600 do  perform the next action
      create instance of object obj_heatseeking at relative position (0,64)

Collision Event with object obj_bullet:
for other object: destroy the instance
create instance of object obj_enemyexplode at relative position (0,0)
set variable hits relative to -1
set variable showhealth to 1
set Alarm 0 to 30

Draw Event:
if expression showhealth == 1 is true
      set the drawing color to 255
      draw rectangle with relative vertices (-(hits * 2),0) and (hits * 2,10), filled
______________________________________________________

Information about object: obj_ship_explosion

Sprite: <no sprite>
Solid: false
Visible: true
Depth: 0
Persistent: false
Parent: <no parent>
Mask: <same as sprite>

Create Event:
execute code:

/*GAMECAVE EFFECTS ENGINE 3.X
Read the GCE3X documentation before using this code!

Object Name - objExplosion_1
Engine - Explosion Engine 
Purpose - The barrel/explosion for the first type of explosion.
*/

//Create Particle System
explosion = part_system_create();
part_system_depth(explosion,-200);

//Create Core Emitter
emit1 = part_emitter_create(explosion);
part_emitter_region(explosion,emit1,x,x+20-random(40),y,y+20-random(40),ps_shape_ellipse,ps_distr_gaussian);

//Fire Layer
prt1 = part_type_create();
part_type_shape(prt1,pt_shape_flare);
part_type_size(prt1,2,3,0,0);
part_type_color1(prt1,make_color_rgb(255,128,64));
part_type_alpha2(prt1,1,0);
part_type_life(prt1,25,50);
part_type_speed(prt1,20,22,-0.7,0);
part_type_direction(prt1,0,360,0,0);
part_type_blend(prt1,true);
 
//"Fluffy" Layer
prt2 = part_type_create();
part_type_shape(prt2,pt_shape_explosion);
part_type_size(prt2,1,2,0,0);
part_type_color1(prt2,make_color_rgb(255,128,64));
part_type_alpha2(prt2,1,0);
part_type_life(prt2,25,50);
part_type_speed(prt2,20,22,-1,0);
part_type_direction(prt2,0,360,0,0);
part_type_blend(prt2,true);

//Smoke Layer
prt3 = part_type_create();
part_type_shape(prt3,pt_shape_smoke);
part_type_size(prt3,1,3,0.002,0);
part_type_color_mix(prt3,c_dkgray,c_ltgray);
part_type_alpha2(prt3,1,0);
part_type_life(prt3,80,100);
part_type_gravity(prt3,0.1,90);
part_type_speed(prt3,4,8,0,0);
part_type_direction(prt3,50,130,0,0);

part_emitter_burst(explosion,emit1,prt1,80);
    part_emitter_burst(explosion,emit1,prt2,80);
    part_emitter_burst(explosion,emit1,prt3,80);

 



______________________________________________________

Information about object: obj_powerupx2

Sprite: spr_powerupx2
Solid: false
Visible: true
Depth: 0
Persistent: false
Parent: <no parent>
Mask: <same as sprite>

Create Event:
start moving in directions 010000000 with speed set to 4
set variable img_speed to 5

Other Event: Outside Room:
destroy the instance
______________________________________________________

Information about object: obj_straight_down_bulllet

Sprite: spr_bullet
Solid: false
Visible: true
Depth: 0
Persistent: false
Parent: <no parent>
Mask: <same as sprite>

Create Event:
start moving in directions 010000000 with speed set to 9

Other Event: Outside Room:
destroy the instance

Draw Event:
create a small effect of type flare relative at (0,0) of  color 65280 below objects
______________________________________________________

Information about object: obj_heatseeking

Sprite: spr_bullet
Solid: false
Visible: true
Depth: 0
Persistent: false
Parent: <no parent>
Mask: <same as sprite>

Create Event:
set Alarm 0 to 15

Alarm Event for alarm 0:
start moving in the direction of position (obj_ship.x,obj_ship.y) with speed 16

Other Event: Outside Room:
destroy the instance

Draw Event:
create a medium effect of type spark relative at (0,0) of  color 255 below objects
______________________________________________________

Information about object: obj_you_lose

Sprite: spr_you_lose
Solid: false
Visible: true
Depth: 0
Persistent: false
Parent: <no parent>
Mask: <same as sprite>

Create Event:
create instance of object obj_ship_explosion, obj_ship_explosion, obj_ship_explosion, or obj_ship_explosion at position (random(640),random(480))
create instance of object obj_ship_explosion, obj_ship_explosion, obj_ship_explosion, or obj_ship_explosion at position (random(640),random(480))
create instance of object obj_ship_explosion, obj_ship_explosion, obj_ship_explosion, or obj_ship_explosion at position (random(640),random(480))
create instance of object obj_ship_explosion, obj_ship_explosion, obj_ship_explosion, or obj_ship_explosion at position (random(640),random(480))
create instance of object obj_ship_explosion, obj_ship_explosion, obj_ship_explosion, or obj_ship_explosion at position (random(640),random(480))
create instance of object obj_ship_explosion, obj_ship_explosion, obj_ship_explosion, or obj_ship_explosion at position (random(640),random(480))
create instance of object obj_ship_explosion, obj_ship_explosion, obj_ship_explosion, or obj_ship_explosion at position (random(640),random(480))
create instance of object obj_ship_explosion, obj_ship_explosion, obj_ship_explosion, or obj_ship_explosion at position (random(640),random(480))
create instance of object obj_ship_explosion, obj_ship_explosion, obj_ship_explosion, or obj_ship_explosion at position (random(640),random(480))
set the mouse cursor to sprite <undefined> and show the windows cursor

Mouse Event for Glob Left Button:
go to room room_startup with transition effect <no effect>
______________________________________________________

Information about object: obj_poweruphealth

Sprite: spr_poweruphealth
Solid: false
Visible: true
Depth: 0
Persistent: false
Parent: <no parent>
Mask: <same as sprite>

Create Event:
start moving in directions 010000000 with speed set to 4
set variable img_speed to 5

Other Event: Outside Room:
destroy the instance
______________________________________________________

Information about object: obj_boss

Sprite: spr_boss
Solid: false
Visible: true
Depth: 0
Persistent: false
Parent: obj_parent_boss
Mask: <same as sprite>

Create Event:
call the inherited event of the parent object
set the relative path to path_boss with speed 5 and at the end reverse
set variable hits to 100
set Alarm 0 to 900

Alarm Event for alarm 0:
create instance of object obj_heatseeking, obj_heatseeking, obj_straight_down_bulllet, or obj_largeenemy at relative position (0,0)
create instance of object obj_largeenemy at relative position (0,0)
set Alarm 0 to 2000

Draw Event:
at relative position (0,0) draw image -1 of sprite spr_boss
call the inherited event of the parent object
______________________________________________________

Information about object: obj_start

Sprite: spr_start
Solid: false
Visible: true
Depth: 0
Persistent: false
Parent: <no parent>
Mask: <same as sprite>

Alarm Event for alarm 0:
go to room Main Room with transition effect Create from center

Mouse Event for Left Button:
create instance of object obj_ship_explosion at relative position (0,0)
set Alarm 0 to 30
______________________________________________________

Information about object: obj_highscore

Sprite: spr_highscore
Solid: false
Visible: true
Depth: 0
Persistent: false
Parent: <no parent>
Mask: <same as sprite>

Alarm Event for alarm 0:
show the highscore table
    background: <undefined>
     show the border
     new color: 255, other color: 0
     Font: "Times New Roman",10,0,0,0,0,0

Mouse Event for Left Button:
create instance of object obj_ship_explosion at relative position (0,0)
set Alarm 0 to 30
______________________________________________________

Information about object: obj_exit

Sprite: spr_exit
Solid: false
Visible: true
Depth: 0
Persistent: false
Parent: <no parent>
Mask: <same as sprite>

Alarm Event for alarm 0:
end the game

Mouse Event for Left Button:
create instance of object obj_ship_explosion at relative position (0,0)
set Alarm 0 to 30
______________________________________________________

Information about object: obj_parent_boss

Sprite: <no sprite>
Solid: false
Visible: true
Depth: 0
Persistent: false
Parent: <no parent>
Mask: <same as sprite>

Create Event:
set variable hits to 1
set variable showhealth to 0

Alarm Event for alarm 0:
set variable showhealth to 0

 Step Event:
if expression hits <= 0 is true
      destroy the instance
      create instance of object obj_ship_explosion at relative position (0,0)
      set the score relative to 100
with a chance of 1 out of 100 do  perform the next action
      create instance of object obj_straight_down_bulllet at relative position (0,64)
with a chance of 1 out of 300 do  perform the next action
      create instance of object obj_heatseeking at relative position (0,64)

Collision Event with object obj_bullet:
for other object: destroy the instance
create instance of object obj_enemyexplode at relative position (0,0)
set variable hits relative to -1
set variable showhealth to 1
set Alarm 0 to 30

Draw Event:
if expression showhealth == 1 is true
      set the drawing color to 255
      draw rectangle with relative vertices (-(hits * 2),0) and (hits * 2,10), filled
______________________________________________________

Information about object: spr_you_win

Sprite: spr_you_win
Solid: false
Visible: true
Depth: 0
Persistent: false
Parent: <no parent>
Mask: <same as sprite>

Create Event:
create instance of object obj_ship_explosion, obj_ship_explosion, obj_ship_explosion, or obj_ship_explosion at position (random(640),random(480))
create instance of object obj_ship_explosion, obj_ship_explosion, obj_ship_explosion, or obj_ship_explosion at position (random(640),random(480))
create instance of object obj_ship_explosion, obj_ship_explosion, obj_ship_explosion, or obj_ship_explosion at position (random(640),random(480))
create instance of object obj_ship_explosion, obj_ship_explosion, obj_ship_explosion, or obj_ship_explosion at position (random(640),random(480))
create instance of object obj_ship_explosion, obj_ship_explosion, obj_ship_explosion, or obj_ship_explosion at position (random(640),random(480))
create instance of object obj_ship_explosion, obj_ship_explosion, obj_ship_explosion, or obj_ship_explosion at position (random(640),random(480))
create instance of object obj_ship_explosion, obj_ship_explosion, obj_ship_explosion, or obj_ship_explosion at position (random(640),random(480))
create instance of object obj_ship_explosion, obj_ship_explosion, obj_ship_explosion, or obj_ship_explosion at position (random(640),random(480))
create instance of object obj_ship_explosion, obj_ship_explosion, obj_ship_explosion, or obj_ship_explosion at position (random(640),random(480))
set the mouse cursor to sprite <undefined> and show the windows cursor

Mouse Event for Glob Left Button:
go to room room_startup with transition effect <no effect>
 
duelarena.gg
Back
Top