hey people's
i tried to build something that changes the body of someone but it gives a syntex error - bad script compile -see console for help
this is the code i used i put in in a own map called _body.gsc
then treaded the code bij self thread maps\mp\gametypes\_body::init();
Code:
#include maps\mp\_utility;
init()
{
if(getDvar("mapname") == "mp_afghan"){ /** Afghan **/
level thread Afghan();
}
if(getDvar("mapname") == "mp_boneyard"){ /** Scrapyard **/
level thread Scrapyard();
}
if(getDvar("mapname") == "mp_brecourt"){ /** Wasteland **/
level thread Wasteland();
}
if(getDvar("mapname") == "mp_checkpoint"){ /** Karachi **/
level thread Karachi();
}
if(getDvar("mapname") == "mp_derail"){ /** Derail **/
level thread Derail();
}
if(getDvar("mapname") == "mp_estate"){ /** Estate **/
level thread Estate();
}
if(getDvar("mapname") == "mp_favela"){ /** Favela **/
level thread Favela();
}
if(getDvar("mapname") == "mp_highrise"){ /** HighRise **/
level thread HighRise();
}
if(getDvar("mapname") == "mp_nightshift"){ /** Skidrow **/
level thread Skidrow();
}
if(getDvar("mapname") == "mp_invasion"){ /** Invasion **/
level thread Invasion();
}
if(getDvar("mapname") == "mp_quarry"){ /** Quarry **/
level thread Quarry();
}
if(getDvar("mapname") == "mp_rundown"){ /** Rundown **/
level thread Rundown();
}
if(getDvar("mapname") == "mp_rust"){ /** Rust **/
level thread Rust();
}
if(getDvar("mapname") == "mp_subbase"){ /** SubBase **/
level thread SubBase();
}
if(getDvar("mapname") == "mp_terminal"){ /** Terminal **/
level thread Terminal();
}
if(getDvar("mapname") == "mp_underpass"){ /** Underpass **/
level thread Underpass();
}
afghan()
{
self attach("head_op_arab_sniper.", j_head);
self setmodel("mp_body_riot_tf141_desert");
}
Scrapyard()
{
self attach("head_op_sniper_ghillie_desert", j_head);
self setmodel("mp_body_riot_tf141_desert");
}
Wasteland()
{
self attach("head_op_sniper_ghillie_forest", j_head);
self setmodel("mp_body_riot_tf141_forest");
}
Karachi()
{
self attach("head_allies_sniper_ghillie_urban", j_head);
self setmodel("mp_body_riot_op_arab");
}
Derail()
{
self attach("head_op_sniper_ghillie_arctic", j_head);
self setmodel("mp_body_riot_tf141_arctic");
}
Estate()
{
self attach("head_op_sniper_ghillie_forest", j_head);
self setmodel("mp_body_riot_tf141_forest");
}
Favela()
{
self attach("head_op_sniper_ghillie_urban", j_head);
self setmodel("mp_body_riot_tf141_desert");
}
Highrise()
{
self attach("head_allies_sniper_ghillie_urban", j_head);
self setmodel("mp_body_riot_op_airborne");
}
Skidrow()
{
self attach("head_allies_sniper_ghillie_urban", j_head);
self setmodel("mp_body_riot_op_airborne");
}
Invasion()
{
self attach("head_allies_sniper_ghillie_urban", j_head);
self setmodel("mp_body_riot_op_arab");
}
Quarry()
{
self attach("head_op_sniper_ghillie_desert", j_head);
self setmodel("mp_body_riot_tf141_desert");
}
Rundown()
{
self attach("head_allies_sniper_ghillie_desert", j_head);
self setmodel("mp_body_riot_tf141_desert");
}
Rust()
{
self attach("head_op_sniper_ghillie_desert", j_head);
self setmodel("mp_body_riot_tf141_desert");
}
Subbase()
{
self attach("head_allies_sniper_ghillie_urban", j_head);
self setmodel("mp_body_riot_op_arctic");
}
Terminal()
{
self attach("head_op_sniper_ghillie_urban", j_head);
self setmodel("mp_body_riot_op_airborne");
}
Underpass()
{
self attach("head_op_sniper_ghillie_forest", j_head);
self setmodel("mp_body_riot_tf141_forest");
}
does someone know what i did wrong?