MODSonline
  Welcome Guest to MODSonline Home | Forums | Register | Login
Main-Menu
Home
Login
Register
Add Download
Add News
Add Tutorial *
Forums

Advertise
Affiliate Store US *
Affiliate Store UK *
Affiliate Store CA *
Angry Letter Generator
Avatar Upload
Calendar of Games
Contact
Downloads
FAQs
Forums
Member List
Member Projects
News
News Grabber *
Policy
Polls
Private Messages
Reviews
Screenshot Gallery
Search
Servers - Game
Store - Shirts *
Subscribe
Topics
Tutorials
Weblinks
Wiki *
Tutorials
CoD Mapping
CoDUO Mapping
CoD2 Mapping
CoD4 Mapping
CoDWW Mapping
CoD FAQs
HL2 Mapping
HL2 FAQs
SOF1 Mapping
Crysis Mapping
Q4 Mapping
Doom 3 Mapping
Doom 3 FAQs
UT2K3 Mapping
SOF2 Mapping
SOF2 FAQs

Lightray Modeling
General Modeling
General Modding
Adobe Photoshop
Common Mapping Errors

Readme.txt Generator
Members-Online
INSANE{H|S} [Forum]
liltc64 [Forum]
reborn1213 [Forum]
taske [Downl]

4 Members and 8 Guests
Chat MODSonline
0 People Now Chatting
MODSOnline TeamSpeak

download TeamSpeak

In-The-News
Sunday, Jan. 4th
MODSonair 161 Live
Friday, Jan. 2nd
MODSonair Episode 160
Thursday, Jan. 1st
HAPPY NEW YEAR MODSONLINE AND ALL
Sunday, Dec. 28th
MODSonair 160 Live
Saturday, Dec. 27th
MODSonline Holiday Pwnage
Latest Poll
Modsonair audio or video?
Video from here on. 48.57%
Sticking with audio. 2.86%
Either is good. 17.14%
What is modsonair? 31.43%
Read More...
4 comments

Newsletter
Name:
Email:
Newsletter Archives
Your Membership
User Name:
Password:
Register.
In The Forums
vision script
CoD2 Scripting.. Posts: (14) Views: (64) by liltc64
Start at level 15
CoD:WW Zombie/Co.. Posts: (6) Views: (102) by Sgt.Rampage
pk3 making?
CoDUO Level Desi.. Posts: (1) Views: (9) by ghostryder07
found em
CoD:WW Zombie/Co.. Posts: (1) Views: (14) by cme4pain
Google 468 Banner Quake 4 Mods for Dummies
CoDWW Download
Forums
MODSonline.com Forums

Welcome to the MODSonline.com forums. Looking for Frequently Asked Questions? Check out our FAQs section or search it out using the SEARCH link below. If you are new here, you may want to check out our rules and this great user's guide to the forums and the website.
For more mapping and modding information, see our Wiki: MODSonWiki.com

Jump To:
Forum: All Forums : Call of Duty 4
Category: CoD 4 Level Design
CoD 4 mapping and level design.
Moderators: foyleman, rEdrUmMDK, Foxhound, Rasta, StrYdeR, The_Caretaker, supersword, batistablr, playername, Welshy
Latest Posts
Subscribed Posts
Search
Restricted Access Restricted Access
Page
Previous Page Next Page
subscribe
Author Topic: Rain or Snow
keker
General Member
Since: Jan 19, 2008
Posts: 19
Last: Mar 18, 2008
[view latest posts]
Level 1
Category: CoD 4 Level Design
Posted: Thursday, Feb. 7, 2008 03:52 pm
I have created the following .gsc file..


main()
{
maps\mp\_load::main();

//setExpFog(300, 1400, 0.5, 0.5, 0.5, 0);
ambientPlay("ambient_farm");
VisionSetNaked( "mp_farm", 0 );

game["allies"] = "sas";
game["axis"] = "russian";
game["attackers"] = "allies";
game["defenders"] = "axis";
game["allies_soldiertype"] = "woodland";
game["axis_soldiertype"] = "woodland";

setdvar( "r_specularcolorscale", "5" );

level._effect[ "wood" ] = loadfx( "explosions/grenadeExp_wood" );
level._effect[ "dust" ] = loadfx( "explosions/grenadeExp_dirt_1" );
level._effect[ "brick" ] = loadfx( "explosions/grenadeExp_concrete_1" );
level._effect[ "coolaidmanbrick" ] = loadfx( "explosions/grenadeExp_concrete_1" );
level._effect[ "rain_heavy_mist" ] = loadfx( "weather/rain_mp_farm" );
level._effect[ "lightning" ] = loadfx( "weather/lightning_mp_farm" );
level._effect[ "cgoshp_drips_a" ] = loadfx( "misc/cgoshp_drips_a" );

//ambient runners
level._effect[ "rain_splash_mp_farm" ] = loadfx( "ambient_runners/mp_farm_rain_splash01" );
level._effect[ "water_noise_ud" ] = loadfx( "ambient_runners/mp_farm_water_noise_ud01" );
level._effect[ "water_noise" ] = loadfx( "ambient_runners/mp_farm_water_noise01" );


/#
if ( getdvar( "clientSideEffects" ) != "1" )
maps\createfx\mp_kek_fx::main();
#/

level.tweakfile = true;


//* Fog section *

setdvar( "scr_fog_disable", "0" );

setExpFog(300, 1400, 0.5, 0.5, 0.5, 0);
VisionSetNaked( "mp_kek", 0 );

}

I basically tried every other way suggested in the forums but none worked as different files.... i.e. _fx _art etc compile & syntax errors. I tried every combination ended up putting all the weather commands into the mp_kek.gsc file & everything started working at once. Except visible rain!!!
I have set my worldspawn & sky map settings to match mp_farm (downpour)
The strange thing is that i get fog & the sounds, as though it is raining, & the sky is the same as mp_farm but, no visible drops of rain...... is this added through radiant...... if it is radient please describe how to add & link the Patches? Models? or whatever it is it uses.
pa1n
General Member
Since: Feb 5, 2008
Posts: 23
Last: Sep 18, 2008
[view latest posts]
Level 1
Category: CoD 4 Level Design
Posted: Thursday, Feb. 7, 2008 04:17 pm
Thanks for the help.

It just gives me an error about the compile.

something about unexpected end of file found }

something i dont get is i cant find the gsc file for MP Downpour map which has exactly what i want.....
pa1n
General Member
Since: Feb 5, 2008
Posts: 23
Last: Sep 18, 2008
[view latest posts]
Level 1
Category: CoD 4 Level Design
Posted: Thursday, Feb. 7, 2008 04:29 pm
doh just re-read last post

so the map downpour is actualy farm

Im going to have to have a read of its gsc file tonight


nice info dude
keker
General Member
Since: Jan 19, 2008
Posts: 19
Last: Mar 18, 2008
[view latest posts]
Level 1
Category: CoD 4 Level Design
Posted: Thursday, Feb. 7, 2008 04:37 pm
Make sure you re build fast file after everytime u change .gsc file.
Sevenz
General Member
Since: Apr 24, 2006
Posts: 1179
Last: Jan 8, 2009
[view latest posts]
Level 8
Category: CoD 4 Level Design
Posted: Thursday, Feb. 7, 2008 04:52 pm
as i already said, we miss something and that's why we don't see visible rain. i guess we have to do something in radiant, eg. adding a global rain effect to worldspawn (rain_heavy_mist) or something like this...

currently we just load the effect

Code:
 level._effect[ "rain_heavy_mist" ] = loadfx( "weather/rain_mp_farm" );

but we actually don't use it [ohwell]
pa1n
General Member
Since: Feb 5, 2008
Posts: 23
Last: Sep 18, 2008
[view latest posts]
Level 1
Category: CoD 4 Level Design
Posted: Thursday, Feb. 7, 2008 05:47 pm
I read your post twice and it makes sence .

The script loads all the bits it need But it does not seam to use them...
Sevenz
General Member
Since: Apr 24, 2006
Posts: 1179
Last: Jan 8, 2009
[view latest posts]
Level 8
Category: CoD 4 Level Design
Posted: Thursday, Feb. 7, 2008 06:52 pm
this if from fastfile mp_farm.ff: maps/createfx/mp_farm_fx.gsc

Code:
//_createfx generated. Do not touch!!

main()
{
	// CreateFX entities placed: 114

	ent = maps\mp\_utility::createOneshotEffect( "rain_heavy_mist" );
	ent.v[ "origin" ] = ( 27.2079, -1156.02, 583.278 );
	ent.v[ "angles" ] = ( 270, 0, 0 );
	ent.v[ "fxid" ] = "rain_heavy_mist";
	ent.v[ "delay" ] = -15;

	ent = maps\mp\_utility::createOneshotEffect( "rain_heavy_mist" );
	ent.v[ "origin" ] = ( 305.878, 1079.03, 716.141 );
	ent.v[ "angles" ] = ( 270, 0, 0 );
	ent.v[ "fxid" ] = "rain_heavy_mist";
	ent.v[ "delay" ] = -15;

[...]
}

i guess you can plant effects in-game, but i don't have a clue how.


some code snippets:


raw\maps\mp\_utility.gsc:

Code:
createOneshotEffect( fxid )
{
	ent = maps\mp\_createfx::createEffect( "oneshotfx", fxid );
	ent.v[ "delay" ] = -15;
	return ent;
}



raw\maps\mp\_fx.gsc:

Code:
	OneShotfx: Fires an effect once.
	maps\mp\_fx::OneShotfx( effectname, (x y z), predelay);

	Example:
	maps\mp\_fx::OneShotfx(level.medFire,		// Medium fire effect
					(-701, -18361, 148),	// Origin
					5);						// Wait 5 seconds before doing effect



raw\maps\mp\_createfx.gsc:

Code:
createfx()
{
	precacheShader("black");	

	flag_init( "createfx_saving" );
	// Effects placing tool
	if ( !isdefined( level.createFX ) )
		level.createFX = [];
	
	triggers = getentarray( "trigger_multiple", "classname" );
	for (i=0;i



raw\maps\mp\_createfxMenu.gsc:

Code:
create_fx_menu()
{
	if ( button_is_clicked( "escape", "x" ) )
	{
		exit_menu();
		return;
	}

	if (menu("creation"))
	{
		if (button_is_clicked("1"))
		{
			setmenu("create_oneshot");
			draw_effects_list();		
			return;
		}
Sevenz
General Member
Since: Apr 24, 2006
Posts: 1179
Last: Jan 8, 2009
[view latest posts]
Level 8
Category: CoD 4 Level Design
Posted: Thursday, Feb. 7, 2008 07:09 pm
same question here: Adding effects to map
-HeadHUNTER-
General Member
Since: Jan 3, 2006
Posts: 8
Last: Feb 26, 2008
[view latest posts]
Level 0
Category: CoD 4 Level Design
Posted: Friday, Feb. 8, 2008 09:30 am
i already played on a few custom maps where it was raining...but i cant get the rain to work on my map :(

i spend the last few days with searching the modsonline forum,german and english wiki and other cod sides ! tried the cod 2 the tutorial for rain like caretaker said

i tried both ways the one with test2_fx.gsc and the .gsc but
that doesnt work ...it always gave me an } bad syntax error and if i changed the brackets i get other errors :(

and i tried other codes which i found in the forums
but the best i could get was the rain sound,fire and smoke to work!but thats all

i also used parts of the the mp_farm.gsc and mp_cargoship.gsc
but doesnt work either cause the effect isnt defined there:(

on the wiki side it says :

Quote:
The maps that shipped with the game have a separate map_art.gsc file where these effects were defined. User-made maps won't have this file, so the effects should be defined within the map_fx.gsc file.


i checked all iwi.files in the main and all other cod4 folders but i cant find the cargoship/farm_art.gsc to check how i have to define...

But how do i define that?? i guess somehow like in the cod2 tutorial but how? or is it an worldspawnsetting?

it would be nice if someone could explain how we get rain to work on cod4 ;)


plz dont post links to the tuts or to other forum threads...i have already read them all!!!


and if that is that easy like a lot of guys say in the forum...then it couldnt be too hard to write a simple cod4 rain tut for the mapping community ;)

regards

and sry for the bad english :P

-edit-
as u see on my register date...this is my first question! im mapping since cod 1 and i always helped me out by myself with using the tuts and reading the forum but this time i am really stuck !

edited on Feb. 8, 2008 09:34 am by SST_Co2_HeadHUNTER
Sevenz
General Member
Since: Apr 24, 2006
Posts: 1179
Last: Jan 8, 2009
[view latest posts]
Level 8
Category: CoD 4 Level Design
Posted: Friday, Feb. 8, 2008 12:33 pm
ginj:

Quote:
actually in the stock maps, the effect locations are made in the art file
but we dont have art files with radiant as custom map builder.
so u got to add them in the _fx.gsc file, like the way u did. dunno if theere are any errors in ur script, but thats the way to go

you can extract the stock map art files from map fastfiles. if you want to know how to, let me know. as far as we don't know how IW did the art stuff, we have to do it like for cod2 (all fx placed manually or via script, eg. mp_mapname_fx.gsc)

if you still get errors after removing bracket errors may mean, that you had errors before, but the bracket errors were caught before the syntax errors etc. so try to fix all of them.
Restricted Access Restricted Access
Page
Previous Page Next Page
subscribe
MODSonline.com Forums : Call of Duty 4 : CoD 4 Level Design
All logos and trademarks and information in this site are property of MODSonline LLC © 2009.
The comments are property of their posters.
RSS news feeds for MODSonline can be found News.php.
Art of War Central
Partners
CODAddicts - Call of Duty News & Downloads
Frag Universe
Battle for Europe COD2
Call of Duty Headquarters
The Firing Box
modbase.be
XoXide
Ask About
Advertising
Friends
After Life Gaming
Canada Kicks Ass Clan
Great Gamer
Ask About
Advertising
Link to Us
MODSonair
View in iTunes
Please help us to raise in the ranks of podcasting and subscribe to our itunes feed using the link above.
MODSonair Releases
MODSonair Episode 160
MODSonair Episode 159
MODSonair Episode 158
MODSonair Episode 157
MODSonair Episode 156
Next Show
The next MODSonair show will air LIVE on:
01/11/2009 12:00 EST

Time remaining:
Copyright © 2009 MODSonline
Tresware Content Management System Copyright © 2009 Tresware
Website Designed and Hosted   Tresware