unit sprites and a buncha other stuff

This commit is contained in:
the me 2022-08-15 19:04:23 -07:00
parent e45eb49492
commit a537ea5cf2
37 changed files with 516 additions and 17 deletions

View file

@ -44,7 +44,7 @@ function st_moving() {
var guy = c_gettile(x, y, true);
c_colortile(guy.x, guy.y, c_green);
//log("selecting");
var rng = [1];
//var rng = [1];
var guy = c_gettile(x, y, true);
var hitting = noone;
if guy != noone {
@ -52,19 +52,30 @@ function st_moving() {
case DIR.LEFT:
hitting = c_gettile(guy.x-1, guy.y);
c_colortile(guy.x-1, guy.y, c_red);
sprite_index = data.down;
image_xscale = -1;
break;
case DIR.DOWN:
hitting = c_gettile(guy.x, guy.y+1);
c_colortile(guy.x, guy.y+1, c_red);
sprite_index = data.down;
break;
case DIR.UP:
hitting = c_gettile(guy.x, guy.y-1);
c_colortile(guy.x, guy.y-1, c_red);
sprite_index = data.up;
break;
case DIR.RIGHT:
hitting = c_gettile(guy.x+1, guy.y);
c_colortile(guy.x+1, guy.y, c_red);
sprite_index = data.down;
image_xscale = 1;
break;
default:
sprite_index = data.idle;
image_xscale = -1;
break;
}
if hitting != noone && select {
log("found one");