Steam telepítése
belépés
|
nyelv
简体中文 (egyszerűsített kínai)
繁體中文 (hagyományos kínai)
日本語 (japán)
한국어 (koreai)
ไทย (thai)
Български (bolgár)
Čeština (cseh)
Dansk (dán)
Deutsch (német)
English (angol)
Español - España (spanyolországi spanyol)
Español - Latinoamérica (latin-amerikai spanyol)
Ελληνικά (görög)
Français (francia)
Italiano (olasz)
Bahasa Indonesia (indonéz)
Nederlands (holland)
Norsk (norvég)
Polski (lengyel)
Português (portugáliai portugál)
Português - Brasil (brazíliai portugál)
Română (román)
Русский (orosz)
Suomi (finn)
Svenska (svéd)
Türkçe (török)
Tiếng Việt (vietnámi)
Українська (ukrán)
Fordítási probléma jelentése
Create event:
if place_meeting(x, y, obj_block)
{
// your code to spawn another block
instance_destroy();
}
Or you can try move the block until it's not colliding anything
Create event:
while(place_meeting(x, y, obj_block))
{
x = random_range(// horizontal limit of the spawn area)
y = random_range(// vertical limit of the spawn area)
}
Or check if there is nothing before you create the block
Block spawner:
var xx = random_range(// vertical limit of the spawn area)
var yy = random_range(// vertical limit of the spawn area)
if place_free(xx, yy) instance_create(xx, yy, obj_block)
Tyvm, this one seems to have gotten the results I was looking for :D
I was pretty sure that it was along the lines of something like this.
Had to edit my spawning code a little to avoid errors that would lead to auto crashing the game upon destroying one of the blocks, but they are now only spawning within pixels of each other and no longer touching :D