AA to SH script conversion

Post your scripting questions / solutions here

Moderator: Moderators

Post Reply
Daniel Radcliffe
Second Lieutenant
Posts: 168
Joined: Fri May 30, 2003 9:49 am

AA to SH script conversion

Post by Daniel Radcliffe »

I have an AA map almost complete, and i would like to convert it so that it can be a SH map too.

Can someone please show me how to do this, or even do it. As untill i tried to test the map on SH i was unaware there was a difference :oops:
Heres my script:
// billandben
// ARCHITECTURE: billandben
// SCRIPTING: billandben

main:
// set scoreboard messages
setcvar "g_obj_alliedtext1" "We have to protect"
setcvar "g_obj_alliedtext2" "the train and the"
setcvar "g_obj_alliedtext3" "documents"
setcvar "g_obj_axistext1" "Destroy the train"
setcvar "g_obj_axistext2" "and retrieve both"
setcvar "g_obj_axistext3" "ducuments"
setcvar "g_scoreboardpic" "none"

level waittill prespawn

exec global/DMprecache.scr
level.script = maps/obj/train_station.scr
exec global/ambient.scr m5l1b
thread global/exploder.scr::main
level.farplane = 4200
$world farplane level.farplane
$world farplane_color (.336 .336 .45)

level.defusing_team = "allies"
level.planting_team = "axis"
level.targets_to_destroy = 3
level.bomb_damage = 200
level.bomb_explosion_radius = 2048
level.dmrespawning = 0
level.dmroundlimit = 8
level.clockside = allies

level waittill spawn

//level waittill roundstart

thread document_random_setup
$train_bomb thread global/obj_dm.scr::bomb_thinker
$document_trigger thread document_check

thread axis_win_bomb
thread allies_win_timer
end


axis_win_bomb:
while(level.targets_destroyed < level.targets_to_destroy)
waitframe
teamwin axis
end

allies_win_timer:
level waittill allieswin
end

document_check:
while(1) { // forever
self waittill trigger
if(parm.other.dmteam == axis) {
self nottriggerable
self.target hide
level.targets_destroyed ++ // ++ adds 1
break
}
waitframe
}
end


document_random_setup:
local.location = ((randomint 6) + 1)
local.location_entity = $("document_location_" + local.location)
$document.origin = local.location_entity.origin
$document_trigger.origin = local.location_entity.origin
end
Thx in advance for helping
Daniel Radcliffe
Second Lieutenant
Posts: 168
Joined: Fri May 30, 2003 9:49 am

Post by Daniel Radcliffe »

OK, since there is no reply :cry: either no-one knows :shock: or im going along the wrong path :?

My map shows up in SH under all the game styles other than Obj and ToW, and well i wouldnt expect it to be in ToW. Can someone please tell me what it is i am missing/doing wrong as i would like to have the map as both AA and SH.

Some come on peeps, someone must know what stupid thing it is im missing/doing wrong.

Please help, your faithful GOD, me :twisted: :twisted: :twisted: :twisted:
User avatar
bdbodger
Moderator
Posts: 2596
Joined: Tue Feb 25, 2003 7:34 am
Location: canada
Contact:

Post by bdbodger »

my map didn't show up in obj untill I added obj_ to the front of the map name . obj_mymap.bsp etc ... and of course it is in the maps/obj directory it is a mohaa complied map but I don't think that made any difference . After I added that I could play it in spearhead .
Daniel Radcliffe
Second Lieutenant
Posts: 168
Joined: Fri May 30, 2003 9:49 am

Post by Daniel Radcliffe »

Damn that was to simple :oops:, thx bodger
Post Reply