A Community discussion forum for Halo Custom Edition, Halo 2 Vista, Portal and Halo Machinima

Home  Search Register  Login Member ListRecent Posts
  
 
»Forums Index »Halo Custom Edition (Bungie/Gearbox) »Halo CE Technical / Map Design »something's wrong with my vehicle placement......

Author Topic: something's wrong with my vehicle placement...... (5 messages, Page 1 of 1)
Moderators: Dennis

sargejohnson
Joined: Apr 20, 2009

Shall we play a game?


Posted: Jul 29, 2009 06:36 AM    Msg. 1 of 5       
Hi there. Last time, i have been using another computer to do my mapping, so when i decided to switch to a newer comp, i copied my relevant tags over after installing the HEK in the new comp. However, the vehicle scripts that i used for my previous computer could spawn the custom vehicles stated, but my new comp's script's can't properly do so. Here's an example.....

i was modding hangemhigh to have some custom vehicles in it, so this is my script:
Quote:
(global boolean server 0)

(script startup vehicles
(if
(>= (unit_get_health host_check) 0)
(set server 1)
)
(if
(= server 1)
(begin
(object_create "host_check")
(object_create "cturret1")
(object_create "cghost1")
(object_create "cghost2")
(object_create "cshee1")
(object_create "cshee2")
(object_create "turret1")
(object_create "turret2")
(object_create "wasp1")
)
)
)

(script continuous respawn_stuff
(if
(= server 1)
(begin
(if
(volume_test_object "vehicle_spawn" "cturret1")
(object_create_anew "cturret1")
)
(if
(volume_test_object "vehicle_spawn" "cghost1")
(object_create_anew "cghost1")
)
(if
(volume_test_object "vehicle_spawn" "cghost2")
(object_create_anew "cghost2")
)
(if
(volume_test_object "vehicle_spawn" "cshee1")
(object_create_anew "cshee1")
)
(if
(volume_test_object "vehicle_spawn" "cshee2")
(object_create_anew "cshee2")
)
(if
(volume_test_object "vehicle_spawn" "turret1")
(object_create_anew "turret1")
)
(if
(volume_test_object "vehicle_spawn" "turret2")
(object_create_anew "turret2")
)
(if
(volume_test_object "vehicle_spawn" "wasp1")
(object_create_anew "wasp1")
)
)
(sleep_until (= 0 1))
)
)


(ps yes i know the formatting is FUBAR, but i don't know how to fix that....)


FYI the vehicle to object index is as follows:

host_check/cturret1 - cgunturret (the default ingame version)
cghost1/cghost2 - fuel rod ghosts (the extinction version)
cshee1/cshee2 - banshees (the default ingame version)
turret1 - 50 cal turret
turret2 - h_turret (M247 GPMG)
wasp1 - wasp

i put this script in the data/levels/test/hangemhigh/scripts folder
the only vehicles that spawn in the map after compiling are the 2 shees.
can someone help me make the other vehicles appear?
Edited by sargejohnson on Jul 29, 2009 at 06:37 AM


Me KS
Joined: Feb 2, 2008

Desire is Reality. Xfire: jetmaster23


Posted: Jul 29, 2009 01:03 PM    Msg. 2 of 5       
Do you only want those 6 vehicles? Or do you want the default ones in addition to those?

If you want just those 6, then you don't need the script at all. This is because you can replace the 6 vehicles in your globals with those 6 and then let the game spawn them as usual.

A vehicle script is only needed if you want more than 6 types of vehicles in any map, and it's only needed for the ones not in the globals.


FtDSpartn
Joined: May 1, 2009

Verified AI.


Posted: Jul 30, 2009 12:44 AM    Msg. 3 of 5       
BTW To fix the formatting click the # button then put your script\text inbetween the code things like this:
(script startup example  
(begin
-blah blah blah-


Edited by FtDSpartn on Jul 30, 2009 at 01:02 AM


sargejohnson
Joined: Apr 20, 2009

Shall we play a game?


Posted: Jul 31, 2009 08:02 AM    Msg. 4 of 5       
i need more than those 6 vehicles in there (because this list is not final), and i don'tplan to mess with my globals at the moment (just in case something screws up, and i have to reinstall the HEK).


Me KS
Joined: Feb 2, 2008

Desire is Reality. Xfire: jetmaster23


Posted: Jul 31, 2009 11:34 AM    Msg. 5 of 5       
I really doubt anything will go wrong because you replaced vehicles in your globals tag. If you want to be safe, just make a backup copy of your original globals before making any changes.

So, at least for now, put 5 of your 6 vehicles in the globals. Then, when you think of more vehicles to add to the list, put only those extra vehicles in the script, because those 5 are taken care of by the game.

However, you will need to script in one of those 6 at this moment. This is because the 'host_check' vehicle has to spawn by default, which means it must be in the globals. Make sure it stays in the globals.

As for fixing the script: the script isn't the problem. It's probably something wrong with your 'host_check' hog's spawn settings, since you say the vehicles don't spawn to begin with. Make sure 'host_check' is in the globals and that its 'allowed' and 'default' spawn settings are both checked for all game types.

To check to see if the script is determining that you are the server, type 'inspect server' without quotes in the console while hosting a game. If it returns '1', that means the script should be working right.

 

 
Previous Older Thread    Next newer Thread







Time: Sat January 21, 2023 4:26 AM 141 ms.
A Halo Maps Website