View unanswered posts | View active topics


Post a new topicPost a reply
Previous topic | Next topic 

User avatar   Beginner BeginnerMember since: 19.04.2012, 21:26Posts: 76 Likes: 0
 

 Post Topic: Making A Flashlight As A Weapon?
PostPosted 22.04.2012, 16:58 
How would I make a flashlight as a weapon. By weapon I mean something you can wield, that emits light. I've already modeled it in 3DS Max, how do I get the light coming out of it in the actual CE3?
I'd also want a button that turns the light on or off.

User avatar   Trainee TraineeMember since: 24.08.2011, 15:48Posts: 184Location: I do believe at home... Likes: 1
 

 Post Topic: Re: Making A Flashlight As A Weapon?
PostPosted 28.04.2012, 00:00 
I also need to know that.


Co Leader of Aloadae
We still got Jobs open
Look here who is needed: Aloadae
  Beginner BeginnerMember since: 28.12.2010, 22:31Posts: 76Location: Sydney, Australia Likes: 2
 

 Post Topic: Re: Making A Flashlight As A Weapon?
PostPosted 12.05.2012, 03:01 
You could place it as a BasicEntity, and enable the Pickable option (meaning you can pick it up). Then place a SimpleLight, change the projector texture to something resembling a flashlight, change the radius, colour, etc. to the desired values, then link the light to the flashlight. This will allow the player to pick up the flashlight and shine the light around. However, using this technique doesn't provide much flexibility in regards to how the character holds the light, which direction the flashlight is pointing, etc.

If my way does not work, I'd recommend following a simple weapon tut and then link the SimpleLight to the weapon once it's ready to be used.

Best of luck :)
User avatar   Trainee TraineeMember since: 24.08.2011, 15:48Posts: 184Location: I do believe at home... Likes: 1
 

 Post Topic: Re: Making A Flashlight As A Weapon?
PostPosted 01.08.2012, 11:25 
*push*
I still don´t know really how to do the flashlight. It should be probably be done with the xml.


Co Leader of Aloadae
We still got Jobs open
Look here who is needed: Aloadae
  Beginner BeginnerMember since: 09.06.2012, 01:21Posts: 87Location: Germany Likes: 0
 

 Post Topic: Re: Making A Flashlight As A Weapon?
PostPosted 02.08.2012, 15:59 
You can create an flowgraph for an simple light.
Like this: http://www.crydev.net/viewtopic.php?f=325&t=91213
(but when doing the height maybe take the height of the camera, just write an pm if you want to know how, cause if youre going to crouch or prone the flashlight won't will be usable right.)

In same flowgraph you take the weapon sensor. When weapon flashlight is currently selected, you're able to set the falshlight on or off, if it's not selected its off every time.

If you don't get it, write me a pm, I will describe it more.

-Bennz


User avatar   Trainee TraineeMember since: 24.08.2011, 15:48Posts: 184Location: I do believe at home... Likes: 1
 

 Post Topic: Re: Making A Flashlight As A Weapon?
PostPosted 02.08.2012, 16:55 
Thanks, that was a big step forward. But yea, I also need the height, for example looking up or down.

I tried with weapon sensor and I didn´t get it to work. If I select another weapon the light sticks in the air and stays there. Also I could attach the flashlight only to an entity of the weapon, not the weapon itself (for example the weapon i have from beginning won´t have a flashlight, only the entity which I pick up).

Well also the FPS drops quite alot as Cry-Spify said.

Can´t be this done with a dummy in the rig?


Co Leader of Aloadae
We still got Jobs open
Look here who is needed: Aloadae
  Skilled Modder Skilled ModderMember since: 06.09.2012, 20:32Posts: 680Location: San Juan Island, Washington Likes: 93
 

 Post Topic: Re: Making A Flashlight As A Weapon?
PostPosted 25.10.2012, 23:01 
I think this is going to be one of my next projects. If someone wants to contribute the actual flashlight model and rigging for it (whatever I need to actually hold and see the flashlight in first and third person modes), I'll do all of the C++/XML code to make it a real weapon and release it.


Image

Miscreated - Official Website: http://miscreatedgame.com
Steam Greenlight: http://bit.ly/14h87r8
Facebook: http://on.fb.me/XBeB3p
Twitter: http://bit.ly/XBeyEK