Home API Manuals About Forum
Toggle Dark/Light/Auto mode Toggle Dark/Light/Auto mode Toggle Dark/Light/Auto mode Back to homepage

moveThroughNPC

Sets the minimum stamina required to step onto a tile occupied by a mobile (NPC or player). If the character’s current stamina is below this value, the mobile is treated as impassable by the pathfinder.

In Ultima Online, walking through another mobile consumes stamina. This variable controls the threshold below which the pathfinder considers the step impossible and routes around the mobile instead.

Default value: 1000 (effectively treats mobiles as impassable unless stamina is very high).

In Python, use GetMoveThroughNPC() / SetMoveThroughNPC(value).

Задаёт минимальное количество stamina, необходимое для шага на тайл, занятый мобайлом (NPC или игроком). Если текущая stamina персонажа ниже этого значения, мобайл считается непроходимым для поиска пути.

В Ultima Online прохождение через другого мобайла расходует stamina. Эта переменная задаёт порог, ниже которого поиск пути считает шаг невозможным и прокладывает маршрут в обход мобайла.

Значение по умолчанию: 1000 (фактически делает мобайлов непроходимыми, если stamina не очень высокая).

В Python используйте GetMoveThroughNPC() / SetMoveThroughNPC(value).

Pascal

var moveThroughNPC: Integer;

Python

def GetMoveThroughNPC() -> int: ...
def SetMoveThroughNPC(Value: int) -> None: ...

Pascal Example

begin
  // Allow walking through NPCs with low stamina cost
  moveThroughNPC := 10;
  MoveXY(1234, 5678, True, 1, True);
  moveThroughNPC := 1000;  // restore default
end.

Python Example

SetMoveThroughNPC(10)
newMoveXY(1234, 5678, True, 1, True)
SetMoveThroughNPC(1000)

See Also

MoveXY, newMoveXY, moveCheckStamina