Jump to content

Parent in Editor


Dozz
 Share

Recommended Posts

Yes simply click, hold and drag from one object to another. There is no graphic visualisation of the linking (like a line) but if you did it properly you will get a message saying 'CreatLink(0)?' and just click Ok... that should be all

STS - Scarlet Thread Studios

AKA: Engineer Ken

 

Fact: Game Development is hard... very bloody hard.. If you are not prepared to accept that.. Please give up now!

Link to comment
Share on other sites

That's not the same thing as parenting.

 

It's assumed that when models are loaded in the editor, their hierarchy has already been arranged in a modeling program, and all models are top-level entities.

My job is to make tools you love, with the features you want, and performance you can't live without.

Link to comment
Share on other sites

@Ken Also when linking there is a visual line drawn. Tools->Linked Index let's you change which link you are viewing and linking. You can only view1 link index at a time. Also pressing keys 0-7 will change this selected index.

 

@Dozz I know you said without Lua but currently you have to use Lua to do this in the editor. In a way Ken's comment could work for parenting but it would still require some coding in the model scripts. You'd want to add the following function so you know when something is linked and then you could call EntityParent. The model script function would be:

 

function object:SetTarget(target,index)

end

 

You can look at the lua template in the Scripts folder to see this and all other Lua model functions that the engine calls.

 

I fought for this function because it can be useful to know when a target is set. Like in this case you could put code in this that actually does the parenting of models. Should just be a 1 liner in each model that you want this functionality in.

Link to comment
Share on other sites

thanks Rick, getting to grips with Lua is on my list, but it's on page 2. Its not a big issue it not being in the editor, It works in my cpp code. For my purposes, building the hierarchy through the modelling app works fine, I just don't want it for all models. thanks

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...