Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 12 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,12 +58,14 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),

- New hotkey system for `Actor` and `HeldDevice`.
Pressing a certain new hotkey will mark it as activated on `Actor` and `HeldDevice`, letting scripts make use of the new bindings easily.
`Enum` binding for `HeldDevice.HeldDeviceHotkeyType`: `PRIMARY = 0, AUXILIARY = 1, HELDDEVICEHOTKEYTYPECOUNT = 2`.
`Enum` binding for `Actor.ActorHotkeyType`: `PRIMARY = 0, AUXILIARY = 1, ACTORHOTKEYTYPECOUNT = 2`.
`Enum` binding for `HeldDevice.HeldDeviceHotkeyType`: `PRIMARYHOTKEY = 0, AUXILIARYHOTKEY = 1, HELDDEVICEHOTKEYTYPECOUNT = 2`.
`Enum` binding for `Actor.ActorHotkeyType`: `PRIMARYHOTKEY = 0, AUXILIARYHOTKEY = 1, ACTORHOTKEYTYPECOUNT = 2`.
Both `Actor` and `HeldDevice` have the following functions:
`HotkeyActionIsActivated(hotkeyType)` returns whether a certain hotkey action is being activated or not.
`ActivateHotkeyAction(hotkeyType)` activates a certain hotkey action.
`DeactivateHotkeyAction(hotkeyType)` deactivates a certain hotkey action.

- New `Controller` state `WEAPON_RELOADHELD`, which is true every frame reload input is held (as opposed to `WEAPON_RELOAD` which is only true once when pressed).

- New `GAScripted` Lua script method `IsCompatibleScene(scene)` to allow Activities to generically decide which Scenes are eligible by returning a boolean value.
New `GAScripted` INI enumerating property `AddRequiredArea`, replacing Lua file scanning, to allow Activities to explicitly state which areas are strictly required.
Expand All @@ -81,6 +83,10 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),

- New `ACraft` INI and Lua (R/W) property `CanEnterOrbit`, which determines whether a craft can enter orbit (and refund gold appropriately) or not. If false, default out-of-bounds deletion logic applies.

- New `MovableMan` function `GetMOsAtPosition(posX, posY, ignoreTeam, getsHitByMOsOnly)` that will return an iterator with all the `MovableObject`s that intersect that exact position with their sprite.

- New `SceneMan` function `CastAllMOsRay(startVector, rayVector, table ignoreMOIDs, ignoreTeam, ignoreMaterial, bool ignoreAllTerrain, int skip)` which returns an iterator with pointers to all the non-ignored MOs met along the ray.

</details>

<details><summary><b>Changed</b></summary>
Expand Down Expand Up @@ -127,6 +133,10 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),

- `MOSRotating` Lua function `AddWound` now additionally accepts the format `MOSRotating:AddWound(AEmitter* woundToAdd, const Vector& parentOffsetToSet, bool checkGibWoundLimit, bool isEntryWound, bool isExitWound)`, allowing modders to specify added wounds as entry- or exit wounds, for the purpose of not playing multiple burst sounds on the same frame. These new arguments are optional.

- `SceneMan` function `CastFindMORay` now has an extra bool parameter `findChildMOIDs` that denotes whether it also triggers on child MOIDs or not, which defaults to true for the same default behavior as before.

- `SceneMan` function `CastMORay` now can also accept a table of MOIDs instead of a single MOID, letting you ignore any arbitrary set of MOIDs.

- Techion Laser Rifle now has a constant range rather than being dependent on game resolution.

- Various performance improvements.
Expand Down
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogDS015.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogDS016.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogDS017.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogDS018.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogDS019.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogDS020.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogDS021.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogDS022.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogXB002.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogXB003.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogXB004.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogXB005.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogXB006.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogXB007.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogXB008.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogXB009.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogXB010.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogXB011.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogXB012.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogXB013.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogXB014.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogXB015.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogXB016.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogXB017.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogXB018.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogXB019.png
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogXB020.png
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogXB021.png
Binary file modified Data/Base.rte/GUIs/Controllers/DualAnalogXB022.png
26 changes: 13 additions & 13 deletions Data/Base.rte/GUIs/SettingsGUI.ini
Original file line number Diff line number Diff line change
Expand Up @@ -1612,7 +1612,7 @@ Parent = CollectionBoxScrollingMappingClipBox
X = 0
Y = 0
Width = 440
Height = 369
Height = 540
Visible = True
Enabled = True
Name = CollectionBoxScrollingMappingBox
Expand Down Expand Up @@ -2465,7 +2465,7 @@ Text = [InputKey]
[LabelInputName29]
ControlType = LABEL
Parent = CollectionBoxScrollingMappingBox
X = 215
X = 5
Y = 355
Width = 110
Height = 20
Expand All @@ -2481,7 +2481,7 @@ VAlignment = middle
[ButtonInputKey29]
ControlType = BUTTON
Parent = CollectionBoxScrollingMappingBox
X = 330
X = 120
Y = 355
Width = 95
Height = 20
Expand All @@ -2496,7 +2496,7 @@ Text = [InputKey]
ControlType = LABEL
Parent = CollectionBoxScrollingMappingBox
X = 215
Y = 380
Y = 355
Width = 110
Height = 20
Visible = True
Expand All @@ -2512,7 +2512,7 @@ VAlignment = middle
ControlType = BUTTON
Parent = CollectionBoxScrollingMappingBox
X = 330
Y = 380
Y = 355
Width = 95
Height = 20
Visible = True
Expand All @@ -2525,7 +2525,7 @@ Text = [InputKey]
[LabelInputName31]
ControlType = LABEL
Parent = CollectionBoxScrollingMappingBox
X = 215
X = 5
Y = 380
Width = 110
Height = 20
Expand All @@ -2541,7 +2541,7 @@ VAlignment = middle
[ButtonInputKey31]
ControlType = BUTTON
Parent = CollectionBoxScrollingMappingBox
X = 330
X = 120
Y = 380
Width = 95
Height = 20
Expand Down Expand Up @@ -2585,8 +2585,8 @@ Text = [InputKey]
[LabelInputName33]
ControlType = LABEL
Parent = CollectionBoxScrollingMappingBox
X = 215
Y = 380
X = 5
Y = 405
Width = 110
Height = 20
Visible = True
Expand All @@ -2601,8 +2601,8 @@ VAlignment = middle
[ButtonInputKey33]
ControlType = BUTTON
Parent = CollectionBoxScrollingMappingBox
X = 330
Y = 380
X = 120
Y = 405
Width = 95
Height = 20
Visible = True
Expand All @@ -2616,7 +2616,7 @@ Text = [InputKey]
ControlType = LABEL
Parent = CollectionBoxScrollingMappingBox
X = 215
Y = 380
Y = 405
Width = 110
Height = 20
Visible = True
Expand All @@ -2632,7 +2632,7 @@ VAlignment = middle
ControlType = BUTTON
Parent = CollectionBoxScrollingMappingBox
X = 330
Y = 380
Y = 405
Width = 95
Height = 20
Visible = True
Expand Down
26 changes: 13 additions & 13 deletions Data/Base.rte/GUIs/SettingsPauseGUI.ini
Original file line number Diff line number Diff line change
Expand Up @@ -1613,7 +1613,7 @@ Parent = CollectionBoxScrollingMappingClipBox
X = 0
Y = 0
Width = 440
Height = 369
Height = 540
Visible = True
Enabled = True
Name = CollectionBoxScrollingMappingBox
Expand Down Expand Up @@ -2466,7 +2466,7 @@ Text = [InputKey]
[LabelInputName29]
ControlType = LABEL
Parent = CollectionBoxScrollingMappingBox
X = 215
X = 5
Y = 355
Width = 110
Height = 20
Expand All @@ -2482,7 +2482,7 @@ VAlignment = middle
[ButtonInputKey29]
ControlType = BUTTON
Parent = CollectionBoxScrollingMappingBox
X = 330
X = 120
Y = 355
Width = 95
Height = 20
Expand All @@ -2497,7 +2497,7 @@ Text = [InputKey]
ControlType = LABEL
Parent = CollectionBoxScrollingMappingBox
X = 215
Y = 380
Y = 355
Width = 110
Height = 20
Visible = True
Expand All @@ -2513,7 +2513,7 @@ VAlignment = middle
ControlType = BUTTON
Parent = CollectionBoxScrollingMappingBox
X = 330
Y = 380
Y = 355
Width = 95
Height = 20
Visible = True
Expand All @@ -2526,7 +2526,7 @@ Text = [InputKey]
[LabelInputName31]
ControlType = LABEL
Parent = CollectionBoxScrollingMappingBox
X = 215
X = 5
Y = 380
Width = 110
Height = 20
Expand All @@ -2542,7 +2542,7 @@ VAlignment = middle
[ButtonInputKey31]
ControlType = BUTTON
Parent = CollectionBoxScrollingMappingBox
X = 330
X = 120
Y = 380
Width = 95
Height = 20
Expand Down Expand Up @@ -2586,8 +2586,8 @@ Text = [InputKey]
[LabelInputName33]
ControlType = LABEL
Parent = CollectionBoxScrollingMappingBox
X = 215
Y = 380
X = 5
Y = 405
Width = 110
Height = 20
Visible = True
Expand All @@ -2602,8 +2602,8 @@ VAlignment = middle
[ButtonInputKey33]
ControlType = BUTTON
Parent = CollectionBoxScrollingMappingBox
X = 330
Y = 380
X = 120
Y = 405
Width = 95
Height = 20
Visible = True
Expand All @@ -2617,7 +2617,7 @@ Text = [InputKey]
ControlType = LABEL
Parent = CollectionBoxScrollingMappingBox
X = 215
Y = 380
Y = 405
Width = 110
Height = 20
Visible = True
Expand All @@ -2633,7 +2633,7 @@ VAlignment = middle
ControlType = BUTTON
Parent = CollectionBoxScrollingMappingBox
X = 330
Y = 380
Y = 405
Width = 95
Height = 20
Visible = True
Expand Down
4 changes: 2 additions & 2 deletions Source/Entities/MOPixel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -140,8 +140,8 @@ void MOPixel::SetTrailLength(int trailLength) {
m_Atom->SetTrailLength(trailLength);
}

bool MOPixel::HitTestAtPixel(int pixelX, int pixelY) const {
if (!GetsHitByMOs() || GetRootParent()->GetTraveling()) {
bool MOPixel::HitTestAtPixel(int pixelX, int pixelY, bool validOnly) const {
if (validOnly && (!GetsHitByMOs() || GetRootParent()->GetTraveling())) {
return false;
}

Expand Down
3 changes: 2 additions & 1 deletion Source/Entities/MOPixel.h
Original file line number Diff line number Diff line change
Expand Up @@ -125,8 +125,9 @@ namespace RTE {
/// Whether a set of X, Y coordinates overlap us (in world space).
/// @param pixelX The given X coordinate, in world space.
/// @param pixelY The given Y coordinate, in world space.
/// @param validOnly Whether to return false if this MO isn't validly owned by MovableMan or not.
/// @return Whether the given coordinate overlap us.
bool HitTestAtPixel(int pixelX, int pixelY) const override;
bool HitTestAtPixel(int pixelX, int pixelY, bool validOnly = true) const override;
#pragma endregion

#pragma region Virtual Override Methods
Expand Down
4 changes: 2 additions & 2 deletions Source/Entities/MOSprite.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -240,8 +240,8 @@ void MOSprite::Destroy(bool notInherited) {
Clear();
}

bool MOSprite::HitTestAtPixel(int pixelX, int pixelY) const {
if (!GetsHitByMOs() || GetRootParent()->GetTraveling()) {
bool MOSprite::HitTestAtPixel(int pixelX, int pixelY, bool validOnly) const {
if (validOnly && (!GetsHitByMOs() || GetRootParent()->GetTraveling())) {
return false;
}

Expand Down
3 changes: 2 additions & 1 deletion Source/Entities/MOSprite.h
Original file line number Diff line number Diff line change
Expand Up @@ -127,8 +127,9 @@ namespace RTE {
/// Whether a set of X, Y coordinates overlap us (in world space).
/// @param pixelX The given X coordinate, in world space.
/// @param pixelY The given Y coordinate, in world space.
/// @param validOnly Whether to return false if this MO isn't validly owned by MovableMan or not.
/// @return Whether the given coordinate overlap us.
bool HitTestAtPixel(int pixelX, int pixelY) const override;
bool HitTestAtPixel(int pixelX, int pixelY, bool validOnly = true) const override;

/// Gets the current angular velocity of this MovableObject. Positive is
/// a counter-clockwise rotation.
Expand Down
3 changes: 2 additions & 1 deletion Source/Entities/MovableObject.h
Original file line number Diff line number Diff line change
Expand Up @@ -588,8 +588,9 @@ namespace RTE {
/// Whether a set of X, Y coordinates overlap us (in world space).
/// @param pixelX The given X coordinate, in world space.
/// @param pixelY The given Y coordinate, in world space.
/// @param validOnly Whether to return false if this MO isn't validly owned by MovableMan or not.
/// @return Whether the given coordinate overlap us.
virtual bool HitTestAtPixel(int pixelX, int pixelY) const { return false; }
virtual bool HitTestAtPixel(int pixelX, int pixelY, bool validOnly = true) const { return false; }

/// Shows whether this is or carries a specifically named object in its
/// inventory. Also looks through the inventories of potential passengers,
Expand Down
84 changes: 84 additions & 0 deletions Source/Lua/LuaAdapterDefinitions.h
Original file line number Diff line number Diff line change
Expand Up @@ -512,6 +512,90 @@ namespace RTE {

#pragma region SceneMan Lua Adapters
struct LuaAdaptersSceneMan {
/// Traces along a vector and returns MOID of the first non-ignored
/// non-NoMOID MO encountered. If a non-air terrain pixel is encountered
/// first, g_NoMOID will be returned.
/// @param start The starting position.
/// @param ray The vector to trace along.
/// @param ignoreMOIDs A vector of MOIDs to ignore. Any child MO's of this MOID will also be ignored. (default: g_NoMOID)
/// @param ignoreTeam To enable ignoring of all MOIDs associated with an object of a specific (default: Activity::NoTeam)
/// team which also has team ignoring enabled itself.
/// @param ignoreMaterial A specific material ID to ignore hits with. (default: 0)
/// @param ignoreAllTerrain Whether to ignore all terrain hits or not. (default: false)
/// @param skip For every pixel checked along the line, how many to skip between them (default: 0)
/// for optimization reasons. 0 = every pixel is checked.
/// @return The MOID of the hit non-ignored MO, or g_NoMOID if terrain or no MO was hit.
static MOID CastMORay1(SceneMan& sceneMan, const Vector& start, const Vector& ray, const luabind::object& ignoreMOIDs, int ignoreTeam = Activity::NoTeam, unsigned char ignoreMaterial = 0, bool ignoreAllTerrain = false, int skip = 0);

/// Traces along a vector and returns MOID of the first non-ignored
/// non-NoMOID MO encountered. If a non-air terrain pixel is encountered
/// first, g_NoMOID will be returned.
/// @param start The starting position.
/// @param ray The vector to trace along.
/// @param ignoreMOID An MOID to ignore. Any child MO's of this MOID will also be ignored. (default: g_NoMOID)
/// @param ignoreTeam To enable ignoring of all MOIDs associated with an object of a specific (default: Activity::NoTeam)
/// team which also has team ignoring enabled itself.
/// @param ignoreMaterial A specific material ID to ignore hits with. (default: 0)
/// @param ignoreAllTerrain Whether to ignore all terrain hits or not. (default: false)
/// @param skip For every pixel checked along the line, how many to skip between them (default: 0)
/// for optimization reasons. 0 = every pixel is checked.
/// @return The MOID of the hit non-ignored MO, or g_NoMOID if terrain or no MO was hit.
static MOID CastMORay2(SceneMan& sceneMan, const Vector& start, const Vector& ray, MOID ignoreMOID = g_NoMOID, int ignoreTeam = Activity::NoTeam, unsigned char ignoreMaterial = 0, bool ignoreAllTerrain = false, int skip = 0);

/// Traces along a vector and returns a vector of all MOs encountered.
/// @param start The starting position.
/// @param ray The vector to trace along.
/// @param ignoreMOIDs A vector of MOIDs to ignore. Any child MOs of an MOID will also be ignored. (default: g_NoMOID)
/// @param ignoreTeam To enable ignoring of all MOIDs associated with an object of a specific team (default: Activity::NoTeam)
/// @param ignoreMaterial A specific material ID to ignore hits with. (default: 0)
/// @param ignoreAllTerrain Whether to ignore all terrain hits or not. (default: false)
/// @param skip For every pixel checked along the line, how many to skip between them (default: 0)
/// for optimization reasons. 0 = every pixel is checked.
/// @return A vector of pointers to all MovableObjects met along the ray, who aren't ignored.
static const std::vector<MovableObject*>* CastAllMOsRay(SceneMan& sceneMan, const Vector& start, const Vector& ray, const luabind::object& ignoreMOIDs, int ignoreTeam = Activity::NoTeam, unsigned char ignoreMaterial = 0, bool ignoreAllTerrain = false, int skip = 0);

/// Traces along a vector and returns the length of how far the trace went
/// without hitting any non-ignored terrain material or MOID at all.
/// @param start The starting position.
/// @param ray The vector to trace along.
/// @param obstaclePos A reference to the vector screen will be filled out with the absolute
/// location of the first obstacle, or the end of the ray if none was hit.
/// @param freePos A reference to the vector screen will be filled out with the absolute
/// location of the last free position before hitting an obstacle, or the
/// end of the ray if none was hit. This is only altered if thre are any
/// free pixels encountered.
/// @param ignoreMOIDs A vector of MOIDs to ignore. Any child MO's of an MOID will also be ignored. (default: g_NoMOID)
/// @param ignoreTeam To enable ignoring of all MOIDs associated with an object of a specific (default: Activity::NoTeam)
/// team which also has team ignoring enabled itself.
/// @param ignoreMaterial A specific material ID to ignore hits with. (default: 0)
/// @param skip For every pixel checked along the line, how many to skip between them (default: 0)
/// for optimization reasons. 0 = every pixel is checked.
/// @return How far along, in pixel units, the ray the pixel of any obstacle was
/// encountered. If no pixel of the right material was found, < 0 is returned.
/// If an obstacle on the starting position was encountered, 0 is returned.
static float CastObstacleRay1(SceneMan& sceneMan, const Vector& start, const Vector& ray, Vector& obstaclePos, Vector& freePos, const luabind::object& ignoreMOIDs, int ignoreTeam = Activity::NoTeam, unsigned char ignoreMaterial = 0, int skip = 0);

/// Traces along a vector and returns the length of how far the trace went
/// without hitting any non-ignored terrain material or MOID at all.
/// @param start The starting position.
/// @param ray The vector to trace along.
/// @param obstaclePos A reference to the vector screen will be filled out with the absolute
/// location of the first obstacle, or the end of the ray if none was hit.
/// @param freePos A reference to the vector screen will be filled out with the absolute
/// location of the last free position before hitting an obstacle, or the
/// end of the ray if none was hit. This is only altered if thre are any
/// free pixels encountered.
/// @param ignoreMOID An MOID to ignore. Any child MOs of this MOID will also be ignored. (default: g_NoMOID)
/// @param ignoreTeam To enable ignoring of all MOIDs associated with an object of a specific (default: Activity::NoTeam)
/// team which also has team ignoring enabled itself.
/// @param ignoreMaterial A specific material ID to ignore hits with. (default: 0)
/// @param skip For every pixel checked along the line, how many to skip between them (default: 0)
/// for optimization reasons. 0 = every pixel is checked.
/// @return How far along, in pixel units, the ray the pixel of any obstacle was
/// encountered. If no pixel of the right material was found, < 0 is returned.
/// If an obstacle on the starting position was encountered, 0 is returned.
static float CastObstacleRay2(SceneMan& sceneMan, const Vector& start, const Vector& ray, Vector& obstaclePos, Vector& freePos, MOID ignoreMOID = g_NoMOID, int ignoreTeam = Activity::NoTeam, unsigned char ignoreMaterial = 0, int skip = 0);

/// Takes a Box and returns a list of Boxes that describe the Box, wrapped appropriately for the current Scene.
/// @param boxToWrap The Box to wrap.
/// @return A list of Boxes that make up the Box to wrap, wrapped appropriately for the current Scene.
Expand Down
Loading
Loading