Muzzle Flash

In this forum you will find and post information regarding the modding of Star Wars Battlefront 2. DO NOT POST MOD IDEAS/REQUESTS.

Moderator: Moderators

Post Reply
Eaol
Major
Major
Posts: 510
Joined: Fri Jul 31, 2009 5:49 pm
Games I'm Playing :: SWBF2 and Warframe
Location: Everywhere.

Muzzle Flash

Post by Eaol »

Is there any way to change the muzzle flash effect? I noticed that there's a file in the FX folder for a large muzzle flash, containing a puff of smoke. Is there perhaps a way to set up an effect to appear when the muzzle flash appears?
JimmyAngler
High General
High General
Posts: 837
Joined: Mon Nov 04, 2013 10:37 am
Projects :: Battlefront Halation
Games I'm Playing :: SWBF 1-2-2015
xbox live or psn: none
Location: Area 51

Re: Muzzle Flash

Post by JimmyAngler »

Yeah, just add an emitter to the muzzle flash.fx file.
LRKfm946
Master Sergeant
Master Sergeant
Posts: 163
Joined: Sun Feb 02, 2014 6:13 pm
Projects :: Battlefront II Hunger Games
Games I'm Playing :: SWBF2 BF3
Contact:

Re: Muzzle Flash

Post by LRKfm946 »

Change the Discharge effect:

Code: Select all

MuzzleFlash         = "small_muzzle_flash"
FlashColor          = "80 80 255 255"     
FlashLength         = 0.025               
FlashColor          = "100 100 255 255"   
FlashLength         = 0.025               
FlashLightColor     = "220 220 255 175"   
FlashLightRadius    = "2.0"               
FlashLightDuration  = "0.25"              
Discharge           = "small_smoke_effect"   //<--Change this to whatever you want
Marth8880
Resistance Leader
Posts: 5042
Joined: Tue Feb 09, 2010 8:43 pm
Projects :: DI2 + Psychosis
Games I'm Playing :: Silent Hill 2
xbox live or psn: Marth8880
Location: Edinburgh, UK
Contact:

Re: Muzzle Flash

Post by Marth8880 »

The Discharge ODF parameter doesn't work. (Unless of course you've gotten it to work. :o ...Please tell me someone's finally gotten it to work.)
LRKfm946
Master Sergeant
Master Sergeant
Posts: 163
Joined: Sun Feb 02, 2014 6:13 pm
Projects :: Battlefront II Hunger Games
Games I'm Playing :: SWBF2 BF3
Contact:

Re: Muzzle Flash

Post by LRKfm946 »

Oh, nevermind then. :? Do what Jimmy said.
Eaol
Major
Major
Posts: 510
Joined: Fri Jul 31, 2009 5:49 pm
Games I'm Playing :: SWBF2 and Warframe
Location: Everywhere.

Re: Muzzle Flash

Post by Eaol »

JimmyAngler wrote:Yeah, just add an emitter to the muzzle flash.fx file.
But isn't that effect unused? I've never seen the contents of that file actually used in the game (the puff of smoke and whatnot).
kinetosimpetus
Imperial Systems Expert
Imperial Systems Expert
Posts: 2381
Joined: Wed Mar 25, 2009 4:15 pm
Projects :: A secret project
Games I'm Playing :: Warframe STO

Re: Muzzle Flash

Post by kinetosimpetus »

AFAIK the only way to make a custom muzzle fx on a trooper is to make a trail fx that is offset so it appears near the gun barrel, such as:

Image

An effect like that could be added, but it'd need to be a different custom one for every gun as they are different sizes.

I don't think you can get rid of the stock flash... unless you make its color black maybe?
JimmyAngler
High General
High General
Posts: 837
Joined: Mon Nov 04, 2013 10:37 am
Projects :: Battlefront Halation
Games I'm Playing :: SWBF 1-2-2015
xbox live or psn: none
Location: Area 51

Re: Muzzle Flash

Post by JimmyAngler »

Um way off, AQT did it for Halofront. You need two planes. One for side view and one for front/back view. Texture them, load them in your ingame, and add it to you weapon odf:

Code: Select all

MuzzleFlashModel	= "modelname"
Eaol
Major
Major
Posts: 510
Joined: Fri Jul 31, 2009 5:49 pm
Games I'm Playing :: SWBF2 and Warframe
Location: Everywhere.

Re: Muzzle Flash

Post by Eaol »

Yeah I tried that, Kinetos, and I got unsatisfactory results (the thing with an offset effect) - it'd move around when I looked around so that sometimes it'd be off.
AQT
Gametoast Staff
Gametoast Staff
Posts: 4910
Joined: Sat Nov 03, 2007 4:55 pm
Location: SoCal, USA

Re: Muzzle Flash

Post by AQT »

JimmyAngler wrote:Um way off, AQT did it for Halofront. You need two planes. One for side view and one for front/back view. Texture them, load them in your ingame, and add it to you weapon odf:

Code: Select all

MuzzleFlashModel	= "modelname"
For the record, I'd just like to point out that DarthD.U.C.K. did it for Prosecutor, and I merely reused the asset in an originally stand-alone map.
kinetosimpetus
Imperial Systems Expert
Imperial Systems Expert
Posts: 2381
Joined: Wed Mar 25, 2009 4:15 pm
Projects :: A secret project
Games I'm Playing :: Warframe STO

Re: Muzzle Flash

Post by kinetosimpetus »

Can you post a more specific instruction on how it was done?
User avatar
Nedarb7
Lieutenant General
Lieutenant General
Posts: 676
Joined: Sat Sep 22, 2012 3:41 pm

Re: Muzzle Flash

Post by Nedarb7 »

If anyone is still wondering here is how it looks in the stock game:
- Model
Hidden/Spoiler:
ImageImage
- Texture (alpha layer)
Hidden/Spoiler:
Image
- Weapon ODF

Code: Select all

MuzzleFlashModel = "flashmodel"
I believe the stock flash model name is "meshmuzzleflash" (found in SWBF1 assets).

In order to get your new muzzle flash model into the game you will need to load it into a req (lvl) that will be loaded into the mission.
Say your side's req or the ingame req.

Here's an example of a custom muzzle flash put together by simply retexturing the stock flash's texture:
Hidden/Spoiler:
Image
Eaol
Major
Major
Posts: 510
Joined: Fri Jul 31, 2009 5:49 pm
Games I'm Playing :: SWBF2 and Warframe
Location: Everywhere.

Re: Muzzle Flash

Post by Eaol »

Yeah, I've been doing it that way, but I had created a really movie-accurate .fx file for a muzzle flash and wanted to know if I could attach it somehow; unfortunately, I had it sort of working but it'd move around so that sometimes, it'd be floating above or below the muzzle by a foot or so. Thanks anyway!
Post Reply