<div class="IPBDescription">How to put a laser beam on a gun</div> Does anyone know how to put a laser beam on a gun? is there a guide or something that could help me ?
but i thought that if u put a half visible cylinder on the end fo a barrel it would go through walls so u can see it on the other side <!--emo&???--><img src='http://www.unknownworlds.com/forums/html/emoticons/confused.gif' border='0' style='vertical-align:middle' alt='confused.gif'><!--endemo-->
Using a long laser beam on a weapons P_ model would be called cheating (spiked models). But to have a long laserbeam on the weapons V_ model is not cheating, cause the V_ model is in no way visible from third person view or a player being looked at.
ok, the ultra short "How to add a laser to your model" tut 1: open the base SMD in any modeling program 2: Add a cylender (cant spell, too early...) 3: make the skin somtihng easy to remember, like laser.bmp 4: Jig around a chair 5: open the base SMD with notepad 6: add a line of code (check the transparnecy thred 7: compile 8: play 9: give me all your money
Only onsiedered a cheat if he adds it to his P_mdl, keep it as a W or V model or we'll send some flying Scorpians after you
but even in the v view it will look strange... because the weapon model gets rendered seperatly and projected on the first person view the playermodel will not clip through buildings and stuff.. it must be look pretty odd when you stand close to the wall and your laser beam runs virtualy infinity into the depth without collision..
other thing is the laser will overlay every playermodel..
ah o yea the firstperson model is diff from third lol i forgot about that soz <!--emo&:D--><img src='http://www.unknownworlds.com/forums/html/emoticons/biggrin.gif' border='0' style='vertical-align:middle' alt='biggrin.gif'><!--endemo-->
Wow, so many replies and not one person even knows how to properly do this one little thing. Headcrab has it the closest, but he's still totally wrong. I imagine he means opening the QC file in notepad, and not the SMD. Opening the SMD in notepad is for adding joints...
Making a laser that looks cool is a slightly complicated operation, but at its basic level you're just adding a cylinder to the end of your gun.
I'm going to try explaining it quickly, but I'm assuming you have some knowledge of basic modelling for half-life. If you lack that, then sour grapes to you. Easiest and ugliest way of doing it, is to just make a closed cylinder and assign it to some dark red texture. Assign the vertices of the cylinder to the main part of your gun. You can flip the faces at the end of the cylinder to simulate the red dot. When you're editting the qc file add the line $texrendermode "<your dark red texture here>.bmp" "additive". It has to be additive and not masked.
The red dot that clips through walls(Heinlein anyone?) can be fixed, but I'm not going to try and explain it.
If you have any questions relating to any of this, then go find someone who wants to answer them. I'm just doing my one good samaritan deed for the day.
The problem with reversing the faces on the end of the laser, applying a red texture over them is that you really begin to notice it when you stand close to a wall. You also have to extend the cylinder waaaaayyy out in left field, leaving you with a big red streak that goes off into infinity, leaving color banding on the edges of the shape, which looks really ugly in-game. I'm using Oppee's laser, which has a good skin that I'm working on moving around. There's a nasty banding effect on one egde of the beam, with a gradient effect on the other. I'm currently trying to fix that one up right now, but shrinking the red field and smoothing up the edges also makes it darker than I'd like in-game.
And Duo, you need the updated studiomdl.exe <a href='http://collective.valve-erc.com/index.php?doc=1043360861-70912800' target='_blank'>here.</a>
<span style='color:red'>IF YOUR NOT RUNNING WINDOWS XP, THEN THIS MIGHT NOT WORK</span>
<span style='color:green'>Dosen't matter where you put it, say you put it in C:\x\x (I'm sure someone like you would understand what I mean). Then click the start button in the lower left corner of your screen (again, only a totaly clueless computer n00b woulden't understand me), go to All Programs, go to Accessories, then click on Command Prompt. Say you put studiomdl.exe in C:\x\x like I told you too, type:
C:\x\x\studiomdl.exe
then hit enter. An *** ERROR *** message should come up, with a bunch of crap, this is good, this means you got the right directory for studiomdl.exe. Hit the up arrow so C:\x\x\studiomdl.exe comes up again, then type whereever your decompiled model is (say you decompiled it to C:\x\c\), then add the name of the .qc. So say you decompiled v_WTH.mdl to C:\x\c\, you would have the .qc, the .smds and all that crap, you would add:
C:\x\c\v_WTH.qc
to the line, so it reads:
C:\x\x\studiomdl.exe C:\x\c\v_WTH.qc
then hit enter. This is ofcourse, after you added the $texrendermode thing and did what every one else told you. Now you see all kinds of stuff being compiled, now you have to find the compiled .mdl. Before you typed all that C:\x\x\ stuff, theres something like:
C:\Documents and Settings\Owner.YOUR-xxxxxxx.000>
before you added C:\x\x\ whatever to it (this is just an example of what mine says). You just find that folder (C:\Documents and Settings\Owner.YOUR-xxxxxxx.000> for me), open it, and your compiled .mdl should be there.</span>
<span style='color:yellow'>If you have any questions or problems, just ask me.</span>
Or you could just right-click the .qc, select Open With, click Browse, browse to the directory you put studiomdl.exe, select it, uncheck "always open with this program", and you're good to go.
Hmm...what would the world be like without snoopy? <!--emo&:0--><img src='http://www.unknownworlds.com/forums/html/emoticons/wow.gif' border='0' style='vertical-align:middle' alt='wow.gif'><!--endemo-->
* * * * *
...I think I got a pretty good idea. <!--emo&;)--><img src='http://www.unknownworlds.com/forums/html/emoticons/wink.gif' border='0' style='vertical-align:middle' alt='wink.gif'><!--endemo-->
Man this guy keeps pm'ing me u need block on these forums <!--emo&::nerdy::--><img src='http://www.unknownworlds.com/forums/html/emoticons/nerd.gif' border='0' style='vertical-align:middle' alt='nerd.gif'><!--endemo-->
god its funny to watch nerds fighting <!--emo&:p--><img src='http://www.unknownworlds.com/forums/html/emoticons/tounge.gif' border='0' style='vertical-align:middle' alt='tounge.gif'><!--endemo-->
Anybody can make the standart LMG with a Laser Beam 4 me? <!--emo&::marine::--><img src='http://www.unknownworlds.com/forums/html/emoticons/marine.gif' border='0' style='vertical-align:middle' alt='marine.gif'><!--endemo-->
Comments
1: open the base SMD in any modeling program
2: Add a cylender (cant spell, too early...)
3: make the skin somtihng easy to remember, like laser.bmp
4: Jig around a chair
5: open the base SMD with notepad
6: add a line of code (check the transparnecy thred
7: compile
8: play
9: give me all your money
Only onsiedered a cheat if he adds it to his P_mdl, keep it as a W or V model or we'll send some flying Scorpians after you
but even in the v view it will look strange... because the weapon model gets rendered seperatly and projected on the first person view the playermodel will not clip through buildings and stuff.. it must be look pretty odd when you stand close to the wall and your laser beam runs virtualy infinity into the depth without collision..
other thing is the laser will overlay every playermodel..
Making a laser that looks cool is a slightly complicated operation, but at its basic level you're just adding a cylinder to the end of your gun.
I'm going to try explaining it quickly, but I'm assuming you have some knowledge of basic modelling for half-life. If you lack that, then sour grapes to you. Easiest and ugliest way of doing it, is to just make a closed cylinder and assign it to some dark red texture. Assign the vertices of the cylinder to the main part of your gun. You can flip the faces at the end of the cylinder to simulate the red dot. When you're editting the qc file add the line $texrendermode "<your dark red texture here>.bmp" "additive". It has to be additive and not masked.
The red dot that clips through walls(Heinlein anyone?) can be fixed, but I'm not going to try and explain it.
If you have any questions relating to any of this, then go find someone who wants to answer them. I'm just doing my one good samaritan deed for the day.
bad command $texrendermode
that's all i'm getting....but then again i'm using milkshape >.<
and it should be in additive mode for the right effect
And Duo, you need the updated studiomdl.exe <a href='http://collective.valve-erc.com/index.php?doc=1043360861-70912800' target='_blank'>here.</a>
<span style='color:green'>Dosen't matter where you put it, say you put it in C:\x\x (I'm sure someone like you would understand what I mean). Then click the start button in the lower left corner of your screen (again, only a totaly clueless computer n00b woulden't understand me), go to All Programs, go to Accessories, then click on Command Prompt. Say you put studiomdl.exe in C:\x\x like I told you too, type:
C:\x\x\studiomdl.exe
then hit enter. An *** ERROR *** message should come up, with a bunch of crap, this is good, this means you got the right directory for studiomdl.exe. Hit the up arrow so C:\x\x\studiomdl.exe comes up again, then type whereever your decompiled model is (say you decompiled it to C:\x\c\), then add the name of the .qc. So say you decompiled v_WTH.mdl to C:\x\c\, you would have the .qc, the .smds and all that crap, you would add:
C:\x\c\v_WTH.qc
to the line, so it reads:
C:\x\x\studiomdl.exe C:\x\c\v_WTH.qc
then hit enter. This is ofcourse, after you added the $texrendermode thing and did what every one else told you. Now you see all kinds of stuff being compiled, now you have to find the compiled .mdl. Before you typed all that C:\x\x\ stuff, theres something like:
C:\Documents and Settings\Owner.YOUR-xxxxxxx.000>
before you added C:\x\x\ whatever to it (this is just an example of what mine says). You just find that folder (C:\Documents and Settings\Owner.YOUR-xxxxxxx.000> for me), open it, and your compiled .mdl should be there.</span>
<span style='color:yellow'>If you have any questions or problems, just ask me.</span>
*
*
*
*
*
...I think I got a pretty good idea. <!--emo&;)--><img src='http://www.unknownworlds.com/forums/html/emoticons/wink.gif' border='0' style='vertical-align:middle' alt='wink.gif'><!--endemo-->