Jump to content


Photo

How to create a filter: to hide a specific model type?


  • Please log in to reply
6 replies to this topic

#1 Bikerdude

Bikerdude

    Mod hero

  • Member
  • PipPipPipPipPip
  • 19973 posts

Posted 15 March 2018 - 07:46 AM

So I am trying to find a way to hide a specific model type, in this case .LWO - any ideas..?



#2 nbohr1more

nbohr1more

    Darkmod PR, Wordsmith

  • Development Role
  • PipPipPipPipPip
  • 8866 posts

Posted 15 March 2018 - 08:13 AM

Hmm...
 
<filter name="Hide LWO">
	<filterCriterion type="entityclass" match=".*" action="show" />
	<filterCriterion type="entityclass" match="*.lwo" action="hide" />
</filter>

?
Please visit TDM's IndieDB site and help promote the mod:

http://www.indiedb.c...ds/the-dark-mod

(Yeah, shameless promotion... but traffic is traffic folks...)

#3 Judith

Judith

    Advanced Member

  • Member
  • PipPipPip
  • 1323 posts

Posted 15 March 2018 - 08:19 AM

EDIT:

 

NVM, looks like nbohr1more got this.


Edited by Judith, 15 March 2018 - 08:21 AM.


#4 OrbWeaver

OrbWeaver

    Mod hero

  • Active Developer
  • PipPipPipPipPip
  • 7485 posts

Posted 15 March 2018 - 10:15 AM

Hmm...
 

<filter name="Hide LWO">
	<filterCriterion type="entityclass" match=".*" action="show" />
	<filterCriterion type="entityclass" match="*.lwo" action="hide" />
</filter>

?

 

 

It's been a long time since I worked on the filter system, but I'm dubious that that would work. The entity class for a model is going to be func_static, surely, rather than including the model file extension?

 

I think you'd need a filter that matches on the model spawnarg, if the filter system supports matching on arbitrary spawnargs.



#5 Bikerdude

Bikerdude

    Mod hero

  • Member
  • PipPipPipPipPip
  • 19973 posts

Posted 15 March 2018 - 10:54 AM

<filter name="Hide LWO">
	<filterCriterion type="entityclass" match=".*" action="show" />
	<filterCriterion type="entityclass" match="*.lwo" action="hide" />
</filter>

Tried this already, the above causes a error popup in DR and if you click abort DR crashes to desktop.


Edited by Bikerdude, 15 March 2018 - 11:14 AM.


#6 Obsttorte

Obsttorte

    Scripting guru, Mapper

  • Active Developer
  • PipPipPipPipPip
  • 5608 posts

Posted 15 March 2018 - 05:25 PM

The following will work (tested it).

  • go to filters/edit filters
  • press the add button
  • give the filter a suitable name
  • press the add button to add a new filter rule
  • apply the following settings: Type=entitykeyvalue Entity Key=model Match=(*.).lwo Action=hide
  • press save to confirm the changes

Note that you can bind a keyboard shortcut to your custom filter (useful if you use it often).

 

Attached Files


FM's: Builder Roads, Old Habits, Old Habits Rebuild
WIP's: Several. Although after playing Thief 4 I really wanna make a city mission.
Mapping and Scripting: Apples and Peaches
Sculptris Models and Tutorials: Obsttortes Models
My wiki articles: Obstipedia
Let's Map TDM YouTube playlist: ObstlerTube
Texture Blending in DR: DR ASE Blend Exporter

End of shameless self promotion.

#7 Bikerdude

Bikerdude

    Mod hero

  • Member
  • PipPipPipPipPip
  • 19973 posts

Posted 15 March 2018 - 05:29 PM

Nice, thanks for that Obs!






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users