Jump to content
The Dark Mod Forums

Inlining entities - is it working?


motorsep
 Share

Recommended Posts

There is a spawn arg on func_static entities called "inline". I recall it suppose to embed mesh into .proc file and free up that entity. This way you could embed all meshes into .proc and worry not about grass, rocks, etc. eating up entity count. Also it should improve loading times.

 

As I recall, Quake 4 had this working, but vanilla Doom 3 doesn't inline entities properly (collisions are missing and it still remains an entity afaik).

 

Was it fixed in TDM engine?

Link to comment
Share on other sites

I'm pretty sure I've seen the relevant code in dmap but I've not tried it. It's only for func statics. Did you check whether it adds the model to the proc?

The world collision model generation isn't part of dmap, it's tacked on after. I can well believe it ignores the inline spawnarg, but I'd have thought it would cater for func statics anyway.

Map loading is different again. But if the first two are sorted, it would be easy to skip any inline FS during spawning. No idea how much of this is implemented.

Link to comment
Share on other sites

The world collision model generation isn't part of dmap, it's tacked on after. I can well believe it ignores the inline spawnarg, but I'd have thought it would cater for func statics anyway.

 

Think I was wrong on this.. FS CMs won't automatically be part of the world CM else you'd not be able to show/hide them.

I'll take a look after work and try to clear up whether inlining is "not implemented" or "broken".

Link to comment
Share on other sites

As far as I know we never used inlining and so never fixed it. Not sure it is worth to fixi it (SEED partially replaces it).

"The reasonable man adapts himself to the world; the unreasonable one persists in trying to adapt the world to himself. Therefore, all progress depends on the unreasonable man." -- George Bernard Shaw (1856 - 1950)

 

"Remember: If the game lets you do it, it's not cheating." -- Xarax

Link to comment
Share on other sites

That's a point: for TDM at least, SEED probably does the job better does it? Because it doesn't just reduce the entity count, it combines the models in some way for drawing? Tels, please step in with proper explanation here :)

 

As motorsep has had to point out to me before though when I've recommended SEED, that system is only for TDM and he's using DR to work on something different. And if every model is unique, then you're back to wanting inlining in any case.

Link to comment
Share on other sites

Yeah, you'd be surprised to know how many people use DR for non-TDM projects (people use it for plain Doom 3 mapping for example).

 

I am not sure yet if we will use inlining at this point. Our LOD system prototype needs to reference entities, and inlining won't allow that. So until we make LOD system renderer integrated, we probably won't mess with inlining.

Link to comment
Share on other sites

I've used the inline spawnarg in my maps. It allows you to scale func statics to larger than 100 percent without the odd bug where upscaled objects disappear when at the edges of the screen.

But you should walk having internal dignity. Be a wonderful person who can dance pleasantly to the rhythm of the universe.

-Sun Myung Moon

 

My work blog: gfleisher.blogspot.com

Link to comment
Share on other sites

Are they inaccessible func statics Moonbo? So collision doesn't matter?

 

I took a quick look in the code out of curiosity even though no-one actually wants it fixing. It's all as reported as far as I can see: dmap generates visible models in the proc file for inline models (and scales them too). Note: all models generated by dmap are for looks only: they're not solid. Then the world collision model is generated but it seems to handle only brushes and patches. Then on map start, the entity is simply hidden. It's neither prevented from spawning nor removed.

Link to comment
Share on other sites

.... for looks only: they're not solid.

 

How about having collision hull for inlined models? (textures/common/collision surface)

 

Then the world collision model is generated but it seems to handle only brushes and patches. Then on map start, the entity is simply hidden. It's neither prevented from spawning nor removed.

 

In other words it's still an entity? Is there a cvar to show entities count? Might just inline a model, and check entities count to see if it was left in the pool or removed. It would be cool to still have it as accessible entity, but so that it doesn't take up place in the total pull of entities.

Link to comment
Share on other sites

How about having collision hull for inlined models? (textures/common/collision surface)

The collision loader could handle that I'm sure, it just looks like it doesn't.

 

In other words it's still an entity? Is there a cvar to show entities count? Might just inline a model, and check entities count to see if it was left in the pool or removed. It would be cool to still have it as accessible entity, but so that it doesn't take up place in the total pull of entities.

Based on what I saw, the entity will still count. Not sure if there's a cvar to count entities, but there's one that shows their bounding boxes and names, including hidden entities: g_showentityinfo

Link to comment
Share on other sites

Hey Steve,

 

They're definitely accessible (for instance, the chandeliers that the player can climb on in the church in Requiem are inlined), but because TDM doesn't scale up the collision model along with the visible model, I removed their collision and replaced it with nodraw brushes.

But you should walk having internal dignity. Be a wonderful person who can dance pleasantly to the rhythm of the universe.

-Sun Myung Moon

 

My work blog: gfleisher.blogspot.com

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.

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

  • Recent Status Updates

    • peter_spy

      What a lovely game, perfect way to relax before sleep.
      · 3 replies
    • STiFU

      Anyone here clocking in some times in Neon Light?
      · 0 replies
    • JackFarmer

      Boris Johnson's resignation does not change the fact that Australia is home to 29 million kangaroos and Wales has a population of just over three million.

      If the Australian kangaroos were to invade Wales, one resident would have to fight almost ten kangaroos at a time.
      · 8 replies
    • peter_spy

      Deathloop – what a mess of a game. I'd love to see a post-mortem on it some day. I hope Arkane is doing okay though.
      · 27 replies
    • OrbWeaver

      I like house-cleaning and taking out the trash.
      · 3 replies
×
×
  • Create New...