Making fire

Have questions about CoD4 mapping that aren't covered in the tutorials section? Post here!

Moderator: Core Staff

Post Reply
inzerke
CJ Wannabe
CJ Wannabe
Posts: 15
Joined: February 18th, 2012, 9:27 am

Making fire

Post by inzerke » February 20th, 2012, 6:10 pm

Hi guys,

I wanted to make a floor who's on fire and followed the next tutorial:

http://modsonline.com/Tutorials-read-448.html

I've noticed that this isn't 100% working.
Also how to make a whole floor on fire instead of a little barrel?

Still back to the basic question to get that barrel script working.
I used the following part of the script in ther tutorial, notice I edited some small things which i though it would work:

Code: Select all

{             
	level._effect["fire"] = loadfx ("fx/fire/fire_barrel_fragm_a.fx");
        maps\mp\_fx::loopfx("fire", ( X, Y, Z), 3);             
	level._effect["smoke"] = loadfx ("fx/smoke/thin_black_smoke_M.fx");
        maps\mp\_fx::loopfx("smoke", ( X, Y, Z), 3); 
}
Can anybody also explain with what the ( X, Y, Z), 3); does?

Thanks for help already.

Copy-Cat
CJ Wannabe
CJ Wannabe
Posts: 30
Joined: July 1st, 2011, 2:01 am

Re: Making fire

Post by Copy-Cat » February 20th, 2012, 6:42 pm

In my recent experience with working with FX I have found that the wiki tutorial did not work as expected. I made a few changes to the script after loading the map in Dev mode and reading the errors the console gave me.

1. The path of your effect

Code: Select all

("fx/fire/fire_barrel_fragm_a.fx");
in the gsc script at least for it to work for me should read.

Code: Select all

{             
   level._effect["fire"] = loadfx ("fire/fire_barrel_fragm_a");
        maps\mp\_fx::loopfx("fire", ( X, Y, Z), 3);             
   level._effect["smoke"] = loadfx ("smoke/thin_black_smoke_M");
        maps\mp\_fx::loopfx("smoke", ( X, Y, Z), 3); 
}


Notice I changed the path and also I removed the file extension ".fx" for the name of the effect.

The (X, Y, Z ) are the coordinates withing your map that you want the effect. The easiest way for me to find out the coordinates was to create an Info - Null object at the location I want the effect and copy the coordinates from the Entity's origin values, and paste them into my gsc, remembering to add the commas. If you followed the tutorial correctly you now should have a

raw/maps/mp/mp_yourmap_fx.gsc
and a
raw/maps/createfx/mp_yourmap_fx.gsc

for yourmap. In addition you now should have 4 lines added to your mp_yourmap.csv or your zone file as it is called.

Code: Select all

fx,fire/fire_barrel_fragm_a
fx,smoke/thin_black_smoke_M
rawfile,maps/createfx/mp_yourmap_fx.gsc
rawfile,maps/mp/mp_yourmap_fx.gsc
Now if someone could figure out how to add effects without having to include them in our gsc scripts like the 1rst option of the tutorial you were looking at, I think that would be a hella easier.

inzerke
CJ Wannabe
CJ Wannabe
Posts: 15
Joined: February 18th, 2012, 9:27 am

Re: Making fire

Post by inzerke » February 20th, 2012, 7:16 pm

Just to clear things up for other people,
You can use the tutorial with the following script:

Code: Select all

{             
   level._effect["fire"] = loadfx ("fx/fire/fire_barrel_fragm_a.fx");
        maps\mp\_fx::loopfx("fire", ( X, Y, Z), 3);             
   level._effect["smoke"] = loadfx ("fx/smoke/thin_black_smoke_M.fx");
        maps\mp\_fx::loopfx("smoke", ( X, Y, Z), 3);
}
Thanks to Copy-Cat for making that clear to me. :)
It's working now.

EDIT:
how to make a large floor on fire instead of a small barrel?

Copy-Cat
CJ Wannabe
CJ Wannabe
Posts: 30
Joined: July 1st, 2011, 2:01 am

Re: Making fire

Post by Copy-Cat » February 20th, 2012, 7:38 pm

hmmm, I tried like for 4 hours trying to get that script to work.

What exactly did I say that helped you. :D

Please elaborate on what you did so others can do the same.

User avatar
Buzzard
CJ Wannabe
CJ Wannabe
Posts: 23
Joined: November 5th, 2009, 7:13 pm

Re: Making fire

Post by Buzzard » February 20th, 2012, 7:55 pm

inzerke wrote:EDIT:
how to make a large floor on fire instead of a small barrel?
As far as I know you only have two options:
1) Spawn a lot of effects side by side (This will probably look not so good and could cause problems when you have lots of effects in your map).
2) Create/Search a new effect which fits better.

I would recommend number 2) to you. If you have no/not that much experience with the effect editor I would suggest this tutorial by Rezil: viewtopic.php?f=19&t=11909
Last edited by Buzzard on February 20th, 2012, 7:58 pm, edited 1 time in total.

inzerke
CJ Wannabe
CJ Wannabe
Posts: 15
Joined: February 18th, 2012, 9:27 am

Re: Making fire

Post by inzerke » February 20th, 2012, 7:57 pm

Didn't want to create so much effect near each other for :
1) the work with co-ordinates
2) maybe fps drop there?

Lets have a look at the link you gave me,
hope it helps :d

Copy-Cat
CJ Wannabe
CJ Wannabe
Posts: 30
Joined: July 1st, 2011, 2:01 am

Re: Making fire

Post by Copy-Cat » February 20th, 2012, 8:05 pm

Buzzard wrote: I would recommend number 2) to you. If you have no/not that much experience with the effect editor I would suggest this tutorial by Rezil: viewtopic.php?f=19&t=11909
OMG!!!!!

That is an awesome tut!

Kudos

User avatar
Rezil
Core Staff
Core Staff
Posts: 2030
Joined: July 24th, 2006, 11:21 am
Location: Cramped in a small cubicle/making another jump map

Re: Making fire

Post by Rezil » February 21st, 2012, 1:25 am

Thanks for the feedback. I'd be happy to write some more tutorials, but I don't really know what people have trouble with and what exactly hasn't already been covered elsewhere.
Drofder2004: Drofder's rules for reviewing a map
[...]
#5 If your name is Rezil, minimum 5/5.
---
<LT>YosemiteSam[NL]:
I heard somewhere that the best way to start is juggling 2 balls with one hand, so you will get a feel for it.

Post Reply

Who is online

Users browsing this forum: No registered users and 30 guests