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 »scripting help

Page 1 of 2 Go to page: · [1] · 2 · Next
Author Topic: scripting help (41 messages, Page 1 of 2)
Moderators: Dennis

jackotheblah
Joined: Jan 5, 2011

uthink ur lag is bad,takes jesus 3 days to respawn


Posted: Jan 18, 2011 07:30 PM    Msg. 1 of 41       
i am trying to make an sp map and i need a lot of help with the scripting, i have the scripting bible pdf but it doesnt relly help with putting a script together it just has single commands, help will be appreciated.


Muscl3r
Joined: May 22, 2010

dont pray 4 easy lives...pray to be STRONGER MEN


Posted: Jan 18, 2011 07:33 PM    Msg. 2 of 41       
contact me on the pm's


MoooseGuy
Joined: Aug 10, 2008

I Approve This Message.


Posted: Jan 18, 2011 07:41 PM    Msg. 3 of 41       
Perhaps it would be beneficial if more specific information was provided regarding what you are trying to accomplish. There are some good scripters on this site, including myself, that can help you out.


jackotheblah
Joined: Jan 5, 2011

uthink ur lag is bad,takes jesus 3 days to respawn


Posted: Jan 18, 2011 07:55 PM    Msg. 4 of 41       
firstly i would like to learn how to make checkpoints.
then how to make ai spawn and follow commands when the player is within a certain area.
they are my priorities other things can come later.


Muscl3r
Joined: May 22, 2010

dont pray 4 easy lives...pray to be STRONGER MEN


Posted: Jan 18, 2011 08:03 PM    Msg. 5 of 41       
okay i sent u the stuff u asked about including the actual script of how to get it done. I have explained what the commands do aswell


jackotheblah
Joined: Jan 5, 2011

uthink ur lag is bad,takes jesus 3 days to respawn


Posted: Jan 18, 2011 08:36 PM    Msg. 6 of 41       
my script

(script startup script
(sleep_until (volume_test_objects spawn_first_wave (players)) 10)
(game_save_totally_unsafe)
(ai_place floodstart)
(ai_place grunt_start)
)

my error

01.19.11 12:31:59 [script line 4] this is not a valid ai encounter or squad.: flood_start)

01.19.11 12:31:59 recompiling scripts after scenarios were merged.
01.19.11 12:31:59 [script line 1] this left parenthesis is unmatched.: (script startup script

edit:im fairly sure that floodstart is a squad.
Edited by jackotheblah on Jan 18, 2011 at 08:38 PM


Muscl3r
Joined: May 22, 2010

dont pray 4 easy lives...pray to be STRONGER MEN


Posted: Jan 18, 2011 08:37 PM    Msg. 7 of 41       
flood_start isn't a squad or ai encounter in ur scenario. U have to get the spelling the same in the script and in sapien


jackotheblah
Joined: Jan 5, 2011

uthink ur lag is bad,takes jesus 3 days to respawn


Posted: Jan 18, 2011 08:44 PM    Msg. 8 of 41       
i renamed it floodstart in the script and sapien but it gives the same error.

edit: found the problem, the script ai_place won't work with the squads but it works with the encounters so i'll have lots of encounters in my sp game.
Edited by jackotheblah on Jan 18, 2011 at 08:46 PM


Muscl3r
Joined: May 22, 2010

dont pray 4 easy lives...pray to be STRONGER MEN


Posted: Jan 18, 2011 08:58 PM    Msg. 9 of 41       
(ai_place ecnounter1/squad1)

where ecnounter1 is the encounter and squad 1 is the squad


jackotheblah
Joined: Jan 5, 2011

uthink ur lag is bad,takes jesus 3 days to respawn


Posted: Jan 18, 2011 09:15 PM    Msg. 10 of 41       
that fixed it, thnx.
right now im working on the intro cutscene thingy.


Muscl3r
Joined: May 22, 2010

dont pray 4 easy lives...pray to be STRONGER MEN


Posted: Jan 19, 2011 02:06 AM    Msg. 11 of 41       
U need help on that too?


jackotheblah
Joined: Jan 5, 2011

uthink ur lag is bad,takes jesus 3 days to respawn


Posted: Jan 19, 2011 09:45 PM    Msg. 12 of 41       
not yet but i havent finished so maybe.

edit: do u know how to make the cutscene start when the level starts.
And do u know a script to make ai follow the player.
Edited by jackotheblah on Jan 19, 2011 at 10:37 PM
Edited by jackotheblah on Jan 19, 2011 at 11:01 PM


Muscl3r
Joined: May 22, 2010

dont pray 4 easy lives...pray to be STRONGER MEN


Posted: Jan 20, 2011 05:39 AM    Msg. 13 of 41       
(script startup firefight1
(fade_out 1 1 1 0)
(player_enable_input 0)
(camera_control 1)
(sleep 60)
(cinematic_start)
(cinematic_show_letterbox 1)
(camera_set cam1 0)
(sleep 30)
(fade_in 1 1 1 30)
(sleep 60)
(camera_set cam2 90)
(sleep 45)
(camera_set cam3 90)
(sleep 45)
(camera_set cam4 90)
(sleep 60)
(fade_out 1 1 1 30)
(cinematic_stop)
(sleep 30)
(camera_control 0)
(fade_in 1 1 1 30)
(sleep 30)
(player_enable_input 1)
)

This is part of one of my latest scripts for a cutscene.

As for ai following:

(ai_follow_target_players middle_marines)


MoooseGuy
Joined: Aug 10, 2008

I Approve This Message.


Posted: Jan 20, 2011 01:16 PM    Msg. 14 of 41       
Good show, chap.
I will be camping in this thread if you need any more advanced help.


Muscl3r
Joined: May 22, 2010

dont pray 4 easy lives...pray to be STRONGER MEN


Posted: Jan 20, 2011 03:40 PM    Msg. 15 of 41       
:o


jackotheblah
Joined: Jan 5, 2011

uthink ur lag is bad,takes jesus 3 days to respawn


Posted: Jan 20, 2011 05:00 PM    Msg. 16 of 41       
Quote: --- Original message by: Muscl3r
As for ai following:

(ai_follow_target_players middle_marines)


do i have to do the (script startup marines bit in that script

edit: dont worry i figured out i dont.
do u know how to kill an ai after about 10 seconds into the game, is it (ai_kill marinesattack\marines)
Edited by jackotheblah on Jan 20, 2011 at 05:07 PM


Muscl3r
Joined: May 22, 2010

dont pray 4 easy lives...pray to be STRONGER MEN


Posted: Jan 20, 2011 05:18 PM    Msg. 17 of 41       
Yes or you could use:

(ai_kill_silent marinesattack\marines)

Sometimes prevents crashes

To sleep the script for ten seconds:

(sleep 300)

30 units is one second


jackotheblah
Joined: Jan 5, 2011

uthink ur lag is bad,takes jesus 3 days to respawn


Posted: Jan 20, 2011 05:31 PM    Msg. 18 of 41       
when you use the kill script do the bodies stay

edit: discovered they do.
do u know any thing like a dead body biped or scenery.
Edited by jackotheblah on Jan 20, 2011 at 05:45 PM


Muscl3r
Joined: May 22, 2010

dont pray 4 easy lives...pray to be STRONGER MEN


Posted: Jan 20, 2011 06:30 PM    Msg. 19 of 41       
When u place a biped, in properties view tick dead and the biped will spawn dead. I've heard that in mp the bodies disapear after a while, not sure about sp tho. But if you use:

(garbage_collect_now)
(rasterizer_decals_flush)

to clean the map, if the player isn't looking at the dead person it will disappear. There are dead marine tags somewhere. I know theres one in madness p3 that u could *ahem* "exctract".

Otherwise if they do disappear in sp automatically, u could do this in ur script:

(garbage_collect_now)
(rasterizer_decals_flush)
(sleep 60)
(object_create_anew dead_biped1)


jackotheblah
Joined: Jan 5, 2011

uthink ur lag is bad,takes jesus 3 days to respawn


Posted: Jan 20, 2011 07:05 PM    Msg. 20 of 41       
thnx for that i havent tested it with the bodies yet but i will tell you if they stay.


Muscl3r
Joined: May 22, 2010

dont pray 4 easy lives...pray to be STRONGER MEN


Posted: Jan 20, 2011 07:44 PM    Msg. 21 of 41       
ok np


jackotheblah
Joined: Jan 5, 2011

uthink ur lag is bad,takes jesus 3 days to respawn


Posted: Jan 20, 2011 11:03 PM    Msg. 22 of 41       
as far as i know they stay but i havent found any blood stain tags yet, would you recommend any.

edit: 2 things, is there a script that deactivates and activates trigger volumes and the follow player script isnt working.

edit 2: another thing, is it a script to make objectives.
Edited by jackotheblah on Jan 21, 2011 at 12:11 AM


Muscl3r
Joined: May 22, 2010

dont pray 4 easy lives...pray to be STRONGER MEN


Posted: Jan 21, 2011 01:19 AM    Msg. 23 of 41       
Trigger volumes are dealt with in the scripts. If the script is sleeping until the player enters one of the triggers, that is the only trigger "active"

For ai following, the ai will only stay within their firing positions. Add more firing positions where you want them to be able to follow the player. But some ai don't seem to have the ability to follow such as elites (well thats what happened to me anyway). Or maybe you need to put 'true' at the end of the command. I dunno

For objectives/hud messages:

First, open up notepad. Type in the following:

obj1=>>Get to the covenant base
obj2=>>Kill that guy
obj3=>>Do stuff
obj4=>>Go on vacation

Replace the random statements with your own. You can script up to as many
objectives as you want. Then, save it as a ‘unicode’ encoding, and name it ‘hud
messages’.

Save it in data\levels\mapname

Then run tool. Type this in:
tool hud-messages levels\mapname yourscenario

So if my scenario was called retardland and it was located in levels\happyplace, i'd type this:

tool hud-messages levels\happyplace retardland

Note that this will not work if ur scenario is in levels\test... It must be in levels\nameoffolder


Then script this:
(show_hud_help_text true)
(hud_set_help_text obj1)
(hud_set_objective_text obj1)
(sleep 150)
(show_hud_help_text false)

This will show objective 1 for 5 seconds, and then close. It will still appear in
the pause menu.
If Sapien crashes when you try to compiles scripts, run it through tool again,
and check if there’s a file called hud messages in tags\levels\mapname

Modified from Polamee's sp tutorial


jackotheblah
Joined: Jan 5, 2011

uthink ur lag is bad,takes jesus 3 days to respawn


Posted: Jan 21, 2011 05:03 PM    Msg. 24 of 41       
how do i make it that when the player walks over a trigger the objective turns on.

edit: does the hud messages file have to be .txt or .hsc
Edited by jackotheblah on Jan 21, 2011 at 05:05 PM


Ermac
Joined: Nov 24, 2006

Pops up from time to time


Posted: Jan 21, 2011 06:22 PM    Msg. 25 of 41       
Neither. They are .hmt


jackotheblah
Joined: Jan 5, 2011

uthink ur lag is bad,takes jesus 3 days to respawn


Posted: Jan 22, 2011 04:48 PM    Msg. 26 of 41       
thankyou, i've been wondering why it would't work.


MoooseGuy
Joined: Aug 10, 2008

I Approve This Message.


Posted: Jan 22, 2011 06:49 PM    Msg. 27 of 41       
Having fun yet?


jackotheblah
Joined: Jan 5, 2011

uthink ur lag is bad,takes jesus 3 days to respawn


Posted: Jan 22, 2011 09:47 PM    Msg. 28 of 41       
of course i am, halo mapping is the greatest. even if it has a lot of sore problems.


Muscl3r
Joined: May 22, 2010

dont pray 4 easy lives...pray to be STRONGER MEN


Posted: Jan 22, 2011 10:34 PM    Msg. 29 of 41       
and sore losers


jackotheblah
Joined: Jan 5, 2011

uthink ur lag is bad,takes jesus 3 days to respawn


Posted: Jan 23, 2011 02:41 AM    Msg. 30 of 41       
lol.
another thing for my never ending questions, the marines will still not follow the player and i have done this: placed firing positions everywhere done this script.

(script startup marinesfollow
(ai_follow_target_players marinesattack\m1)
(ai_follow_target_players marinesattack\m2)
(ai_follow_target_players marinesattack\m3)
(ai_follow_target_players marinesattack\m4)
(ai_follow_target_players marinesattack\e1)
)

edit: there is a lot of squads becuase they are single ai's incase you are wondering.

edit 2: im kind of embarrest about how big my thread is getting but i think it is because it has got off topic a little bit somewhere but this post is on topic.
Edited by jackotheblah on Jan 23, 2011 at 03:03 AM


Muscl3r
Joined: May 22, 2010

dont pray 4 easy lives...pray to be STRONGER MEN


Posted: Jan 23, 2011 04:06 AM    Msg. 31 of 41       
If those squads are all of the ones in the encounter then you could have (ai_follow_target_players marinesattack)

If this is not working you could try:

(ai_follow_target_players marinesattack true)

or

((ai_follow_target_players marinesattack) true)

Though i dunno if these are valid script commands

PS
Ask as many questions as you need and it will be a lot easier later on.


jackotheblah
Joined: Jan 5, 2011

uthink ur lag is bad,takes jesus 3 days to respawn


Posted: Jan 23, 2011 08:35 PM    Msg. 32 of 41       
im starting to hink that something isnt right about that script, not what you did but with sapien becuase it seems that whatever i put in it compiles, so im going to try putting some thing like (blahbalah) in it and see if it still compiles then ill know something is wrong.

edit: i was right i put in the blah thing and it still compiled in sapien. so there is some thing wrong and i dont know what the problem is any suggestions.
Edited by jackotheblah on Jan 23, 2011 at 08:49 PM


Muscl3r
Joined: May 22, 2010

dont pray 4 easy lives...pray to be STRONGER MEN


Posted: Jan 23, 2011 08:53 PM    Msg. 33 of 41       
Do you have the script in the data\levels\mapname\scripts ??

Is the script saved as an hsc file?


jackotheblah
Joined: Jan 5, 2011

uthink ur lag is bad,takes jesus 3 days to respawn


Posted: Jan 23, 2011 08:58 PM    Msg. 34 of 41       
yes that is all done but is thee a max amount of scripts you can have in a scenario becuase i have a lot.


Muscl3r
Joined: May 22, 2010

dont pray 4 easy lives...pray to be STRONGER MEN


Posted: Jan 23, 2011 09:01 PM    Msg. 35 of 41       
i don't think so.

So just to make sure, ur scenario is located in tags\levels\mapname

and ur scripts are located in data\levels\mapname\scripts

?

 
Page 1 of 2 Go to page: · [1] · 2 · Next

 
Previous Older Thread    Next newer Thread







Time: Thu January 19, 2023 1:34 PM 187 ms.
A Halo Maps Website