Speed walls/floors...

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

Moderator: Core Staff

Post Reply
User avatar
Chucky.
CJ Fan
CJ Fan
Posts: 172
Joined: June 12th, 2012, 4:27 am
Location: UK
Contact:

Speed walls/floors...

Post by Chucky. » June 24th, 2012, 2:34 pm

Hey all, I just would like too know how do I make a wall in a semi circle? Erm, like ib_liam, the green wall you have too speed run around after the 3rd or 4th bounce. Also, speed floors like on to_the_moon intermediate & advanced, where you have too run up the floor to land on moon? I'm quite new too mapping as you can probably see, lol. I watched a YouTube tutorial on how too make a bendy/shaped wall, but everytime I click anything on the patch tab, it turns out completly different to when the dude in the tutorial does it. The click something like patch, bevel after lining the wall up and it turns out perfectly where they only need to rotate/move into posision but when I do it, the wall either turns out the wrong way around or too thin. Thanks all!

fishy
CJ Wannabe
CJ Wannabe
Posts: 30
Joined: June 24th, 2012, 2:51 pm

Re: Speed walls/floors...

Post by fishy » June 24th, 2012, 3:03 pm

With the patch selected just hit Ctrl-I and that will invert the direction the texture faces. Also you can use the thicken tool if it's to thin.

User avatar
Chucky.
CJ Fan
CJ Fan
Posts: 172
Joined: June 12th, 2012, 4:27 am
Location: UK
Contact:

Re: Speed walls/floors...

Post by Chucky. » June 24th, 2012, 4:36 pm

fishy wrote:With the patch selected just hit Ctrl-I and that will invert the direction the texture faces. Also you can use the thicken tool if it's to thin.
Hey, how do I use the thinning tool? 0_o

User avatar
Chucky.
CJ Fan
CJ Fan
Posts: 172
Joined: June 12th, 2012, 4:27 am
Location: UK
Contact:

Re: Speed walls/floors...

Post by Chucky. » June 24th, 2012, 5:50 pm

I figured out making curved walls, thank you. Can anyone help with making a speed floor please?

Vartazian
CJ Worshipper
CJ Worshipper
Posts: 286
Joined: June 10th, 2011, 9:14 pm

Re: Speed walls/floors...

Post by Vartazian » June 24th, 2012, 6:52 pm

here is the script i used for mp_to_the_moon. You need to add the thread first in your
gsc file. somethign like this:

Code: Select all

main()
{

	maps\mp\_load::main();

	game["allies"] = "marines";
	game["axis"] = "opfor";
	game["attackers"] = "axis";
	game["defenders"] = "allies";
	game["allies_soldiertype"] = "desert";
	game["axis_soldiertype"] = "desert";
	
	setdvar( "r_specularcolorscale", "1" );

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

thread speed();

}

speed()
 
{ 
trigger = getent("svt_accelerate_1","targetname");  
while(1)
{
trigger waittill ("trigger",player);
i=12;
while(i > 8 && player isOnGround())
{
   player SetMoveSpeedScale(i);
   wait(.05);
}
player SetMoveSpeedScale(1);
wait(2);
}
}

So to use this, make a box around a platform. right click on 2d grid > trigger> multiple.
then highlight it, and hit N. enter KEY: targetname VALUE:svt_accelerate_1

User avatar
Goro92
CJ Spammer!
CJ Spammer!
Posts: 605
Joined: March 7th, 2011, 5:54 pm
Location: Brescia, Italy

Re: Speed walls/floors...

Post by Goro92 » June 24th, 2012, 7:01 pm

pjchucky wrote:I figured out making curved walls, thank you. Can anyone help with making a speed floor please?
the "speed floor" is a script

first learn something easier like a text

The first step is to create a game script file with your level's name in the filename. It goes in the following game directory:

\raw\maps\mp\mp_yourmap.gsc

Then paste this code in

Code: Select all

main()
{
    maps\mp\_load::main();
    
  
    
                game["allies"] = "marines";
               game["axis"] = "opfor";
               game["attackers"] = "axis";
               game["defenders"] = "allies";
               game["allies_soldiertype"] = "desert";
               game["axis_soldiertype"] = "desert";

    
    setdvar( "r_specularcolorscale", "1" );
    
    setdvar("r_glowbloomintensity0",".25");
    setdvar("r_glowbloomintensity1",".25");
    setdvar("r_glowskybleedintensity0",".3");
    setdvar("compassmaxrange","1800");
    


}

-TEXT MESSAGE

In radiant:
create a multiple trigger --> press N --> key: targetname, value: text1

Scripting:
Open your mp_yourmap.gsc

and add this code:

Code: Select all


main()
{

   thread text();
}

text()
{
   trigger = getent("text1","targetname");

   while (1)
   {
      trigger waittill ("trigger", user);
      
         user iprintlnbold ("Goro is AMAZING!");   
        
   }
}


The final code should be this

Code: Select all

main()
{

    maps\mp\_load::main();
    
    ambientPlay("ambient_backlot_ext");
    
                game["allies"] = "marines";
               game["axis"] = "opfor";
               game["attackers"] = "axis";
               game["defenders"] = "allies";
               game["allies_soldiertype"] = "desert";
               game["axis_soldiertype"] = "desert";

    
    setdvar( "r_specularcolorscale", "1" );
    
    setdvar("r_glowbloomintensity0",".25");
    setdvar("r_glowbloomintensity1",".25");
    setdvar("r_glowskybleedintensity0",".3");
    setdvar("compassmaxrange","1800");
   thread text();
}

text()
{
   trigger = getent("text1","targetname");

   while (1)
   {
      trigger waittill ("trigger", user);
      
         user iprintlnbold ("Goro is AMAZING!");   
        
   }
}

the last step is to add this line

Code: Select all

rawfile,maps/mp/mp_yourmap.gsc
in the upload zone file
Image

User avatar
Chucky.
CJ Fan
CJ Fan
Posts: 172
Joined: June 12th, 2012, 4:27 am
Location: UK
Contact:

Re: Speed walls/floors...

Post by Chucky. » June 24th, 2012, 8:20 pm

Vartazian wrote:here is the script i used for mp_to_the_moon. You need to add the thread first in your
gsc file. somethign like this:

Code: Select all

main()
{

	maps\mp\_load::main();

	game["allies"] = "marines";
	game["axis"] = "opfor";
	game["attackers"] = "axis";
	game["defenders"] = "allies";
	game["allies_soldiertype"] = "desert";
	game["axis_soldiertype"] = "desert";
	
	setdvar( "r_specularcolorscale", "1" );

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

thread speed();

}

speed()
 
{ 
trigger = getent("svt_accelerate_1","targetname");  
while(1)
{
trigger waittill ("trigger",player);
i=12;
while(i > 8 && player isOnGround())
{
   player SetMoveSpeedScale(i);
   wait(.05);
}
player SetMoveSpeedScale(1);
wait(2);
}
}

So to use this, make a box around a platform. right click on 2d grid > trigger> multiple.
then highlight it, and hit N. enter KEY: targetname VALUE:svt_accelerate_1
Hey, thanks but it doesn't work. I put the trig around the platform I wanted too accelerate (trig_multiple), entered the key and value, updated my GSC but it just don't work for some reason. I added you on Xfire, hope you can help. Thanks again =)

EDIT: I fixed it, thank you. xD

User avatar
Drofder2004
Core Staff
Core Staff
Posts: 13313
Joined: April 13th, 2005, 8:22 pm
Location: UK, London

Re: Speed walls/floors...

Post by Drofder2004 » June 25th, 2012, 3:30 am

Code: Select all

speed() 
{ 
   trigger = getent("svt_accelerate_1","targetname");  
   while(1)
   {
      trigger waittill ("trigger",player);
      i=12;
      
      while(i > 8 && player isOnGround())
      {
         player SetMoveSpeedScale(i);
         wait(.05);
      }
 
      player SetMoveSpeedScale(1);
      wait(2);
   }
}
Is the intention of this code to allow the player to continuosly run around at 12 times speed as long as touches the ground?
What if the player touches the trigger and turns around?

I can't help but think this would be improved using a "while - player isTouching(area)" type of code and then setting a fixed area for the player to run in. Also, this code will be paused and only the first player to trigger it will be able to use it. Again, it would surely be best to pass the player to another function when triggered.
Image
Virgin Media 20Mb Broadband:
"Perfect for families going online at the same time, downloading movies, online gaming and more."
Borked internet since: 22-07-2010

Post Reply

Who is online

Users browsing this forum: No registered users and 30 guests