corrected 'treat unidentified variables as zero' errors and other conversion errors
This commit is contained in:
parent
5a9989d1d1
commit
2fc68a5c96
|
@ -139,7 +139,7 @@
|
|||
],
|
||||
"IncludedFiles": [],
|
||||
"MetaData": {
|
||||
"IDEVersion": "2.3.2.556",
|
||||
"IDEVersion": "2.3.2.560",
|
||||
},
|
||||
"resourceVersion": "1.4",
|
||||
"name": "Infinity",
|
||||
|
|
|
@ -0,0 +1,3 @@
|
|||
global.number = 0;
|
||||
global.gameover = 0;
|
||||
global.game = 0;
|
|
@ -40,32 +40,32 @@ draw_text(__view_get( e__VW.XView, 0 )+124,__view_get( e__VW.YView, 0 )+27,strin
|
|||
draw_set_font(fnt_arial_s8_italic);
|
||||
draw_text(__view_get( e__VW.XView, 0 )+350+160,__view_get( e__VW.YView, 0 )+340+160,string_hash_to_newline(((900+50*global.level)-global.time)/30));
|
||||
|
||||
if global.message = 4
|
||||
if global.messages = 4
|
||||
{
|
||||
scr_messages("HP increase! +25 Max HP");
|
||||
}
|
||||
if global.message = 5
|
||||
if global.messages = 5
|
||||
{
|
||||
scr_messages("Wave Complete!");
|
||||
}
|
||||
if global.message = 6
|
||||
if global.messages = 6
|
||||
{
|
||||
scr_messages("Game Over... Tap to continue...");
|
||||
global.gameover = 1;
|
||||
}
|
||||
if global.message = 7
|
||||
if global.messages = 7
|
||||
{
|
||||
scr_messages("Welcome to INFINITY!");
|
||||
}
|
||||
if global.message = 8
|
||||
if global.messages = 8
|
||||
{
|
||||
scr_messages("You can move by pressing the arrow keys");
|
||||
}
|
||||
if global.message = 9
|
||||
if global.messages = 9
|
||||
{
|
||||
scr_messages("and use powerup items by pressing the spacebar!");
|
||||
}
|
||||
if global.message = 10
|
||||
if global.messages = 10
|
||||
{
|
||||
scr_messages("Well, have fun~<3");
|
||||
}
|
||||
|
@ -75,20 +75,20 @@ if global.gameover = 1
|
|||
}
|
||||
if global.game = 20
|
||||
{
|
||||
screen_refresh();
|
||||
mouse_wait();
|
||||
// screen_refresh();
|
||||
// mouse_wait();
|
||||
io_clear();
|
||||
}
|
||||
|
||||
|
||||
var __b__;
|
||||
__b__ = action_if_variable(global.game, 20, 0);
|
||||
if __b__
|
||||
{
|
||||
{
|
||||
obsolete(-1, 1, 255, 0, Arial,10,0,0,1,0,0);
|
||||
|
||||
var __b__;
|
||||
__b__ = action_if_variable(global.game, 20, 0);
|
||||
if __b__
|
||||
{
|
||||
{
|
||||
//obsolete(-1, 1, 255, 0, Arial,10,0,0,1,0,0); //show_highscore()
|
||||
sound_stop_all()
|
||||
|
||||
action_restart_game();
|
||||
}
|
||||
}
|
||||
|
||||
action_restart_game();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -19,6 +19,7 @@
|
|||
"physicsShapePoints": [],
|
||||
"eventList": [
|
||||
{"isDnD":false,"eventNum":0,"eventType":8,"collisionObjectId":null,"resourceVersion":"1.0","name":"","tags":[],"resourceType":"GMEvent",},
|
||||
{"isDnD":false,"eventNum":0,"eventType":0,"collisionObjectId":null,"resourceVersion":"1.0","name":"","tags":[],"resourceType":"GMEvent",},
|
||||
],
|
||||
"properties": [],
|
||||
"overriddenProperties": [],
|
||||
|
|
|
@ -1,3 +1,3 @@
|
|||
global.message = 8;
|
||||
global.messages = 8;
|
||||
alarm[2] = 105;
|
||||
|
||||
|
|
|
@ -1,3 +1,3 @@
|
|||
global.message = 9;
|
||||
global.messages = 9;
|
||||
alarm[3] = 105;
|
||||
|
||||
|
|
|
@ -1,2 +1,2 @@
|
|||
global.message = 10;
|
||||
global.messages = 10;
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
action_timeline_set(tml_muse, 0, 0, 1);
|
||||
action_timeline_set(tml_muse, 0, 0, 1);
|
||||
sound_stop_all();
|
||||
alarm[7] = 10;
|
||||
|
||||
|
@ -12,7 +12,8 @@ global.dragon_left = -9;
|
|||
|
||||
alarm[0] = global.droprate;
|
||||
|
||||
global.message = 7;
|
||||
global.messages = 7;
|
||||
|
||||
alarm[1] = 100;
|
||||
|
||||
|
||||
global.time = 0;
|
|
@ -10,7 +10,7 @@ if global.time >= 900+50*global.level
|
|||
global.level += 1;
|
||||
score += 5000*ceil(1.75*global.level);
|
||||
global.dragon_left += 1;
|
||||
global.message = 5;
|
||||
global.messages = 5;
|
||||
}
|
||||
global.droprate = 1800;
|
||||
|
||||
|
|
|
@ -1,5 +1,8 @@
|
|||
{
|
||||
"spriteId": null,
|
||||
"spriteId": {
|
||||
"name": "mnu_start",
|
||||
"path": "sprites/mnu_start/mnu_start.yy",
|
||||
},
|
||||
"solid": false,
|
||||
"visible": true,
|
||||
"spriteMaskId": null,
|
||||
|
|
|
@ -1,2 +1,4 @@
|
|||
hp = 20;
|
||||
|
||||
|
||||
step = 0;
|
||||
shielded = 0;
|
|
@ -1,28 +1,30 @@
|
|||
step += 1;
|
||||
if step > 4
|
||||
{
|
||||
if distance_to_object(obj_player_control) < 250
|
||||
{
|
||||
step = 0
|
||||
ID = instance_create(x,y,obj_enemy_beams);
|
||||
with (ID) motion_set(other.direction-5+random(10),10);
|
||||
}
|
||||
}
|
||||
|
||||
speed = 6;
|
||||
if hp < 1
|
||||
{
|
||||
score += 500;
|
||||
instance_destroy();
|
||||
}
|
||||
|
||||
if point_direction(x,y,obj_player_control.x,obj_player_control.y) > direction
|
||||
{
|
||||
direction += 5;
|
||||
}
|
||||
if point_direction(x,y,obj_player_control.x,obj_player_control.y) < direction
|
||||
{
|
||||
direction -= 5;
|
||||
}
|
||||
speed = 6;
|
||||
if (instance_exists( obj_player_control ) ) {
|
||||
if step > 4
|
||||
{
|
||||
if distance_to_object(obj_player_control) < 250
|
||||
{
|
||||
step = 0
|
||||
var ID = instance_create(x,y,obj_enemy_beams);
|
||||
with (ID) motion_set(other.direction-5+random(10),10);
|
||||
}
|
||||
}
|
||||
|
||||
if point_direction(x,y,obj_player_control.x,obj_player_control.y) > direction
|
||||
{
|
||||
direction += 5;
|
||||
}
|
||||
if point_direction(x,y,obj_player_control.x,obj_player_control.y) < direction
|
||||
{
|
||||
direction -= 5;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -1,2 +1,4 @@
|
|||
hp = 3;
|
||||
|
||||
|
||||
rotations = 0;
|
||||
shielded = 0;
|
|
@ -3,16 +3,16 @@ if hp < 1
|
|||
score += 200;
|
||||
instance_destroy();
|
||||
}
|
||||
if (instance_exists( obj_player_control ) ) {
|
||||
if (point_distance(x,y,obj_player_control.x,obj_player_control.y) < 32)
|
||||
{
|
||||
speed = 0;
|
||||
if global.shield < 1
|
||||
{
|
||||
global.player_hp -= 7;
|
||||
}
|
||||
exit;
|
||||
}
|
||||
move_towards_point(obj_player_control.x,obj_player_control.y,6);
|
||||
}
|
||||
|
||||
if (point_distance(x,y,obj_player_control.x,obj_player_control.y) < 32)
|
||||
{
|
||||
speed = 0;
|
||||
if global.shield < 1
|
||||
{
|
||||
global.player_hp -= 7;
|
||||
}
|
||||
exit;
|
||||
}
|
||||
move_towards_point(obj_player_control.x,obj_player_control.y,6);
|
||||
|
||||
|
||||
|
|
|
@ -1,2 +1,4 @@
|
|||
hp = 100;
|
||||
|
||||
|
||||
firing = 0;
|
||||
shielded = 0;
|
|
@ -3,19 +3,20 @@ if hp < 1
|
|||
score += 2000
|
||||
instance_destroy();
|
||||
}
|
||||
|
||||
direction = point_direction(x,y,obj_player_control.x,obj_player_control.y)
|
||||
if (point_distance(x,y,obj_player_control.x,obj_player_control.y) < 125)
|
||||
{
|
||||
firing = 1;
|
||||
speed = 0;
|
||||
if global.shield < 1
|
||||
{
|
||||
global.player_hp -= 5
|
||||
}
|
||||
hp -= 1
|
||||
exit;
|
||||
if (instance_exists( obj_player_control) ) {
|
||||
direction = point_direction(x,y,obj_player_control.x,obj_player_control.y)
|
||||
if (point_distance(x,y,obj_player_control.x,obj_player_control.y) < 125)
|
||||
{
|
||||
firing = 1;
|
||||
speed = 0;
|
||||
if global.shield < 1
|
||||
{
|
||||
global.player_hp -= 5
|
||||
}
|
||||
hp -= 1
|
||||
exit;
|
||||
}
|
||||
move_towards_point(obj_player_control.x,obj_player_control.y,4);
|
||||
}
|
||||
firing = 0
|
||||
|
||||
|
||||
|
|
|
@ -1,2 +1,5 @@
|
|||
hp = 250;
|
||||
|
||||
|
||||
final = 0;
|
||||
shield = 0;
|
||||
shielded = 0;
|
|
@ -1,31 +1,32 @@
|
|||
if distance_to_object(obj_player_control) < 350
|
||||
{
|
||||
final += 1
|
||||
if final = 2
|
||||
{
|
||||
ID = instance_create(x,y,obj_enemy_beams)
|
||||
with (ID) motion_set(other.direction-10+random(20),10)
|
||||
final = 0
|
||||
}
|
||||
}
|
||||
if (instance_exists( obj_player_control ) ) {
|
||||
if distance_to_object(obj_player_control) < 350
|
||||
{
|
||||
final += 1
|
||||
if final = 2
|
||||
{
|
||||
var ID = instance_create(x,y,obj_enemy_beams)
|
||||
with (ID) motion_set(other.direction-10+random(20),10)
|
||||
final = 0
|
||||
}
|
||||
}
|
||||
if point_direction(x,y,obj_player_control.x,obj_player_control.y) > direction
|
||||
{
|
||||
direction += 4
|
||||
}
|
||||
if point_direction(x,y,obj_player_control.x,obj_player_control.y) < direction
|
||||
{
|
||||
direction -= 4
|
||||
}
|
||||
}
|
||||
speed = 5
|
||||
direction = direction
|
||||
|
||||
if hp < 1
|
||||
{
|
||||
score += 10000;
|
||||
instance_destroy();
|
||||
}
|
||||
|
||||
shield += 1
|
||||
if point_direction(x,y,obj_player_control.x,obj_player_control.y) > direction
|
||||
{
|
||||
direction += 4
|
||||
}
|
||||
if point_direction(x,y,obj_player_control.x,obj_player_control.y) < direction
|
||||
{
|
||||
direction -= 4
|
||||
}
|
||||
speed = 5
|
||||
direction = direction
|
||||
if shield >= 450
|
||||
{
|
||||
shielded = 1
|
||||
|
@ -35,4 +36,4 @@ if shield >= 600
|
|||
shielded = 0
|
||||
shield = 0
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -1,2 +1,9 @@
|
|||
hp = 100
|
||||
|
||||
|
||||
firetime = 0;
|
||||
stepy = 0;
|
||||
charge = 0;
|
||||
firing = 0;
|
||||
firetime = 0;
|
||||
rot = 0;
|
||||
shielded = 0;
|
|
@ -18,21 +18,21 @@ if firetime > 200
|
|||
speed = 0
|
||||
if stepy > 4
|
||||
{
|
||||
ID = instance_create(x,y,obj_enemy_beams);
|
||||
var ID = instance_create(x,y,obj_enemy_beams);
|
||||
with (ID) motion_set(other.rot-20,10);
|
||||
ID = instance_create(x,y,obj_enemy_beams);
|
||||
var ID = instance_create(x,y,obj_enemy_beams);
|
||||
with (ID) motion_set(other.rot+25,10);
|
||||
ID = instance_create(x,y,obj_enemy_beams);
|
||||
var ID = instance_create(x,y,obj_enemy_beams);
|
||||
with (ID) motion_set(other.rot+70,10);
|
||||
ID = instance_create(x,y,obj_enemy_beams);
|
||||
var ID = instance_create(x,y,obj_enemy_beams);
|
||||
with (ID) motion_set(other.rot+115,10);
|
||||
ID = instance_create(x,y,obj_enemy_beams);
|
||||
var ID = instance_create(x,y,obj_enemy_beams);
|
||||
with (ID) motion_set(other.rot+160,10);
|
||||
ID = instance_create(x,y,obj_enemy_beams);
|
||||
var ID = instance_create(x,y,obj_enemy_beams);
|
||||
with (ID) motion_set(other.rot+205,10);
|
||||
ID = instance_create(x,y,obj_enemy_beams);
|
||||
var ID = instance_create(x,y,obj_enemy_beams);
|
||||
with (ID) motion_set(other.rot+250,10);
|
||||
ID = instance_create(x,y,obj_enemy_beams);
|
||||
var ID = instance_create(x,y,obj_enemy_beams);
|
||||
with (ID) motion_set(other.rot+295,10);
|
||||
stepy = 0
|
||||
}
|
||||
|
@ -45,8 +45,8 @@ if firetime > 200
|
|||
}
|
||||
}
|
||||
firetime += 1
|
||||
if firing < 1
|
||||
if firing < 1 && instance_exists( obj_player_control )
|
||||
{
|
||||
move_towards_point(obj_player_control.x,obj_player_control.y,3)
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -1,2 +1,5 @@
|
|||
alarm[0] = 25
|
||||
|
||||
|
||||
rng = 0;
|
||||
spawned = 0;
|
||||
p = 0;
|
|
@ -6,4 +6,3 @@ if p >= ceil(125/global.level)
|
|||
|
||||
draw_set_color(c_white)
|
||||
draw_circle(x,y,p*global.level,true)
|
||||
|
||||
|
|
|
@ -1,20 +1,20 @@
|
|||
action_set_relative(1);
|
||||
var __b__;
|
||||
__b__ = action_if_variable(other.shielded, 0, 0);
|
||||
if __b__
|
||||
{
|
||||
{
|
||||
with (other) {
|
||||
hp += -1;
|
||||
}
|
||||
__b__ = action_if_variable(global.hypertime, 0, 2);
|
||||
if __b__
|
||||
{
|
||||
with (other) {
|
||||
hp += -4;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
action_kill_object();
|
||||
action_set_relative(0);
|
||||
action_set_relative(1);
|
||||
var __b__;
|
||||
__b__ = action_if_variable(other.shielded, 0, 0);
|
||||
if __b__
|
||||
{
|
||||
{
|
||||
with (other) {
|
||||
hp += -1;
|
||||
}
|
||||
__b__ = action_if_variable(global.hypertime, 0, 2);
|
||||
if __b__
|
||||
{
|
||||
with (other) {
|
||||
hp += -4;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
action_kill_object();
|
||||
action_set_relative(0);
|
||||
|
|
|
@ -1 +1,6 @@
|
|||
action_set_friction(.5);
|
||||
action_set_friction(.5);
|
||||
global.nova_time = 0;
|
||||
global.hypertime = 0;
|
||||
global.shield = 0;
|
||||
press = 0;
|
||||
frame = 0;
|
|
@ -1 +1 @@
|
|||
global.message = 6;
|
||||
global.messages = 6;
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
numero = 0;
|
|
@ -19,6 +19,7 @@
|
|||
"physicsShapePoints": [],
|
||||
"eventList": [
|
||||
{"isDnD":false,"eventNum":0,"eventType":8,"collisionObjectId":null,"resourceVersion":"1.0","name":"","tags":[],"resourceType":"GMEvent",},
|
||||
{"isDnD":false,"eventNum":0,"eventType":0,"collisionObjectId":null,"resourceVersion":"1.0","name":"","tags":[],"resourceType":"GMEvent",},
|
||||
],
|
||||
"properties": [],
|
||||
"overriddenProperties": [],
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
numero = 0;
|
|
@ -19,6 +19,7 @@
|
|||
"physicsShapePoints": [],
|
||||
"eventList": [
|
||||
{"isDnD":false,"eventNum":0,"eventType":8,"collisionObjectId":null,"resourceVersion":"1.0","name":"","tags":[],"resourceType":"GMEvent",},
|
||||
{"isDnD":false,"eventNum":0,"eventType":0,"collisionObjectId":null,"resourceVersion":"1.0","name":"","tags":[],"resourceType":"GMEvent",},
|
||||
],
|
||||
"properties": [],
|
||||
"overriddenProperties": [],
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
numero = 0;
|
|
@ -19,6 +19,7 @@
|
|||
"physicsShapePoints": [],
|
||||
"eventList": [
|
||||
{"isDnD":false,"eventNum":0,"eventType":8,"collisionObjectId":null,"resourceVersion":"1.0","name":"","tags":[],"resourceType":"GMEvent",},
|
||||
{"isDnD":false,"eventNum":0,"eventType":0,"collisionObjectId":null,"resourceVersion":"1.0","name":"","tags":[],"resourceType":"GMEvent",},
|
||||
],
|
||||
"properties": [],
|
||||
"overriddenProperties": [],
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
numero = 0;
|
|
@ -19,6 +19,7 @@
|
|||
"physicsShapePoints": [],
|
||||
"eventList": [
|
||||
{"isDnD":false,"eventNum":0,"eventType":8,"collisionObjectId":null,"resourceVersion":"1.0","name":"","tags":[],"resourceType":"GMEvent",},
|
||||
{"isDnD":false,"eventNum":0,"eventType":0,"collisionObjectId":null,"resourceVersion":"1.0","name":"","tags":[],"resourceType":"GMEvent",},
|
||||
],
|
||||
"properties": [],
|
||||
"overriddenProperties": [],
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
],
|
||||
"layers": [
|
||||
{"instances":[
|
||||
{"properties":[],"isDnd":false,"objectId":null,"inheritCode":false,"hasCreationCode":false,"colour":4294967295,"rotation":0.0,"scaleX":1.0,"scaleY":1.0,"imageIndex":0,"imageSpeed":1.0,"inheritedItemId":null,"frozen":false,"ignore":false,"inheritItemSettings":false,"x":256.0,"y":368.0,"resourceVersion":"1.0","name":"inst_E5144118","tags":[],"resourceType":"GMRInstance",},
|
||||
{"properties":[],"isDnd":false,"objectId":{"name":"mnu_start_objects","path":"objects/mnu_start_objects/mnu_start_objects.yy",},"inheritCode":false,"hasCreationCode":false,"colour":4294967295,"rotation":0.0,"scaleX":1.0,"scaleY":1.0,"imageIndex":0,"imageSpeed":1.0,"inheritedItemId":null,"frozen":false,"ignore":false,"inheritItemSettings":false,"x":256.0,"y":368.0,"resourceVersion":"1.0","name":"inst_E5144118","tags":[],"resourceType":"GMRInstance",},
|
||||
],"visible":true,"depth":0,"userdefinedDepth":false,"inheritLayerDepth":false,"inheritLayerSettings":false,"gridX":32,"gridY":32,"layers":[],"hierarchyFrozen":false,"resourceVersion":"1.0","name":"Compatibility_Instances","tags":[],"resourceType":"GMRInstanceLayer",},
|
||||
{"assets":[
|
||||
{"spriteId":{"name":"bg_titlescreen","path":"sprites/bg_titlescreen/bg_titlescreen.yy",},"w":480,"h":320,"u0":0,"v0":0,"u1":480,"v1":320,"colour":4294967295,"inheritedItemId":null,"frozen":false,"ignore":false,"inheritItemSettings":false,"x":96.0,"y":32.0,"resourceVersion":"1.0","name":"tile_BC45D95E","tags":[],"resourceType":"GMRGraphic",},
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
function scr_messages(argument0) {
|
||||
//displays a message on screen for 1 second, with a fade in and out
|
||||
global.number += 1
|
||||
draw_set_font(fnt_arial_s6_italic)
|
||||
draw_set_font(fnt_arial_s8_italic)
|
||||
draw_set_color(c_white)
|
||||
draw_set_alpha(.05*global.number)
|
||||
if global.number >= 50
|
||||
|
@ -12,7 +12,7 @@ function scr_messages(argument0) {
|
|||
if global.number >= 100
|
||||
{
|
||||
global.number = 0
|
||||
global.message = 0
|
||||
global.messages = 0
|
||||
}
|
||||
draw_set_alpha(1)
|
||||
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
function scr_pointsparticle(argument0) {
|
||||
//displays the points on screen for 1 second, with a fade in and out
|
||||
//copyright 2010 Fenyxtec Studios
|
||||
//original code by William Hogueison
|
||||
//copyright 2010 Studio Tinyleaf
|
||||
//original code by Jennifer Hogueison
|
||||
|
||||
numero += 1
|
||||
draw_set_font(fnt_arial_s5_italic)
|
||||
draw_set_font(fnt_arial_s8_italic)
|
||||
draw_set_color(c_white)
|
||||
draw_set_alpha(.2*numero)
|
||||
if numero >= 30
|
||||
|
|
|
@ -168,7 +168,7 @@
|
|||
{"id":"673662b9-406f-4a28-bfdb-2b234e254320","Key":31.0,"Length":1.0,"Stretch":false,"Disabled":false,"IsCreationKey":false,"Channels":{"0":{"Id":{"name":"2eba3c63-cde5-4c84-9eae-840e22b7bf5f","path":"sprites/mnu_start/mnu_start.yy",},"resourceVersion":"1.0","resourceType":"SpriteFrameKeyframe",},},"resourceVersion":"1.0","resourceType":"Keyframe<SpriteFrameKeyframe>",},
|
||||
],"resourceVersion":"1.0","resourceType":"KeyframeStore<SpriteFrameKeyframe>",},"trackColour":0,"inheritsTrackColour":true,"builtinName":0,"traits":0,"interpolation":1,"tracks":[],"events":[],"modifiers":[],"isCreationTrack":false,"resourceVersion":"1.0","tags":[],"resourceType":"GMSpriteFramesTrack",},
|
||||
],
|
||||
"visibleRange": {"x":0.0,"y":0.0,},
|
||||
"visibleRange": null,
|
||||
"lockOrigin": false,
|
||||
"showBackdrop": true,
|
||||
"showBackdropImage": false,
|
||||
|
|
Loading…
Reference in New Issue