Skip to content

Commit

Permalink
Update APIs (NWNX: 494a2b6e, NWN: 8193.33).
Browse files Browse the repository at this point in the history
  • Loading branch information
jhett12321 committed Nov 17, 2021
1 parent 2f6cdcd commit bf25ce3
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions src/NWNX/Plugins/AreaPlugin.cs
Original file line number Diff line number Diff line change
Expand Up @@ -618,6 +618,19 @@ public static uint CreateSoundObject(uint oArea, System.Numerics.Vector3 vPositi
return VM.NWNX.StackPopObject();
}

/// Rotates an existing area, including all objects within (excluding PCs).
/// @note Functions while clients are in the area, but not recommended as tiles/walkmesh only updates on area load, and this may reuslt in unexpected clientside results.
/// <param name="oArea">The area to be rotated</param>
/// <param name="nRotation">How many 90 degrees clockwise to rotate (1-3).</param>
public static void RotateArea(uint oArea, int nRotation)
{
const string sFunc = "RotateArea";
VM.NWNX.SetFunction(NWNX_Area, sFunc);
VM.NWNX.StackPush(nRotation);
VM.NWNX.StackPush(oArea);
VM.NWNX.Call();
}

// @}
}

Expand Down

0 comments on commit bf25ce3

Please sign in to comment.