CommitLog |
This commit is contained in:
parent
29110d6a69
commit
71f77f2ae9
9 changed files with 166 additions and 29 deletions
|
@ -59,6 +59,33 @@ if(speed > 0)
|
|||
{
|
||||
speed -= 1
|
||||
}
|
||||
|
||||
|
||||
pull_towards_black_holes();
|
||||
</string>
|
||||
</argument>
|
||||
</arguments>
|
||||
</action>
|
||||
</event>
|
||||
<event eventtype="4" ename="obj_black_hole">
|
||||
<action>
|
||||
<libid>1</libid>
|
||||
<id>603</id>
|
||||
<kind>7</kind>
|
||||
<userelative>0</userelative>
|
||||
<isquestion>0</isquestion>
|
||||
<useapplyto>-1</useapplyto>
|
||||
<exetype>2</exetype>
|
||||
<functionname></functionname>
|
||||
<codestring></codestring>
|
||||
<whoName>self</whoName>
|
||||
<relative>0</relative>
|
||||
<isnot>0</isnot>
|
||||
<arguments>
|
||||
<argument>
|
||||
<kind>1</kind>
|
||||
<string>instance_create(x,y,obj_boom_fx)
|
||||
instance_destroy(id);
|
||||
</string>
|
||||
</argument>
|
||||
</arguments>
|
||||
|
|
|
@ -50,6 +50,7 @@
|
|||
<argument>
|
||||
<kind>1</kind>
|
||||
<string>image_angle += 1;
|
||||
|
||||
</string>
|
||||
</argument>
|
||||
</arguments>
|
||||
|
|
|
@ -35,9 +35,9 @@ for(var xx = 0; xx < CHUNK_SIZE*TILE_SIZE; xx+= TILE_SIZE)
|
|||
{
|
||||
for(var yy = 0; yy < CHUNK_SIZE*TILE_SIZE; yy+= TILE_SIZE)
|
||||
{
|
||||
var rnd = random_range(0,1000);
|
||||
var rnd = random_range(0,5000);
|
||||
|
||||
if(floor(rnd) == 500)
|
||||
if(floor(rnd) == 1000)
|
||||
{
|
||||
if(hasGeneratedBlackHole)
|
||||
continue;
|
||||
|
|
|
@ -94,37 +94,13 @@ for(var i = 0; i < 16; i ++)
|
|||
<kind>1</kind>
|
||||
<string>/// Load Chunks
|
||||
|
||||
var playX = obj_player.x;
|
||||
var playY = obj_player.y;
|
||||
|
||||
var chunk_total_size = (CHUNK_SIZE*TILE_SIZE);
|
||||
var chunkCoords = get_chunk_coords(obj_player.x,obj_player.y);
|
||||
|
||||
var chunkRelX = playX % chunk_total_size;
|
||||
var chunkRelY = playY % chunk_total_size;
|
||||
var chunkX = chunkCoords[0];
|
||||
var chunkY = chunkCoords[1];
|
||||
|
||||
var chunkX = (obj_player.x - chunkRelX);
|
||||
var chunkY = (obj_player.y - chunkRelY);
|
||||
// Fix annoyances where % negative = positive
|
||||
|
||||
if(chunkX < 0)
|
||||
{
|
||||
chunkX -= chunk_total_size;
|
||||
}
|
||||
|
||||
if(chunkY < 0)
|
||||
{
|
||||
chunkY -= chunk_total_size;
|
||||
}
|
||||
|
||||
if(chunkY == 0 && (playY < 0 && playY >= chunk_total_size/-1) )
|
||||
{
|
||||
chunkY = chunk_total_size/-1;
|
||||
}
|
||||
|
||||
if(chunkX == 0 && (playX < 0 && playX >= chunk_total_size/-1) )
|
||||
{
|
||||
chunkX = chunk_total_size/-1;
|
||||
}
|
||||
chunkX -= chunk_total_size;
|
||||
chunkY -= chunk_total_size;
|
||||
// Load Chunks
|
||||
|
|
|
@ -80,6 +80,7 @@ if(hp <= 0)
|
|||
}
|
||||
|
||||
direction = image_angle
|
||||
speed = floor(speed);
|
||||
|
||||
if(speed < 0)
|
||||
{
|
||||
|
@ -133,6 +134,51 @@ if(invuln_counter != invuln_counter_max)
|
|||
}
|
||||
|
||||
|
||||
</string>
|
||||
</argument>
|
||||
</arguments>
|
||||
</action>
|
||||
<action>
|
||||
<libid>1</libid>
|
||||
<id>603</id>
|
||||
<kind>7</kind>
|
||||
<userelative>0</userelative>
|
||||
<isquestion>0</isquestion>
|
||||
<useapplyto>-1</useapplyto>
|
||||
<exetype>2</exetype>
|
||||
<functionname></functionname>
|
||||
<codestring></codestring>
|
||||
<whoName>self</whoName>
|
||||
<relative>0</relative>
|
||||
<isnot>0</isnot>
|
||||
<arguments>
|
||||
<argument>
|
||||
<kind>1</kind>
|
||||
<string>///pull_towards_black_holes();
|
||||
pull_towards_black_holes();
|
||||
</string>
|
||||
</argument>
|
||||
</arguments>
|
||||
</action>
|
||||
</event>
|
||||
<event eventtype="4" ename="obj_black_hole">
|
||||
<action>
|
||||
<libid>1</libid>
|
||||
<id>603</id>
|
||||
<kind>7</kind>
|
||||
<userelative>0</userelative>
|
||||
<isquestion>0</isquestion>
|
||||
<useapplyto>-1</useapplyto>
|
||||
<exetype>2</exetype>
|
||||
<functionname></functionname>
|
||||
<codestring></codestring>
|
||||
<whoName>self</whoName>
|
||||
<relative>0</relative>
|
||||
<isnot>0</isnot>
|
||||
<arguments>
|
||||
<argument>
|
||||
<kind>1</kind>
|
||||
<string>damage_player(hp_max);
|
||||
</string>
|
||||
</argument>
|
||||
</arguments>
|
||||
|
|
Reference in a new issue