Login x
User Name:
Password:
Social Links Facebook Twitter YouTube Steam RSS News Feeds

Members Online

»
0 Active | 62 Guests
Online:

LATEST FORUM THREADS

»
CoD: Battle Royale
CoD+UO Map + Mod Releases
Damaged .pk3's
CoD Mapping
heli to attack ai
CoD4 SP Mapping

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: CoD4 MP Mapping
CoD 4 mapping and level design for multiplayer.
Moderators: foyleman, Foxhound, Mystic, StrYdeR, batistablr, Welshy, DrBiggzz, supersword, playername, novemberdobby
Latest Posts
Subscribed Posts
Search
Restricted Access Topic is Locked subscribe
Author Topic: I have problem FX's
czopson90
General Member
Since: Oct 27, 2013
Posts: 5
Last: Mar 10, 2014
[view latest posts]
Level 0
Category: CoD4 MP Mapping
Posted: Saturday, Mar. 8, 2014 10:42 am
Hi !

I turn to you asking you to write the script. I would like to add an effect to my map. effect name is "window_fire_large". I create script_origin.

classname script_origin
origin -2280 309 634.3
targetname smoke_here


Please write the script for this effect "window_fire_large".


My file .gsc looks like

main()
{

maps\mp\_load::main();
maps\mp\_compass::setupMiniMap("compass_map_mp_wmp");
ambientPlay("ambient_overgrown_day");
game["allies"] = "marines";
game["axis"] = "russian";
game["attackers"] = "axis";
game["defenders"] = "allies";
game["allies_soldiertype"] = "woodland";
game["axis_soldiertype"] = "woodland";

setdvar( "r_specularcolorscale", "1" );

setdvar("r_glowbloomintensity0",".25");
setdvar("r_glowbloomintensity1",".25");
setdvar("r_glowskybleedintensity0",".3");
setdvar("compassmaxrange","1800");
VisionSetNaked( "mp_overgrown" );

maps\mp\_explosive_barrels::main();

THX :) [wave]
Share |
TrikX
General Member
Since: Jul 7, 2012
Posts: 129
Last: Dec 31, 2016
[view latest posts]
Level 4
Category: CoD4 MP Mapping
Posted: Sunday, Mar. 9, 2014 05:06 pm
there are more ways to play the fx! but i suppose you want a looping fx on trigger, so this is one of the easy ways to do it!

Code:
main()
{
	level._effect["window_fire_large"] = loadfx( "fire/window_fire_large" );

	maps\mp\_load::main();
	maps\mp\_compass::setupMiniMap("compass_map_mp_wmp");
	ambientPlay("ambient_overgrown_day");
	game["allies"] = "marines";
	game["axis"] = "russian";
	game["attackers"] = "axis";
	game["defenders"] = "allies";
	game["allies_soldiertype"] = "woodland";
	game["axis_soldiertype"] = "woodland";

	setdvar( "r_specularcolorscale", "1" );

	setdvar("r_glowbloomintensity0",".25");
	setdvar("r_glowbloomintensity1",".25");
	setdvar("r_glowskybleedintensity0",".3");
	setdvar("compassmaxrange","1800");
	VisionSetNaked( "mp_overgrown" );

	maps\mp\_explosive_barrels::main();
}


to activate it, do this!
Place a trigger at a point you want it to be activated, and give it key (targetname) and value (activate_fx)

Add this code to gsc and don't forget the thread activ_fx();

Code:
activ_fx()
{
acti_fx = getent("activate_fx","targetname");

	{
	acti_fx waittill ("trigger");

	playfx(level._effect["window_fire_large"],(-2280, 309, 634.3));
	wait 1;
	}
}


add this to your zone file (fx,fire/window_fire_large)

Thats it! [thumbs_up]

edited on Mar. 9, 2014 10:23 am by TrikX
Share |
TrikX
General Member
Since: Jul 7, 2012
Posts: 129
Last: Dec 31, 2016
[view latest posts]
Level 4
Category: CoD4 MP Mapping
Posted: Sunday, Mar. 9, 2014 05:43 pm
But maybe you want it to start when the map starts, and you don't want to place any triggers, so this is a way to do it!
Where i wrote (yourmapname) you need to write the name of your map!

make a new .gsc in raw/maps/mp and call it mp_yourmapname_fx.gsc and place this in it!

Code:
main()
{
	level._effect[ "window_fire_large" ]		 = loadfx( "fire/window_fire_large" );

/#

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

}


Now make a new .gsc in maps\createfx
(If you don't have "createfx" folder, create it)
Give the name mp_yourmapname_fx to that .gsc
In that .gsc put this:

Code:
//_createfx generated. Do not touch!!
main()
{
     	ent = maps\mp\_utility::createOneshotEffect( "window_fire_large" );
     	ent.v[ "origin" ] = ( -2280, 309, 634.3 );
     	ent.v[ "angles" ] = ( 270, 0, 0 );
     	ent.v[ "fxid" ] = "window_fire_large";
     	ent.v[ "delay" ] = -1;
	ent.v[ "soundalias" ] = ""; //if you want sound, place alias here
}


The main of your .gsc has to have this:

Code:
	maps\mp\mp_yourmapname_fx::main();
	maps\createfx\mp_yourmapname_fx::main();


This goes to zone file:

rawfile,maps/mp/mp_yourmapname_fx.gsc
rawfile,maps/createfx/mp_yourmapname_fx.gsc
fx,fire/window_fire_large

Compile and you are done!
Share |
czopson90
General Member
Since: Oct 27, 2013
Posts: 5
Last: Mar 10, 2014
[view latest posts]
Level 0
Category: CoD4 MP Mapping
Posted: Sunday, Mar. 9, 2014 06:43 pm
THX!!!!!! YOU ARE MY HERO !!!!!!!! :)
Share |
czopson90
General Member
Since: Oct 27, 2013
Posts: 5
Last: Mar 10, 2014
[view latest posts]
Level 0
Category: CoD4 MP Mapping
Posted: Monday, Mar. 10, 2014 07:38 pm
Hi.
Do you send me tutorial about how destroy glass? and use machine guns on multiplayer maps ?

edited on Mar. 10, 2014 12:39 pm by czopson90
Share |
TrikX
General Member
Since: Jul 7, 2012
Posts: 129
Last: Dec 31, 2016
[view latest posts]
Level 4
Category: CoD4 MP Mapping
Posted: Monday, Mar. 10, 2014 08:06 pm
Breakable Window

Setting turret in MP is easy, and this is how it's done!

Right Clicking on 2D view -> Misc -> Turret
Press N to open Entity
(Make sure you have your Turret selected when you press the 'N' key)

Now enter all of these values to it!

Code:
Key: bottomarc
Value: 30

Key: export
Value: 2

Key: model
Value: xmodel/weapon_saw_MG_setup

Key: spawnflags
Value: 1

Key: weaponinfo
Value: saw_bipod_crouch_mp


This goes to the Zone File:
Code:
xmodel,weapon_saw_mg_setup


Thats it! [thumbs_up]
Share |
TrikX
General Member
Since: Jul 7, 2012
Posts: 129
Last: Dec 31, 2016
[view latest posts]
Level 4
Category: CoD4 MP Mapping
Posted: Monday, Mar. 10, 2014 08:19 pm
For the window, you can also use this:
Breakable Brushes
Share |
TrikX
General Member
Since: Jul 7, 2012
Posts: 129
Last: Dec 31, 2016
[view latest posts]
Level 4
Category: CoD4 MP Mapping
Posted: Thursday, Apr. 10, 2014 12:38 pm
Oh, now i just looked at the first script i gave you, and i see i made a small mistake!

On the part where the trigger is used to activate the fx, after it's activated you need to delete the trigger so it doesn't continue spawning new fx on the same spot!
So it should be like this:

Code:
activ_fx()
{
acti_fx = getent("activate_fx","targetname");

	{
	acti_fx waittill ("trigger");

	playfx(level._effect["window_fire_large"],(-2280, 309, 634.3));
	wait 0.1;
        acti_fx delete();
	}
}
Share |
Restricted Access Topic is Locked subscribe
MODSonline.com Forums : Call of Duty 4 : CoD4 MP Mapping

Latest Syndicated News

»
Codutility.com up and runn...
Nice, and there still using the logo and template for the screenshots, which...
Codutility.com up and runn...
dundy writes...Quote:Call of Duty modding and mapping is barly alive only a ...
Codutility.com up and runn...
Mystic writes...Quote:It seems to me the like the site is completely dead? ...
Codutility.com up and runn...
It seems to me the like the site is completely dead?

Partners & Friends

»