init
This commit is contained in:
commit
0556f63d2d
119 changed files with 2908 additions and 0 deletions
36
objects/obglobal/Create_0.gml
Normal file
36
objects/obglobal/Create_0.gml
Normal file
|
|
@ -0,0 +1,36 @@
|
|||
randomize(); //рандомизировать...рандом.
|
||||
|
||||
stars = round(sqrt(room_width * room_height / 100) ) + irandom_range(50, 75)
|
||||
|
||||
global.bindAccelerate = ord("W");
|
||||
global.bindDeaccelerate = ord("S");
|
||||
global.bindFire = vk_space;
|
||||
global.bindTurnLeft = ord("A");
|
||||
global.bindTurnRight = ord("D");
|
||||
global.bindTurbo = vk_lshift;
|
||||
|
||||
global.movementType = 0;//0 - мышь, 1 - клава
|
||||
global.money = 0;
|
||||
|
||||
global.playerColor = make_color_hsv(random(255), irandom_range(128, 255), 255);
|
||||
global.faction1Color = make_color_hsv(random(255), irandom_range(128, 255), 255);
|
||||
global.faction2Color = make_color_hsv(random(255), irandom_range(128, 255), 255);
|
||||
|
||||
repeat(stars)
|
||||
{
|
||||
instance_create_layer(random(room_width), random(room_height), "Stars", obStar); //создание звёзд на фоне
|
||||
}
|
||||
|
||||
if room = rMain
|
||||
{
|
||||
spaceship = instance_create_layer(room_width/2, room_height/2, "Instances", obSpaceship); //создание корабля
|
||||
cursor = instance_create_layer(x, y, "Instances", obCursor); // создание курсора
|
||||
station1 = instance_create_layer(irandom_range(576, room_width-576), irandom_range(576, room_height-576), "Instances", obSpacestation); //1 станция
|
||||
}
|
||||
|
||||
window_set_cursor(cr_none); //прячет оригинальный курсор
|
||||
|
||||
repeat(5)
|
||||
{
|
||||
instance_create_layer(random(room_width), random(room_height), "Instances", obEnemy)
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue