Allow simple item bestowal when facing the level edge, too

This commit is contained in:
Eevee (Evelyn Woods) 2021-02-04 20:34:53 -07:00
parent d5fd7b546d
commit c7012f2565

View File

@ -26,9 +26,7 @@ function on_begin_force_floor(me, level) {
// doing this here; decision time hasn't happened yet, but we need to know what direction we're // doing this here; decision time hasn't happened yet, but we need to know what direction we're
// moving to know whether bestowal happens? so what IS the cause of item bestowal? // moving to know whether bestowal happens? so what IS the cause of item bestowal?
let neighbor = level.get_neighboring_cell(me.cell, actor.direction); let neighbor = level.get_neighboring_cell(me.cell, actor.direction);
if (! neighbor) if (neighbor && neighbor.try_entering(actor, actor.direction, level))
return;
if (neighbor.try_entering(actor, actor.direction, level))
return; return;
let item = me.cell.get_item(); let item = me.cell.get_item();
if (! item) if (! item)