add rock text
This commit is contained in:
parent
2df09851d9
commit
85e86033ad
Before Width: | Height: | Size: 296 B After Width: | Height: | Size: 296 B |
BIN
assets/Text_ROCK.webp
Normal file
BIN
assets/Text_ROCK.webp
Normal file
Binary file not shown.
After Width: | Height: | Size: 420 B |
42
main.js
42
main.js
|
@ -11,13 +11,18 @@ let is_img;
|
||||||
let tileMap = [
|
let tileMap = [
|
||||||
' ',
|
' ',
|
||||||
'wtwwwwwwwwwwwwww',
|
'wtwwwwwwwwwwwwww',
|
||||||
|
'wt ttttttt ttttw',
|
||||||
|
'wt itttttttitttw',
|
||||||
|
'wtt tt ttttttttw',
|
||||||
|
'wtttttttttt tttw',
|
||||||
|
'wt ttttttt ttttw',
|
||||||
'wt ttwtttt ttttw',
|
'wt ttwtttt ttttw',
|
||||||
'wttt rtt llt ttw',
|
'wttt rtt llt ttw',
|
||||||
'wtt tttt ll ttfw',
|
'wtt tttt ll ttfw',
|
||||||
'w tttaa ttwt ttw',
|
'w tttaa ttwt ttw',
|
||||||
'wttt aatt wttttw',
|
'wttt aatt wttttw',
|
||||||
'wttttttttttttttw',
|
'wttttttttttttttw',
|
||||||
'wtti tttttfitttw',
|
'wt*i@ttttt^i#ttw',
|
||||||
'wtttttttt tttttw',
|
'wtttttttt tttttw',
|
||||||
'wwwwwwwwwwwwwwww',
|
'wwwwwwwwwwwwwwww',
|
||||||
];
|
];
|
||||||
|
@ -53,11 +58,14 @@ function preload(){
|
||||||
water_img = loadImage("/assets/Water.webp");
|
water_img = loadImage("/assets/Water.webp");
|
||||||
lava_img = loadImage("/assets/Lava.webp");
|
lava_img = loadImage("/assets/Lava.webp");
|
||||||
flag_img = loadImage("/assets/Flag.webp");
|
flag_img = loadImage("/assets/Flag.webp");
|
||||||
is_img = loadImage("/assets/Text_IS_0.webp");
|
is_img = loadImage("/assets/Text_IS.webp");
|
||||||
win_img = loadImage("/assets/Win.webp");
|
win_img = loadImage("/assets/Win.webp");
|
||||||
you_img = loadImage("/assets/You.webp");
|
you_img = loadImage("/assets/You.webp");
|
||||||
move_img = loadImage("/assets/Move.webp");
|
move_img = loadImage("/assets/Move.webp");
|
||||||
stopText_img = loadImage("/assets/Stop.webp");
|
stopText_img = loadImage("/assets/Stop.webp");
|
||||||
|
|
||||||
|
baba_text_img = loadImage("/assets/Text_BABA.webp");
|
||||||
|
flag_text_img = loadImage("/assets/Text_FLAG.webp");
|
||||||
}
|
}
|
||||||
|
|
||||||
function setup(){
|
function setup(){
|
||||||
|
@ -114,10 +122,38 @@ function setup(){
|
||||||
// is
|
// is
|
||||||
let is = new Group();
|
let is = new Group();
|
||||||
is.img = is_img;
|
is.img = is_img;
|
||||||
is.collider = 'none';
|
is.collider = 'dyinamic';
|
||||||
is.tile = 'i';
|
is.tile = 'i';
|
||||||
is.scale = tileSize/is_img.width;
|
is.scale = tileSize/is_img.width;
|
||||||
|
|
||||||
|
// flag_text
|
||||||
|
let flag_text = new Group();
|
||||||
|
flag_text.img = flag_text_img;
|
||||||
|
flag_text.collider = 'dyinamic';
|
||||||
|
flag_text.tile = '^';
|
||||||
|
flag_text.scale = tileSize/flag_text_img.width;
|
||||||
|
|
||||||
|
// baba_text
|
||||||
|
let baba_text = new Group();
|
||||||
|
baba_text.img = baba_text_img;
|
||||||
|
baba_text.collider = 'dyinamic';
|
||||||
|
baba_text.tile = '*';
|
||||||
|
baba_text.scale = tileSize/baba_text_img.width;
|
||||||
|
|
||||||
|
// you
|
||||||
|
let you = new Group();
|
||||||
|
you.img = you_img;
|
||||||
|
you.collider = 'dyinamic';
|
||||||
|
you.tile = '@';
|
||||||
|
you.scale = tileSize/you_img.width;
|
||||||
|
|
||||||
|
// win
|
||||||
|
let win_text = new Group();
|
||||||
|
win_text.img = win_img;
|
||||||
|
win_text.collider = 'dyinamic';
|
||||||
|
win_text.tile = '#';
|
||||||
|
win_text.scale = tileSize/win_img.width;
|
||||||
|
|
||||||
new Tiles(tileMap, tileSize/2, tileSize/2, tileSize, tileSize);
|
new Tiles(tileMap, tileSize/2, tileSize/2, tileSize, tileSize);
|
||||||
|
|
||||||
//BABA
|
//BABA
|
||||||
|
|
Loading…
Reference in New Issue
Block a user