From 0ea5fc66924303d1bf73ba283a383e2aadee02f2 Mon Sep 17 00:00:00 2001 From: neodarz Date: Sat, 11 Aug 2018 20:21:34 +0200 Subject: Initial commit --- docs/doxygen/nel/a02947.html | 1689 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 1689 insertions(+) create mode 100644 docs/doxygen/nel/a02947.html (limited to 'docs/doxygen/nel/a02947.html') diff --git a/docs/doxygen/nel/a02947.html b/docs/doxygen/nel/a02947.html new file mode 100644 index 00000000..bd2ce75c --- /dev/null +++ b/docs/doxygen/nel/a02947.html @@ -0,0 +1,1689 @@ + + +NeL: NLPACS::UMovePrimitive class Reference + + + +
+

NLPACS::UMovePrimitive Class Reference

#include <u_move_primitive.h> +

+

Inheritance diagram for NLPACS::UMovePrimitive: +

+ +NLPACS::CMovePrimitive + +

Detailed Description

+Description of movables primitives.

+This primitive can be a 2d oriented box or a 2d oriented cylinder.

+

Author:
Cyril 'Hulud' Corvazier

+Nevrax France

+
Date:
2001
+ +

+ +

+Definition at line 52 of file u_move_primitive.h. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

Public Types

typedef uint32 TCollisionMask
 Type of the collision mask.

enum  TReaction { DoNothing = 0x0, +Slide = 0x10, +Reflexion = 0x20, +Stop = 0x40 + }
 Reaction mode. More...

enum  TTrigger { NotATrigger = 0x0, +EnterTrigger = 0x100, +ExitTrigger = 0x200, +OverlapTrigger = 0x400 + }
 Reaction mode. More...

enum  TType { _2DOrientedBox = 0x0, +_2DOrientedCylinder = 0x1 + }
 Primitive mode. More...

typedef uint64 TUserData

Public Member Functions

Access the primitive static parts.
virtual float getAbsorbtion () const=0
virtual TCollisionMask getCollisionMask () const=0
virtual float getHeight () const=0
virtual bool getObstacle () const=0
virtual TCollisionMask getOcclusionMask () const=0
virtual TType getPrimitiveType () const=0
virtual float getRadius () const=0
virtual TReaction getReactionType () const=0
virtual void getSize (float &width, float &depth) const=0
virtual TTrigger getTriggerType () const=0
virtual bool isCollisionable () const=0
Setup the primitive static parts.
virtual bool getDontSnapToGround () const=0
 Test if snapping to ground is off.

virtual void setAbsorbtion (float attenuation)=0
virtual void setCollisionMask (TCollisionMask mask)=0
virtual void setDontSnapToGround (bool dont)=0
virtual void setHeight (float height)=0
virtual void setObstacle (bool obstacle)=0
virtual void setOcclusionMask (TCollisionMask mask)=0
virtual void setPrimitiveType (TType type)=0
virtual void setRadius (float radius)=0
virtual void setReactionType (TReaction type)=0
virtual void setSize (float width, float depth)=0
virtual void setTriggerType (TTrigger type)=0
Access the primitive dynamic parts.
virtual NLMISC::CVectorD getFinalPosition (uint8 worldImage) const=0
virtual void getGlobalPosition (UGlobalPosition &pos, uint8 worldImage) const=0
virtual double getOrientation (uint8 worldImage) const=0
virtual const NLMISC::CVectorDgetSpeed (uint8 worldImage) const=0
Move the primitive.
virtual uint8 getFirstWorldImageV () const=0
virtual uint8 getNumWorldImageV () const=0
virtual void insertInWorldImage (uint8 worldImage)=0
virtual void move (const NLMISC::CVectorD &speed, uint8 worldImage)=0
virtual void removeFromWorldImage (uint8 worldImage)=0
virtual void setGlobalPosition (const UGlobalPosition &pos, uint8 worldImage)=0
virtual void setGlobalPosition (const NLMISC::CVectorD &pos, uint8 worldImage, UGlobalPosition::TType type=UGlobalPosition::Unspecified)=0
Setup the primitive dynamic parts.
virtual void setOrientation (double rot, uint8 worldImage)=0

Data Fields

TUserData UserData
+


Member Typedef Documentation

+

+ + + + +
+ + +
typedef uint32 NLPACS::UMovePrimitive::TCollisionMask +
+
+ + + + + +
+   + + +

+Type of the collision mask. +

+ +

+Definition at line 57 of file u_move_primitive.h. +

+Referenced by NLNET::CPacsClient::setCollisionMask(), and NLNET::CPacsClient::setOcclusionMask().

+

+ + + + +
+ + +
typedef uint64 NLPACS::UMovePrimitive::TUserData +
+
+ + + + + +
+   + + +

+ +

+Definition at line 58 of file u_move_primitive.h. +

+Referenced by NLNET::CPacsClient::addPrimitive(), NLNET::cbPacsAnswer(), NLNET::CPacsClient::getPositionSpeed(), NLNET::CPacsClient::getPositionSpeedCallback(), NLPACS::CPrimitiveBlock::getUserData(), NLNET::CPacsClient::removePrimitive(), NLNET::CPacsClient::setCurrentPrimitive(), NLNET::CPacsClient::testMove(), and NLNET::CPacsClient::testMoveCallback().

+


Member Enumeration Documentation

+

+ + + + +
+ + +
enum NLPACS::UMovePrimitive::TReaction +
+
+ + + + + +
+   + + +

+Reaction mode. +

+

Enumeration values:
+ + + + + +
DoNothing  +No reaction. For static objects or not influanced objects. Default value.
Slide  +This object slids over surfaces.
Reflexion  +This object reflects over surfaces.
Stop  +This object stops over surfaces.
+
+ +

+Definition at line 80 of file u_move_primitive.h. +

+

00081         {
+00085                 DoNothing=0x0,
+00086 
+00090                 Slide=0x10,
+00091 
+00095                 Reflexion=0x20,
+00096 
+00100                 Stop=0x40,
+00101         };
+
+

+ + + + +
+ + +
enum NLPACS::UMovePrimitive::TTrigger +
+
+ + + + + +
+   + + +

+Reaction mode. +

+

Enumeration values:
+ + + + + +
NotATrigger  +Not a trigger.
EnterTrigger  +This is a one time trigger. This trigger is actived only when an object enter in its volume.
ExitTrigger  +This is a one time trigger. This trigger is actived only when an object exit from its volume.
OverlapTrigger  +This is an overlap trigger. This trigger is actived each time the object overlap the trigger.
+
+ +

+Definition at line 104 of file u_move_primitive.h. +

+

00105         {
+00109                 NotATrigger=0x0,
+00110 
+00114                 EnterTrigger=0x100,
+00115 
+00119                 ExitTrigger=0x200,
+00120 
+00124                 OverlapTrigger=0x400,
+00125         };
+
+

+ + + + +
+ + +
enum NLPACS::UMovePrimitive::TType +
+
+ + + + + +
+   + + +

+Primitive mode. +

+

Enumeration values:
+ + + +
_2DOrientedBox  +This is a static 2d oriented bounding box. It can be oriented only on the Z axis. It has a height. Collision can be performed only no its sides but not on its top and bottom planes. It doesn't mode. Default value.
_2DOrientedCylinder  +This is a movable 2d oriented cylinder. It can be oriented only on the Z axis. It has a height. Collision can be performed only no its sides but not on its top and bottom planes. It can move only with 3d translations.
+
+ +

+Definition at line 61 of file u_move_primitive.h. +

+

00062         {
+00068                 _2DOrientedBox=0x0,
+00069 
+00075                 _2DOrientedCylinder=0x1,
+00076         };
+
+


Member Function Documentation

+

+ + + + +
+ + + + + + + + + +
virtual float NLPACS::UMovePrimitive::getAbsorbtion  )  const [pure virtual]
+
+ + + + + +
+   + + +

+Set the attenuation of collision for this object. Default value is 1. Should be between 0~1. 0, all the enrgy is attenuated by the collision. 1, all the energy stay in the object. Used only with the flag Reflexion.

+

Parameters:
+ + +
attenuation is the new attenuation for the primitive.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + +
virtual TCollisionMask NLPACS::UMovePrimitive::getCollisionMask  )  const [pure virtual]
+
+ + + + + +
+   + + +

+Set the collision mask for this primitive. Default mask is 0xffffffff.

+

Parameters:
+ + +
mask is the new collision mask.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + +
virtual bool NLPACS::UMovePrimitive::getDontSnapToGround  )  const [pure virtual]
+
+ + + + + +
+   + + +

+Test if snapping to ground is off. +

+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + + +
virtual NLMISC::CVectorD NLPACS::UMovePrimitive::getFinalPosition uint8  worldImage  )  const [pure virtual]
+
+ + + + + +
+   + + +

+Get the position of the move primitive at the end of the movement. This method is slow. Just for initilisation and teleportation.

+If you modify a noncollisionable primitive with this method, you must evaluate in the world image where you have modify it before modify any other dynamic properties in another world image.

+

Returns:
the new position of the primitive.
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + +
virtual uint8 NLPACS::UMovePrimitive::getFirstWorldImageV  )  const [pure virtual]
+
+ + + + + +
+   + + +

+Return the first world image +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + + + + + + + + + + + +
virtual void NLPACS::UMovePrimitive::getGlobalPosition UGlobalPosition pos,
uint8  worldImage
const [pure virtual]
+
+ + + + + +
+   + + +

+Set the global position of the move primitive. This method is fast because you must pass the global position of the primitive.

+If you modify a noncollisionable primitive with this method, you must evaluate in the world image where you have modify it before modify any other dynamic properties in another world image.

+

Parameters:
+ + +
pos is the new global position of the primitive.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + +
virtual float NLPACS::UMovePrimitive::getHeight  )  const [pure virtual]
+
+ + + + + +
+   + + +

+Set the height. For boxes or cylinder.

+

Parameters:
+ + +
height is the new height size of the box. It the size of the sides aligned on OZ.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + +
virtual uint8 NLPACS::UMovePrimitive::getNumWorldImageV  )  const [pure virtual]
+
+ + + + + +
+   + + +

+Return the num of world image +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + +
virtual bool NLPACS::UMovePrimitive::getObstacle  )  const [pure virtual]
+
+ + + + + +
+   + + +

+Set the obstacle flag.

+

Parameters:
+ + +
obstacle is true if this primitive is an obstacle, else false.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + +
virtual TCollisionMask NLPACS::UMovePrimitive::getOcclusionMask  )  const [pure virtual]
+
+ + + + + +
+   + + +

+Set the occlusion mask for this primitive. Default mask is 0xffffffff.

+

Parameters:
+ + +
mask is the new occlusion mask.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + + +
virtual double NLPACS::UMovePrimitive::getOrientation uint8  worldImage  )  const [pure virtual]
+
+ + + + + +
+   + + +

+Set the new orientation of the move primitive. Only for the box primitives.

+If you modify a noncollisionable primitive with this method, you must evaluate in the world image where you have modify it before modify any other dynamic properties in another world image.

+

Parameters:
+ + + +
rot is the new OZ rotation in radian.
worldImage is the world image in which the primitive must be oriented.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + +
virtual TType NLPACS::UMovePrimitive::getPrimitiveType  )  const [pure virtual]
+
+ + + + + +
+   + + +

+Set the primitive type.

+

Parameters:
+ + +
type is the new primitive type.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + +
virtual float NLPACS::UMovePrimitive::getRadius  )  const [pure virtual]
+
+ + + + + +
+   + + +

+Set the cylinder size. Only for cylinder.

+

Parameters:
+ + +
radius is the new radius size of the cylinder.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + +
virtual TReaction NLPACS::UMovePrimitive::getReactionType  )  const [pure virtual]
+
+ + + + + +
+   + + +

+Set the reaction type.

+

Parameters:
+ + +
type is the new reaction type.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + + + + + + + + + + + +
virtual void NLPACS::UMovePrimitive::getSize float &  width,
float &  depth
const [pure virtual]
+
+ + + + + +
+   + + +

+Set the box size. Only for boxes.

+

Parameters:
+ + + +
width is the new width size of the box. It the size of the sides aligned on OX.
depth is the new depth size of the box. It the size of the sides aligned on OY.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + + +
virtual const NLMISC::CVectorD& NLPACS::UMovePrimitive::getSpeed uint8  worldImage  )  const [pure virtual]
+
+ + + + + +
+   + + +

+Get the speed vector for this primitive.

+the new speed vector. +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + +
virtual TTrigger NLPACS::UMovePrimitive::getTriggerType  )  const [pure virtual]
+
+ + + + + +
+   + + +

+Set the trigger type. Default type is NotATrigger.

+

Parameters:
+ + +
type is the new trigger type.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + + +
virtual void NLPACS::UMovePrimitive::insertInWorldImage uint8  worldImage  )  [pure virtual]
+
+ + + + + +
+   + + +

+Insert the primitive in a world image of the move container.

+This primitive must a collisionable primitive.

+

Parameters:
+ + +
worldImage is the number of the world image where you want to insert the primitive.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + +
virtual bool NLPACS::UMovePrimitive::isCollisionable  )  const [pure virtual]
+
+ + + + + +
+   + + +

+Return true if the primitive is collisionable +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + + + + + + + + + + + +
virtual void NLPACS::UMovePrimitive::move const NLMISC::CVectorD speed,
uint8  worldImage
[pure virtual]
+
+ + + + + +
+   + + +

+Move the primitive. This method is fast. Use it to move primitives.

+If you modify a noncollisionable primitive with this method, you must evaluate in the world image where you have modify it before modify any other dynamic properties in another world image.

+

Parameters:
+ + +
speed is the speed of the primitive.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + + +
virtual void NLPACS::UMovePrimitive::removeFromWorldImage uint8  worldImage  )  [pure virtual]
+
+ + + + + +
+   + + +

+Remove the primitive from a world image of the move container.

+This primitive must a collisionable primitive.

+

Parameters:
+ + +
worldImage is the number of the world image from where you want to remove the primitive.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + + +
virtual void NLPACS::UMovePrimitive::setAbsorbtion float  attenuation  )  [pure virtual]
+
+ + + + + +
+   + + +

+Set the attenuation of collision for this object. Default value is 1. Should be between 0~1. 0, all the enrgy is attenuated by the collision. 1, all the energy stay in the object. Used only with the flag Reflexion.

+

Parameters:
+ + +
attenuation is the new attenuation for the primitive.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + + +
virtual void NLPACS::UMovePrimitive::setCollisionMask TCollisionMask  mask  )  [pure virtual]
+
+ + + + + +
+   + + +

+Set the collision mask for this primitive. Default mask is 0xffffffff.

+

Parameters:
+ + +
mask is the new collision mask.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + + +
virtual void NLPACS::UMovePrimitive::setDontSnapToGround bool  dont  )  [pure virtual]
+
+ + + + + +
+   + + +

+Tells that the primitive should not be snapped to ground. The default is false +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + + + + + + + + + + + +
virtual void NLPACS::UMovePrimitive::setGlobalPosition const UGlobalPosition pos,
uint8  worldImage
[pure virtual]
+
+ + + + + +
+   + + +

+Set the global position of the move primitive. This method is fast because you must pass the global position of the primitive.

+If you modify a noncollisionable primitive with this method, you must evaluate in the world image where you have modify it before modify any other dynamic properties in another world image.

+

Parameters:
+ + +
pos is the new global position of the primitive.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + +
virtual void NLPACS::UMovePrimitive::setGlobalPosition const NLMISC::CVectorD pos,
uint8  worldImage,
UGlobalPosition::TType  type = UGlobalPosition::Unspecified
[pure virtual]
+
+ + + + + +
+   + + +

+Set the global position of the move primitive. Setting the global position can take a long time if you use a UGlobalRetriever. Set the position with this method only the first time or for teleporting.

+If you modify a noncollisionable primitive with this method, you must evaluate in the world image where you have modify it before modify any other dynamic properties in another world image.

+

Parameters:
+ + +
pos is the new global position of the primitive.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + + +
virtual void NLPACS::UMovePrimitive::setHeight float  height  )  [pure virtual]
+
+ + + + + +
+   + + +

+Set the height. For boxes or cylinder.

+

Parameters:
+ + +
height is the new height size of the box. It the size of the sides aligned on OZ.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + + +
virtual void NLPACS::UMovePrimitive::setObstacle bool  obstacle  )  [pure virtual]
+
+ + + + + +
+   + + +

+Set the obstacle flag.

+

Parameters:
+ + +
obstacle is true if this primitive is an obstacle, else false.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + + +
virtual void NLPACS::UMovePrimitive::setOcclusionMask TCollisionMask  mask  )  [pure virtual]
+
+ + + + + +
+   + + +

+Set the occlusion mask for this primitive. Default mask is 0xffffffff.

+

Parameters:
+ + +
mask is the new occlusion mask.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + + + + + + + + + + + +
virtual void NLPACS::UMovePrimitive::setOrientation double  rot,
uint8  worldImage
[pure virtual]
+
+ + + + + +
+   + + +

+Set the new orientation of the move primitive. Only for the box primitives.

+If you modify a noncollisionable primitive with this method, you must evaluate in the world image where you have modify it before modify any other dynamic properties in another world image.

+

Parameters:
+ + + +
rot is the new OZ rotation in radian.
worldImage is the world image in which the primitive must be oriented.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + + +
virtual void NLPACS::UMovePrimitive::setPrimitiveType TType  type  )  [pure virtual]
+
+ + + + + +
+   + + +

+Set the primitive type.

+

Parameters:
+ + +
type is the new primitive type.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + + +
virtual void NLPACS::UMovePrimitive::setRadius float  radius  )  [pure virtual]
+
+ + + + + +
+   + + +

+Set the cylinder size. Only for cylinder.

+

Parameters:
+ + +
radius is the new radius size of the cylinder.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + + +
virtual void NLPACS::UMovePrimitive::setReactionType TReaction  type  )  [pure virtual]
+
+ + + + + +
+   + + +

+Set the reaction type.

+

Parameters:
+ + +
type is the new reaction type.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + + + + + + + + + + + +
virtual void NLPACS::UMovePrimitive::setSize float  width,
float  depth
[pure virtual]
+
+ + + + + +
+   + + +

+Set the box size. Only for boxes.

+

Parameters:
+ + + +
width is the new width size of the box. It the size of the sides aligned on OX.
depth is the new depth size of the box. It the size of the sides aligned on OY.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+

+ + + + +
+ + + + + + + + + + +
virtual void NLPACS::UMovePrimitive::setTriggerType TTrigger  type  )  [pure virtual]
+
+ + + + + +
+   + + +

+Set the trigger type. Default type is NotATrigger.

+

Parameters:
+ + +
type is the new trigger type.
+
+ +

+Implemented in NLPACS::CMovePrimitive.

+


Field Documentation

+

+ + + + +
+ + +
TUserData NLPACS::UMovePrimitive::UserData +
+
+ + + + + +
+   + + +

+User data. +

+Definition at line 130 of file u_move_primitive.h.

+


The documentation for this class was generated from the following file: +
Generated on Tue Mar 16 14:26:32 2004 for NeL by + +doxygen +1.3.6
+ + -- cgit v1.2.1