Jump to content

Search the Community

Showing results for tags 'PlayerDummy'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Welcome to UNIGINE Forums
    • News & Announcements
    • Getting started
  • Development
    • Content Creation
    • World Design
    • Rendering
    • Animation
    • Physics, Navigation and Path Finding
    • UI Systems
    • Sound & Video
    • Editor
    • C++ Programming
    • C# Programming
    • Networking
    • Sim IG (Image Generator)
    • VR Discussions
    • General
  • Improving UNIGINE
    • Documentation
    • Feedback for UNIGINE team
    • Bug Reports
    • Unigine SDK Beta feedback
  • Community
    • Add-on Store (https://store.unigine.com/)
    • Showcase
    • Collaboration
    • Tools, Plugins, Materials & Tutorials
    • General Discussions
  • Legacy
    • UnigineScript

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Found 1 result

  1. Hi folks! I'm currently facing a rather annoying issue in Unigine, created by myself and my lack of understanding of course, which I need your help on! My situation is this: I have two characters, I want to calculate the mid-point between these two characters' heads and make a camera inside of the game look at that mid-point. What I am currently doing is: 1. Cycling through bones and finding the head bones of each character 2. Using ObjectMeshSkinned::getWorldBoneTransform to get the transform of each head bone as a mat4 3. Getting the 12th, 13th and 14th values from the head bone mat4s that represent the position of the head bones 4. Creating two separate vec3s for each head bone position using the values from stage 3 5. Finding the distance between the two values and normalising them to give me a look direction for my camera 6. Using Node::setDirection to set the direction the camera is facing like in the default setup of: camera = new PlayerSpectator(); camera.setDirection(Vec3(-1.0f, 0.0f, -0.5f)); The script I am using to get the PlayerSpectator from the world is: PlayerSpectator camera_Player = node_cast(engine.world.getnode(0123456789)); My problem is: When I try to do anything PlayerSpectator/Player/Node related with the PlayerSpectator variable I get an error saying: Project001/Project001.cpp: 1092: ExternClass::run_function(): can't find "class PlayerSpectator * __ptr64" base class in "class PlayerDummy" * __ptr64" class Can anyone suggest what I am doing wrong? Should I not node_cast cameras or something? Am I referencing them the wrong way? I can't even call Node::getNodeName or anything! Thanks in advance for your help! Tom
×
×
  • Create New...