我对 Inform 很陌生,看起来这应该不会太难做到,但我还没有找到方法。我想根据玩家来自哪里来更改房间的描述。大致如下:
The Town Square is a room. "As you enter the small town square, [if yourself came from West]
the rising sun makes silhouettes of the roofs and spires to the East.[otherwise]your long
shadow strides before you as the Sun rises behind.[end if]"
最好的方法是什么?
我找到了一个合理的解决方案:
The last location is a room that varies.
Orientation is a direction that varies.
Before going to anywhere, now the last location is the location of the player.
After going to anywhere:
now orientation is the best route from the last location to the location, using even locked doors;
continue the action.
The Town Square is a room. "As you enter the small town square, [if orientation is east]
the rising Sun makes silhouettes of the roofs and spires to the East.[otherwise if orientation is west]
your long shadow strides before you as the Sun rises behind.[end if]"
"使用甚至锁定的门"修改器可确保即使门关闭并锁定在玩家身后也能正常工作。该解决方案确实假设玩家是通过可逆路线来的,这可能并不总是如此,例如,如果玩家已经传送。