Ohhh man you are using a point constraint not a line constraint! Holy crap it finally works!!! This is the code that ended up doing the trick for me! Matrix34 entityTM = m_pEntity->GetWorldTM(); IPhysicalEntity *pPE = m_pEntity->GetPhysics(); pe_action_add_constraint ac; Vec3 axis(0, 0, 1); ac.flags...
Search found 25 matches
So if I want a swinging door that has a hinge along the (world) Z axis, Then using the code previously posted on my component, I would rotate my entity in the editor by 90 degrees on the Y axis then rotate the mesh component on the Y axis (to make the door stand up right) by -90 degrees? Is that wha...
Sorry for the delay, I had to travel for work. I tried initializing qframe and qframe as LineConstraint did but I still must have something messed up. My code looks like this now: Matrix34 entityTM = m_pEntity->GetWorldTM(); IPhysicalEntity *pPE = m_pEntity->GetPhysics(); pe_action_add_constra...
I've been referencing that file but I am still struggling to get it to work properly. I have two cases that work but both have flaws. I don't know where I am going wrong. First The problem with this is that if I push on the door from the side, the "hinge" at the top moves and the door is no longer s...
This is the code I have come up with so far: Matrix34 entityTM = m_pEntity->GetWorldTM(); IPhysicalEntity *pPE = m_pEntity->GetPhysics(); pe_action_add_constraint ac; ac.flags = world_frames | constraint_no_tears; ac.pBuddy = WORLD_ENTITY; ac.xlimits = 1.0f; ac.xlimits = 0.0f; ac.pt = ac.pt...
I am working making a door, I have it so that if I walk up to the door and click, it opens(yay!). The problem now is that if I push the door without opening it, the door can fall over. How can I "pin" the door such that it's position is locked and the axis which the door can rotate is restricted to ...
I guess I was over thinking this. I thought a pivot was a point something I would add or define in the map or the model. Even if I had 3d studio max I had no idea what needed to be done. I eventually tried moving the origin of the model in Ultimate Unwrap 3d and set the bRotationAroundPivot flag to ...
I have an entity with a rigid body component that is to be a door. I am applying velocity to turn the door, it all works great except that it is rotating on center of mass so it just turns in the middle of the model. I found the bRotationAroundPivot member of pe_action_set_velocity which seems like ...
Thanks for the link, lots of good info on here.
I have a simple entity written in Lua and it works fine however it's labeled as "Legacy". To me "Legacy" means deprecated, since I am just starting out I don't want to waste time learning something that could go away someday. What makes an entity Legacy? Is Lua as a whole Legacy or has the Lua scrip...
- CRYENGINE Official
- - Forum Rules
- - Official Announcements
- CRYENGINE Development
- - Educational & Beginner's Corner
- - - CRYENGINE First Aid
- - - CRYENGINE Feedback
- - - Tutorials & Learning
- - - Plugins, Source Code & GitHub
- - CRYENGINE General
- - - General Discussion
- - - Showcase Gallery
- - - Virtual Reality / Augmented Reality
- - C#/C++ Programming
- - - Entities
- - - Networking
- - - Shaders & Rendering in General
- - - Programming General
- - Asset Preparation
- - - Plugins & Tools
- - - Models & Art
- - - UI
- - - Audio Middleware
- - Game Design - Sandbox Editor
- - - Audio
- - - Animation
- - - Materials
- - - Physics
- - - Debugging
- - - Visual Scripting
- - - UI (HUD/Menu)
- - - Artificial Intelligence
- Online Services
- - Website
- - Launcher
- - Marketplace
- Community Corner
- - Events & MeetUps
- - Recruitment & Collaboration
- - - Job Offers [PAID work only]
- - - Talent Showcase - looking for work
- - - Collaborations [Free Work & Hobby Teams]
- - Off-Topic Discussions