_remap for models?


(fraco) #1

lo,

how can i use _remap to remap model shaders? I want to replace the shader of a model to basically reskin that model for my map.

the q3map2 readme says
<< Key “_remapNN” “the/model/shader;the/real/shader”>>

I did try that, but each and every instance of that model got affected (or maybe each and every instance of that shader), even for instances of the model without the _remap key. Is that the nature of _remap, being global for the entire map? So I can best add it to worldspawn then?

thnx

fraco


(ydnar) #2

Put _remap{N} keys on misc_model entities. If the model has a single shader, you can use * instead of the source shader name, like so:

“_remap01” “*;models/mapobjects/mystuff/myshader”

Odd that your remaps are affecting the models globally. Are you sure you just put the remaps on the right model entities?

y


(fraco) #3

of course I don’t have that particular map anymore. But I’ll try remap again tonight.

b.t.w. if i use the -rename switch do i need to remap the _bsp shaders to my own or what?

“remap01” “blabla_bsp;blabla_mine_bsp”
or
“remap01” “blabla;blabla_mine”

thnx

fraco


(Davros) #4

(fraco) #5

:-S what are you saying Torchy, that i should try and make more sense. I was just trying ask if _remap needed to refer to the renamed shaders for misc_models or to the original ones…

regards

fraco


(Davros) #6

sorry, it was my quick way of saying the bottom choice :). i take it your mapping for sof2/jk2 hence the -rename function. just make sure you make another model shader with the _bsp suffix and rgbgen vertex near the bottom, not lightingdiffuse


(fraco) #7

hmm thnx for the reply, but still confused.

yes sof2.

I use rename and fill out modified shaders with the bsp extension. Now for some of my models I need to _remap the shader to yet another one.
So, you’re saying i need to refer to the original shaders not the renamed ones.

sorry to keep nagging about this.

So if I use _rename, my model uses
normal_shaders_bsp useful for dropping the - whatever it does- lightingdiffuse stuff.

if I remap i specify
_remap of normal_shader;myown_shader

and i actually have to fill out a myown_shader_bsp. That particular model doesn’t need the normal_shader_bsp anymore.

This right? I will stop whining about it anyhow and just try it out :-).

thnx for all the help


(ydnar) #8

The remapping happens before the _bsp suffix appending. So, if you have:

“_remap01” “*;models/mapobjects/foo/bar”

And you use the -rename switch, then you need to have a shader:

models/mapobjects/foo/bar_bsp

In order for it to work correctly.

y


(fraco) #9

_remap works perfectly well on one single model leaving the other models shaders as they were. Just like you said Ydnar.

I probably need new glasses :-S

thread closed

fraco