breakable mirror? + please ansver my newest problem??


(kgbdino) #1

how do i make a mirror in my map?`

and if possible how do i make a mirros i can seethru in 1 way and it reflects light the other way.
please help me again…


(carnage) #2

ime not sure if u can make a mirror breakable

to fake it you could use a func_static decal texture that makes it look smashed


(kgbdino) #3

you can make evrything breakable (so it said in the tutorial) but it didnt say how to make a mirror
but how do i make a mirror? please help me


(Chester) #4

Well, if you already have a mirror texture just do one side with the mirror brush and then the other side with “NO DRAW”. Works fine for me.

Also, if you dont feel like making a mirror texture you could setup a camera to point and project that image. More useful for cameras though.


(kgbdino) #5

well the problem is that i have no clue of how/where i get a mirror texture
and i have no clue of how i can setup a camera and a projector :???:


(No1_sonuk) #6

I have no idea how to write a portal shader, but I do know that the difference between a mirror and a “CCTV monitor” is the existence of a camera.
For a mirror, you place a misc_portal_surface within 64 block units of the mirror surface. To make it into a CCTV monitor, target the misc_portal_surface from a misc_portal_camera.


(kgbdino) #7

well, thank you? :???:
i would say thank you is i had any clue of how i did what you explained
(sorry people but i really am a n00b in that)


(Jaquboss) #8

mirror can be func_explosive ( tried, however dont use same shader for gibs), you must turn off fastsky to see it …
And it was here several time , search!


(Nocturne) #9

what about the die command in scripts?


(LaggingTom) #10

A mirror is whatever texture you please, with the line:

portal

Added into its shader. My perfectly scratchless mirror texture is a 32x32 plain black .tga You can make scratches on the black as if you would want them on the mirror.


(carnage) #11

when you say on the black do you mean the alpha chanel?


(Jaquboss) #12

lol , you can use textures/common/dirtymirror …
And black alpha means mirrored space , white alpha means dirty space


(kgbdino) #13

so if i make a .tga fiel that is black i can get mirrors?


(Jaquboss) #14

textures/common/mirror
{
	qer_editorimage textures/common/mirror.tga
	portal
	surfaceparm nonsolid
	surfaceparm nomarks
	{
	map textures/common/mirror.tga
	blendfunc GL_ONE GL_ONE_MINUS_SRC_ALPHA
	depthWrite
	}    
}

Just make black texture named mirror and move it to textures/common
Also never forget , that misc_portal_surface must be maximaly 64 units far from mirror , and you should never texture more than 1 sides of brush of mirror , and there cant be two mirrors visible at once… also check that there isnt mirror reflecting in another mirror…
As for more brush sides , it works but you get pretty nasty artifact…
For func breakable , just dont set Same shader spawnflag…


(kgbdino) #15

well thanks
exept do i make this a script or what??


(Jaquboss) #16

yep , just copy to mirror.shader for example and put in scripts…


(kgbdino) #17

and how do i choose where it will be mirrors?
is it just to choose a side of a brush and use the mirror texture?


(Jaquboss) #18

yeah like that , you will texture whole brush with some neutral texture and then drag mirror texture over side which will reflect ( unselect brush before you will drag texture ) , then place misc_portal_surface in front of it


(kgbdino) #19

to place misc_portal_surface do i have to right clink in 2d field and choose it in misc menu?
because if thats how it is done i cant do it


(Jaquboss) #20

well , there isnt normaly misc_potal_surface , you can put there whatever , select it , press n , click on classame and rewrite it to misc_portal_surface , then press enter and you have it :wink: