Mg42 error.

Post your scripting questions / solutions here

Moderator: Moderators

Post Reply
computernerd
Lance Corporal
Posts: 14
Joined: Sun Apr 26, 2009 8:09 pm

Mg42 error.

Post by computernerd »

I modified the mohdm1 script so that I could have an mg42 in there, but nothing shows up:
// SOUTHERN FRANCE
// ARCHITECTURE: SENN
// SCRIPTING: POWZER

main:

// set scoreboard messages
setcvar "g_obj_alliedtext1" "Southern France"
setcvar "g_obj_alliedtext2" ""
setcvar "g_obj_alliedtext3" ""
setcvar "g_obj_axistext1" ""
setcvar "g_obj_axistext2" ""
setcvar "g_obj_axistext3" ""

setcvar "g_scoreboardpic" "mohdm1"

// call additional stuff for playing this map round based is needed
if(level.roundbased)
thread roundbasedthread

level waitTill prespawn

//*** Precache Dm Stuff
exec global/DMprecache.scr

level.script = maps/dm/mohdm1.scr
exec global/ambient.scr mohdm1

//exec global/ambient.scr mohdm2

//$world farplane 5000
//$world farplane_color (.333 .333 .329)

level waittill spawn

end

//-----------------------------------------------------------------------------

roundbasedthread:

// Can specify different scoreboard messages for round based games here.

level waitTill prespawn

level waittill spawn

// set the parameters for this round based match
level.dmrespawning = 0 // 1 or 0
level.dmroundlimit = 5 // round time limit in minutes
level.clockside = kills // set to axis, allies, kills, or draw

level waittill roundstart

end

//-----------------------------------------------------------------------------

onlymg42:

local.static = spawn "statweapons/mg42_gun.tik"
local.static.origin = ( 185 473 384 )
local.static.angles = ( 0 0 0)
local.static solid
end
//-----------------------------------------------------------------------------
neillomax
Lieutenant General
Posts: 880
Joined: Thu Jun 23, 2005 6:57 am

Post by neillomax »

try putting it under level wait til spawn.
$oldier Of Ra
Lieutenant Colonel
Posts: 404
Joined: Sun Oct 16, 2005 7:16 pm
Location: Belgium
Contact:

Post by $oldier Of Ra »

Well of course, you didn't activate the thread.
Add:

Code: Select all

thread onlymg42
underneath waittill spawn.
Our official website: http://www.mohaairborne.co.cc
(Still accessible through http://mohaaclantb.tk and http://users.skynet.be/mohaaclantb/)

For all your bot needs!!!!

$oldier Of Ra.
computernerd
Lance Corporal
Posts: 14
Joined: Sun Apr 26, 2009 8:09 pm

Post by computernerd »

Nope still doesn't work :(
$oldier Of Ra
Lieutenant Colonel
Posts: 404
Joined: Sun Oct 16, 2005 7:16 pm
Location: Belgium
Contact:

Post by $oldier Of Ra »

Where did you put the modified script?
Our official website: http://www.mohaairborne.co.cc
(Still accessible through http://mohaaclantb.tk and http://users.skynet.be/mohaaclantb/)

For all your bot needs!!!!

$oldier Of Ra.
computernerd
Lance Corporal
Posts: 14
Joined: Sun Apr 26, 2009 8:09 pm

Post by computernerd »

in the pk3 file the path is as follows: maps/DM/mohdm1.scr
$oldier Of Ra
Lieutenant Colonel
Posts: 404
Joined: Sun Oct 16, 2005 7:16 pm
Location: Belgium
Contact:

Post by $oldier Of Ra »

What's that pk3's filename? It must be higher in the alphabet than "p" if you want it to be loaded instead of the original one.
Our official website: http://www.mohaairborne.co.cc
(Still accessible through http://mohaaclantb.tk and http://users.skynet.be/mohaaclantb/)

For all your bot needs!!!!

$oldier Of Ra.
computernerd
Lance Corporal
Posts: 14
Joined: Sun Apr 26, 2009 8:09 pm

Post by computernerd »

Oh.... ya know what I completely forgot about that.

EDIT: Thanks lots m8 it works great now, thanks for reminding me about the alphabetical order I completely forgot about that. :)
Post Reply