About Store Forum Documentation Contact



Post Reply 
Adding interactive objects
Author Message
drizztfun Offline
Member

Post: #1
Adding interactive objects
Hello,

i am completely new to EE and also C++ (but i know other languages).

My problem is, i am trying to add an object into the world and make me able to interact with it with the mouse.

I tried adding it in the world editor and i tried doing it internally, both is showing the object.

When i now click it (using examples, Physics.Ray), i seem to get an object back, but well.. its the real object or just the ground where it is standing on?

1. Since i am using Physics.Ray, the object has to have a PhysBody?
2. Should i change the objecttype in the editor, to find out what i got via casting as shown in examples?
3. if i have i use some objecttype, like obj_item, i have to set the obj_type during Game::World.init() ? and thats it then?
What about that
Game::ObjMemx<MyObjDef > MyObj;

----------
I just feel like i am confusing myself too much, reading through all the examples.
All i want for the start is some immobile thing, like a chair for example, that i can click for example and get some reference to it, for deleting it, and some other experiments smile

Any help is appreciated, i guess its in the examples but i just keep missing the relevant spots.
02-27-2011 12:42 AM
Find all posts by this user Quote this message in a reply
Driklyn Offline
Member

Post: #2
RE: Adding interactive objects
1. Yes
2. Yes
3. Yes, you'll need Game::ObjMemx<MyObjDef > MyObj;

This tutorial covers everything you're asking, if you haven't looked at it already: "EsenthelEngineSDK\Tutorials\Source\Advanced\4 - Demos, Game Basics\Game Basics\07 - Doors.cpp"
02-27-2011 07:44 AM
Find all posts by this user Quote this message in a reply
drizztfun Offline
Member

Post: #3
RE: Adding interactive objects
Thank you very much, that did it wink

I did not look into the door-tutorial too much, my fault, but its exactly what i want.
02-27-2011 12:07 PM
Find all posts by this user Quote this message in a reply
Post Reply