Page 1 of 1

Trying to "test" a map but failing les miserables

Posted: July 17th, 2006, 3:18 am
by red_gee
I'm trying to figure out how to run a map in mp so that I can test through some prefabs I'm trying to make
I found that I can run the map in SP but then everything is black or white
And in MP I get an error about _callbacksetup.gsc line 10 if I do not use a GSC file named after my map
And if I do use a GSC file named after my map I get this error

Code: Select all

started from:
(file 'maps/mp/mp_test1.gsc', line 1)
main()
*
************************************
writing to: C:\Games\Activision\Call of Duty 2\servercache.dat
Error during initialization:
script runtime error
(see console for details)
script stack overflow (too many embedded function calls)
So my gsc reads

Code: Select all

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

setExpFog(0.0001, 0.55, 0.6, 0.55, 0);
// setCullFog(0, 16500, 0.55, 0.6, 0.55, 0);
ambientPlay("ambient_france");

game["allies"] = "american";
game["axis"] = "german";
game["attackers"] = "allies";
game["defenders"] = "axis";
game["american_soldiertype"] = "normandy";
game["german_soldiertype"] = "normandy";

setCvar("r_glowbloomintensity0", ".25");
setCvar("r_glowbloomintensity1", ".25");
setcvar("r_glowskybleedintensity0",".3");

}
I think I got that code from modsonline

So what am I doing wrong? SP loads with white skybox and everything else black (cannot even see gun)
and Mp won't quite load up

I decided I would try to randomly comment out lines and I ran the GSC like this too

Code: Select all

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

//setExpFog(0.0001, 0.55, 0.6, 0.55, 0);
// setCullFog(0, 16500, 0.55, 0.6, 0.55, 0);
//ambientPlay("ambient_france");

game["allies"] = "american";
game["axis"] = "german";
game["attackers"] = "allies";
game["defenders"] = "axis";
game["american_soldiertype"] = "normandy";
game["german_soldiertype"] = "normandy";

//setCvar("r_glowbloomintensity0", ".25");
//setCvar("r_glowbloomintensity1", ".25");
//setcvar("r_glowskybleedintensity0",".3");

}
To no avail

Posted: July 17th, 2006, 4:33 pm
by Marshall
First off, is the code below is name "mp_test1.gsc" (the file name), then delete the line : "maps\mp\mp_test1::main(); "

Code: Select all

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

setExpFog(0.0001, 0.55, 0.6, 0.55, 0); 
// setCullFog(0, 16500, 0.55, 0.6, 0.55, 0); 
ambientPlay("ambient_france"); 

game["allies"] = "american"; 
game["axis"] = "german"; 
game["attackers"] = "allies"; 
game["defenders"] = "axis"; 
game["american_soldiertype"] = "normandy"; 
game["german_soldiertype"] = "normandy"; 

setCvar("r_glowbloomintensity0", ".25"); 
setCvar("r_glowbloomintensity1", ".25"); 
setcvar("r_glowskybleedintensity0",".3"); 

} 
else that you will be calling a never ending command...

In other words u will be executing the file that code, which will execute that code which will execute that code ect..

lol.. anyway yes delete that if im correct..

If not then Wat is in the "mp_test1.gsc", we nned to know that...




so ure code will be :

Code: Select all

main() 
{ 

maps\mp\_load::main(); 

setExpFog(0.0001, 0.55, 0.6, 0.55, 0); 
// setCullFog(0, 16500, 0.55, 0.6, 0.55, 0); 
ambientPlay("ambient_france"); 

game["allies"] = "american"; 
game["axis"] = "german"; 
game["attackers"] = "allies"; 
game["defenders"] = "axis"; 
game["american_soldiertype"] = "normandy"; 
game["german_soldiertype"] = "normandy"; 

setCvar("r_glowbloomintensity0", ".25"); 
setCvar("r_glowbloomintensity1", ".25"); 
setcvar("r_glowskybleedintensity0",".3"); 

} 

Hope that helped, post soon



Marshall[/quote]

Posted: July 17th, 2006, 5:39 pm
by Drofder2004
What happeed to my post :S

What are your worldspawn settings?

Anf yes, as Marshall said, you do not need the first line (unless you have a reason for having it there, and in that case, post up whats in that gsc).

Posted: July 18th, 2006, 3:33 am
by red_gee
Okay that works, duh on my part, I know very little about coding
But I prolly could have caught that this is the link where I got the code from
http://www.modsonline.com/Tutorials-read-324.html

Code: Select all

main()
{
maps\mp\your_map_name_fx::main();//This line means what then? I guess I shouldn't have deleted that _fx
maps\mp\_load::main();

setExpFog(0.0001, 0.55, 0.6, 0.55, 0);
// setCullFog(0, 16500, 0.55, 0.6, 0.55, 0);
ambientPlay("ambient_france");

game["allies"] = "american";
game["axis"] = "german";
game["attackers"] = "allies";
game["defenders"] = "axis";
game["american_soldiertype"] = "normandy";
game["german_soldiertype"] = "normandy";

setCvar("r_glowbloomintensity0", ".25");
setCvar("r_glowbloomintensity1", ".25");
setcvar("r_glowskybleedintensity0",".3");

}
So what does the FX mean?
I just kinda snipped that part because there is no explanation of what any of the code means

World spawn

Image

But I think I have to use different settings because it is way too bright and redish

Screeny

Image


You'll have to excuse me I've been very tired latly, and not being able to test a map has been getting on my nerves quite a bit
And then I scrapped my prefab because I learned about detail brushes
But I think this puts me back on track
Thank you very much guys
Any feedback on the worldspawn settings would be appreciated, if any is required

Posted: July 18th, 2006, 5:03 am
by Drofder2004
Basically what this does...

Code: Select all

maps\mp\your_map_name_fx::main();
Broken Down.

Code: Select all

maps\mp\ = Folder to look in
your_map_name_fx = GSC filename
:: = Tells to look inside file for a function
main() = the function to look for
So it goes into the folder, looks for the file with the required name, then it opens that file up and finds the function called main() - Understand?

Typically "your_map_name_fx" is the name of the file you would usually use for all your map effects.

Ok, worldspawn. Delete all of your worldspawn settings, we're gonna start again :)...

Here is a list of OFFICIAL settings used in the stock maps. Choose a map thats is similar to your own, and steal the settings from that.

http://www.modsonline.com/Tutorials-read-296.html

Hope that helps :)

Posted: July 18th, 2006, 5:11 pm
by Marshall
well put drofdey..


Basically dont add

"maps\mp\your_map_name_fx::main();"

unless u have a a gsc called "your_map_name_fx.gsc"

or rather in ure case "mp_test1.gsc"...


Also delete ure skybox and start that again too, i have a feeling u have a leak..

Posted: July 18th, 2006, 9:40 pm
by red_gee
Well my world spawn settings are the mp_carentan from that list
And this map in particular was just me trying t o figure out how to actually get a map running
So that I could drop my prefab in it and test it out
So the entire map will probably be deleted several times, and I will most definately be using different world spawn settings from that list though
I really like Caen, so I'll prolly go with that

And as for the fx gsc file, would that just be things like smoke and fire effects or would it be ambient background noises like gun fire in the distance?

Was the basic setup of my worldspawn right though?
I try to enter them in the order specified in that tut and they just seem to go where they want to
Do I need the curly brackets at top and bottom and the quotes
I presume not

Thanks again guys

*Finds problem from my worldspawn to the right worldspawn
Have to see what happens when I change that "s_coloruncolor"
Need to sleep more and work less*