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 »How many ticks is a second regarding the scripts?

Author Topic: How many ticks is a second regarding the scripts? (26 messages, Page 1 of 1)
Moderators: Dennis

Halo CE Noob Modder117
Joined: Aug 9, 2018

Some tutorials would be nice...


Posted: Nov 18, 2018 11:19 PM    Msg. 1 of 26       
So I figured out how to make the music in my map stop, problem is (sleep 150) is way too short it ends up making the music fade out before it even begins. SO, how many ticks is it per second in this game? Wasn't it 150 ticks = 5 seconds? If so I want the music to at least loop for 5 minutes or so. Another question, the game wont explode or anything if you use a large enough amount for the sleep function like say sleep_5000 or sleep_10000?


The Gravemind
Joined: Jul 26, 2016

I Am The Monument To All Your Sins


Posted: Nov 19, 2018 01:30 AM    Msg. 2 of 26       
the only thing i know is that one tick is roughly 0.03 seconds I could be horribly though.
Edited by The Gravemind on Nov 19, 2018 at 01:31 AM


SBB_Michelle
Joined: Nov 4, 2015

Floof


Posted: Nov 19, 2018 03:21 AM    Msg. 3 of 26       


There is 30 ticks in a second,
there is 60 seconds in a minute.

So, for 5 minutes you do 5x60x30. Pay attention in school, kids.

(sleep <short> [<script>])

'short' is short for short int, a short int is a 16 bit int. In a signed int one bit is used to set the sign (if it's negative or not). A bit can be either on or off (true or false, 1 or 0).
2 x 2 x 2 x 2 x 2 x 2 x 2 x 2 x 2 x 2 x 2 x 2 x 2 x 2 x 2 = 32768 possibilities
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15

This can be written as:
2^15 = 32768


The first possibility is 0, so 32768 - 1 (one possibility) = 32767 possibilities above 0
This means the maximum number accepted for a short is 32767, which means the maximum number for the sleep script is 32767.

You can also gather that if 150 ticks is 5 seconds that 30 ticks is one second, because:
150/5=30


With this deductive knowledge you can also find out that 32767 ticks is
32767/30   = 1092.23 seconds
1092.23/60 = 18.2 minutes
0.2*60 = 12 seconds

18:12 is the max amount of time for a sleep script.


Btw gravemind, you are right. You can find out the amount of seconds in a tick by doing:
1/30=0.03333333


I told you all of this because a lot of things in this game can be figured out from info you may already have. You need deductive reasoning to understand a lot of things.

If you give a man fish, you feed him for a day. If you teach a man how to fish, you feed him for a lifetime.
Edited by SBB_Michelle on Nov 19, 2018 at 03:30 AM


Spartan314
Joined: Aug 21, 2010

Former biped rigger & FP animator


Posted: Nov 19, 2018 06:41 AM    Msg. 4 of 26       
Give a man a fish, you feed him for a day. Give a man some ticks, and you flea him for a lifetime.


The Gravemind
Joined: Jul 26, 2016

I Am The Monument To All Your Sins


Posted: Nov 19, 2018 01:15 PM    Msg. 5 of 26       
damn I feel enlightened


Halo CE Noob Modder117
Joined: Aug 9, 2018

Some tutorials would be nice...


Posted: Nov 19, 2018 10:15 PM    Msg. 6 of 26       
Thanks for all that guys, really appreciate that. Just one last thing, its alright if I use ticks for music right? Is it not recommended or fine?

Plus, ticks... Is this an American or European thing? Back in my school days I never heard of nor used ticks. Seconds, minutes and hours are all I've ever heard of regarding time.

I just thought 5 minutes of looping battle music is alright. Is 5 minutes alright for a song to loop? Here is a sample of 1 out of the few sections of my new script I've been working on:

(script startup obj2
(sleep_until (volume_test_objects defend (players)) 0)
(show_hud_help_text true)
(hud_set_objective_text defend)
(hud_set_help_text defend)
(sleep 150)
(show_hud_help_text false)
(sound_looping_start "levels\b40\music\b40_08" none 1 )
(sleep 800) <---------- What could be an appropriate sleeper here?
(sound_looping_stop levels\b40\music\b40_08)
)
Edited by Halo CE Noob Modder117 on Nov 19, 2018 at 10:19 PM


Spartan314
Joined: Aug 21, 2010

Former biped rigger & FP animator


Posted: Nov 20, 2018 08:15 AM    Msg. 7 of 26       
I don't actually know if ticks are the proper term but I'd guess it has a correlation with the FPS.
30 ticks in a second... 30 frames in a second...
Possibly one the many(?) reasons why Halo CE was locked to 30 fps
Michelle'll correct me if I'm wrong

I wouldn't necessarily say it's a universal mode of time

Also I know nothing about scripting
But I'd also guess that sleep 800 would mean you'd be waiting 800 ticks before moving to the next part of the script
800/30 = 26 + 1/3 seconds
Edited by Spartan314 on Nov 20, 2018 at 08:40 AM


SBB_Michelle
Joined: Nov 4, 2015

Floof


Posted: Nov 20, 2018 01:35 PM    Msg. 8 of 26       
It's more of a game term, since the game actually advances its scripting, physics, ai and everything else 30 times a second, all at the same time. We call it a tick, because that is when the clock ticks and time advances.

And yes, the biggest reason for it being 30 tick is because the game ran at 30fps on xbox.

Even with mods like chimera the game is still locked to this, we're just creating inbetween points between the ticks that are purely visual.

Edit: Almost forgot.

Sleep can be used differently than what you're doing.

(sleep <short> [<script>])

(sleep 800 (sound_looping_stop levels\b40\music\b40_08))


From the description on halo scripting bible it implies that this will keep the script that this sleep is executed in going, but it will in the background wait 800 ticks and execute this command when that time has passed.

-----

Also, if your music is not supposed to be a loop, there is a box you can tick in the sound_looping tag called: 'not a loop'. This makes it play only once and you won't need the script to end the track.


Edited by SBB_Michelle on Nov 20, 2018 at 01:40 PM


Halo CE Noob Modder117
Joined: Aug 9, 2018

Some tutorials would be nice...


Posted: Nov 20, 2018 06:45 PM    Msg. 9 of 26       
I'm just using existing in-game music, that one I'm using is straight from the b40 script. What baffles me the most is that when I look at other campaign mission scripts and see how it was done the music scripts all look different and end with objectives or trigger points. Its confusing. What I'd really want to know too is how to just make a condition where the music would just stop AFTER completing an objective. Would you do this:

(script startup obj2
(sleep_until (volume_test_objects defend (players)) 0)
(show_hud_help_text true)
(hud_set_objective_text defend)
(hud_set_help_text defend)
(sleep 150)
(show_hud_help_text false)
(sound_looping_start "levels\b40\music\b40_08" none 1 )
)

(script startup obj3
(sleep_until (volume_test_objects test (players)) 0)
(show_hud_help_text true)
(hud_set_objective_text test)
(hud_set_help_text test)
(sleep 150)
(show_hud_help_text false)
(sound_looping_stop levels\b40\music\b40_08)
)



Side note: Do objectives count as completed when the next one is triggered? Example: You start the mission and it says to leave the area, when you pass another trigger point it says to do whatever next. When that text shows up for the next objective that's it? Do you need to do anything else or is it done once the next one is triggered?
Edited by Halo CE Noob Modder117 on Nov 20, 2018 at 06:49 PM


DeadHamster
Joined: Jun 8, 2014


Posted: Nov 28, 2018 12:07 AM    Msg. 10 of 26       
Objective text is added using (hud_set_objective_text <hud_message>)

The start menu's text I believe is part of the HUD bitmaps, not part of a script.

Doing missions all depends on how the objectives are setup. I generally have one "master" script running that calls on static scripts or continuous scripts to do specific functions. For example


(script dormant step2
(ai_place seconds)
(object_create ghost1)
(object_create ghost2)
(vehicle_load_magic ghost1 "" seconds/pilot)
(vehicle_load_magic ghost2 "" seconds/pilot)
(objects_attach dropship1 "small_cargo01" ghost1 "" )
(objects_attach dropship1 "small_cargo02" ghost2 "" )
)


(script dormant step3
(ai_place thirds)
(object_create ghost3)
(object_create ghost4)
(vehicle_load_magic ghost1 "" thirds/pilot)
(vehicle_load_magic ghost2 "" thirds/pilot)
(objects_attach dropship1 "small_cargo01" ghost1 "" )
(objects_attach dropship1 "small_cargo02" ghost2 "" )
)


(script startup master
(ai_place initial)
(sleep_until (or (= 1 (volume_test_objects trigger1 (players))) (= 0 (ai_living_count initial)) 5)
(wake step2)
(sleep_until (or (= 1 (volume_test_objects trigger2 (players))) (= 0 (ai_living_count seconds)) 5)
(wake step3)
(sleep_until (game_all_quiet) 5)
(game_save_totally_unsafe)
)




To control sounds, run a separate startup script that's first command sleeps until the player enters the area or does whatever you want them to do. Then have another sleep_until conditions for music ending, and stop the looping sound.







Edited by DeadHamster on Nov 28, 2018 at 12:08 AM


Halo CE Noob Modder117
Joined: Aug 9, 2018

Some tutorials would be nice...


Posted: Nov 28, 2018 02:00 AM    Msg. 11 of 26       
Yeah. I forgot to edit my post. Basically, in one night I figured out almost EVERYTHING I wanted to know... There is however, just 1 little thing I am having troubles with...

Making those 'if' variable scripts. I want to initiate something AFTER eliminating an encounter. I found a thread (I cannot friggen find it now, I should have bookmarked these things...) Gamma927 explained how to make a waypoint and explained what each of the lines within the script meant so all I had to do was name and match my objects and flags so it was pretty well done and easy to follow.
Edited by Halo CE Noob Modder117 on Nov 28, 2018 at 07:53 AM


DeadHamster
Joined: Jun 8, 2014


Posted: Nov 28, 2018 01:41 PM    Msg. 12 of 26       
Quote: --- Original message by: Halo CE Noob Modder117

Yeah. I forgot to edit my post. Basically, in one night I figured out almost EVERYTHING I wanted to know... There is however, just 1 little thing I am having troubles with...

Making those 'if' variable scripts. I want to initiate something AFTER eliminating an encounter. I found a thread (I cannot friggen find it now, I should have bookmarked these things...) Gamma927 explained how to make a waypoint and explained what each of the lines within the script meant so all I had to do was name and match my objects and flags so it was pretty well done and easy to follow.
Edited by Halo CE Noob Modder117 on Nov 28, 2018 at 07:53 AM



Google Search

Use site:www.websitename.com in google to only search a specific website. Google's site search is much, much better than any forum's search feature. The first result on that link has the answer you were looking for from Gamma.


The Gravemind
Joined: Jul 26, 2016

I Am The Monument To All Your Sins


Posted: Nov 28, 2018 07:16 PM    Msg. 13 of 26       
Oh hey dead hamster glad to still see you around


Halo CE Noob Modder117
Joined: Aug 9, 2018

Some tutorials would be nice...


Posted: Nov 28, 2018 10:30 PM    Msg. 14 of 26       
Hamster has inspired me to create a level like his connecting various New Mombasa BSPs. Anyway, I found the thread thanks for that tip.

Basically the thing I want to know is: can you make a dormant script be activated AFTER you clear ALL enemies from a certain encounter? Basically aside from threads, I try to see how its all structured in the campaign scripts but some of it seems a little too complex with many variables.

(sleep_until (< 0 (ai_living_count test_encounter ) -regardless of my tests, clearing the encounter NEVER triggers the next portion of my startup script and NEVER triggers my dormant script. I'm a little confused with this one. I tried one of the 'if' versions of the script but it causes parenthesis errors.

TLDR: I want my next script to activate AFTER I kill off my encounter.


DeadHamster
Joined: Jun 8, 2014


Posted: Nov 29, 2018 05:21 PM    Msg. 15 of 26       
(= 0 (ai_living_count test_encounter) 5)



= 0

what you put waited until 0 < ai_living_count.

Which means it happened immediately.


Halo CE Noob Modder117
Joined: Aug 9, 2018

Some tutorials would be nice...


Posted: Nov 29, 2018 08:51 PM    Msg. 16 of 26       
I'ma make this quick so bare with me as I am just going to chuck this in here and there may be mistakes here:

(script startup 5
(sleep_until (= 0 (ai_living_count ambush_wave0 ) 5)) (sound_impulse_start "sound\dialog\b30\b30_020_cortana" none 1 )))
(sleep 150)
(ai_place test3)
(game_save_totally_unsafe)
)

What does the = 0 mean? and what does the 5)) mean?
Also, a script like this, is it better if I did it as a dormant script? I hear its not too good using just startups.


SBB_Michelle
Joined: Nov 4, 2015

Floof


Posted: Nov 29, 2018 08:59 PM    Msg. 17 of 26       
< means less than
So, whatever way you order it would never work properly

Preferably you order these in in order of: thing you want to be 0, 0.

This is just for clarity and you can shrug it off as me being picky.

(= (ai_living_count test_encounter) 0)


The reason that your thing doesn't work as intended is because you are waiting for 0 to be less than the ai living count. Which means the condition is true as long as there is at least one character alive in your encounter. And it becomes false when there is no characters alive in your encounter.
bad:
(< 0 (ai_living_count test_encounter))
if (ai_living_count test_encounter) > 0 that means 0 < (ai_living_count test_encounter)


It also would not work the other way around:
(< (ai_living_count test_encounter) 0)

Because that means the amount of living enemies has to be -1 or lower for this script to activate.

Again watch out with this too (deadhamster's example):

(= 0 (ai_living_count test_encounter) 5)


This checks if (0 == (ai_living_count test_encounter) == 5)

And that can never be true as 0 != 5

You want to use:

(= (ai_living_count test_encounter) 0)

That will activate when there is 0 alive characters in this encounter, which only happens when they are all dead.

Alternatively you can check if there is less than a certain amount of enemies alive in the encounter:

(< (ai_living_count test_encounter) 3)

This means if there is LESS THAN 3 characters in the encounter alive it will activate. The highest number of characters in this encounter that can be alive for the script to start is 2.

Or:
(<= (ai_living_count test_encounter) 3)

This means that if there is 3 OR LESS characters alive in the encounter the script will start.

https://www.cs.cmu.edu/Groups/AI/html/cltl/clm/node124.html


Halo CE Noob Modder117
Joined: Aug 9, 2018

Some tutorials would be nice...


Posted: Nov 30, 2018 03:30 AM    Msg. 18 of 26       
Thanks for all the really awesome replies guys. I really appreciate all the help you guys have given me so far on this tedious mission making journey of mine. I only have one problem now:

(script startup test
(if (= (ai_living_count testdummy_enc0) 0)
(sound_impulse_start "sound\dialog\b30\b30_020_cortana" none 1 )
)
-Left parenthesis unmatched

(script startup test
(sleep_until (= (ai_living_count testdummy_enc0) 0)
(sound_impulse_start "sound\dialog\b30\b30_020_cortana" none 1 )
)
-Left parenthesis unmatched

(script startup test
(sleep_until (= (ai_living_count testdummy_enc0) 0)(sound_impulse_start "sound\dialog\b30\b30_020_cortana" none 1 ))
)
-Left parenthesis unmatched

(script startup test
(sleep_until (= 0 (ai_living_count testdummy_enc0) 0)(sound_impulse_start "sound\dialog\b30\b30_020_cortana" none 1 ))
)
-Left parenthesis unmatched

(script startup test
(sleep_until (= 0 (ai_living_count testdummy_enc0 ))0 (sound_impulse_start "sound\dialog\b30\b30_020_cortana" none 1 ))
)
-Left parenthesis unmatched

(script dormant test
(= (ai_living_count testdummy_enc0) 0)
(sound_impulse_start "sound\dialog\b30\b30_020_cortana" none 1 )
)
-No errors but does NOTHING in-game (and yea, script below it uses wake test line too)

I've mixed and matched so many other combos too via other people's examples and of course, copying the base-game scripts layout and if I'm not getting left parenthesis errors, it has no errors but does nothing in game. This script, of all things seem more simple than the other complex ones I did yet I just cannot comprehend what I'm doing wrong.

All in all, basically, I'm attempting to trigger dialogue and some other vehicle spawning etc. after I clear my encounter but nothing seems to be working... So dumb. Hopefully you guys can see those test scripts I did and see where the error is... Much appreciated, you'll get 5 cookies.
Edited by Halo CE Noob Modder117 on Nov 30, 2018 at 03:32 AM


SBB_Michelle
Joined: Nov 4, 2015

Floof


Posted: Nov 30, 2018 10:24 AM    Msg. 19 of 26       
get notepad++

Set the language to lisp.

When you select the first parenthesis in your script [these thingies "( )"] you will notice it lights up, but no other lights up. That means you forgot to close your script.

Formatting suggestion to make this easier to spot:


Indent your script to signal what is part of what.

First indent on line 2 is because it is part of the script called test.
Second on the line 3 is because that only executes if the if statement returns true.

This script won't work even if you fix that though. Because you are executing this right when the map starts. It does not check over and over, but instead checks at a time where the player could have had no influence on it.

Instead do something like this:


Note how I didn't indent line 3. That is because line 3 is not part of the sleep_until statement like it is in the prior example. Instead of skipping everything in the if statement when the alive enemy count isn't 0 like in the first example. The whole script pauses when the condition is not met and will not unpause until it is met.

Note that (sleep_until) checks every second, so you may have to wait part of a second to see the effect.

You can adjust how fast it checks by adding an extra number


This variant checks every 10 ticks (or 1/3rd) of a second. I only suggest adjusting this when it is actually needed. If there is situations where there is multiple checks going on at once you can get odd inconsistent behavior.


Halo CE Noob Modder117
Joined: Aug 9, 2018

Some tutorials would be nice...


Posted: Nov 30, 2018 11:29 AM    Msg. 20 of 26       
Keep forgetting to download that program, those pretty colours make it that much more attractive. Anyway, one day when I finish this map I'm doing I'm going to have to figure out how to thank you and the others for helping me out. Wouldn't have gotten this far without all the help.

In other modding news, I just made another thread in the other part of the forum about 3DS MAX again... Whilst waiting for script assistance I continued churning out more scenery tags for my map. Though there is 1, just 1 model out of the 20 I've done that is giving me trouble. I'm so pissed off I'm going to put a hole in something, but first I'm going to sleep...

I'm not crazy. Thanks again guys.


DeadHamster
Joined: Jun 8, 2014


Posted: Nov 30, 2018 03:57 PM    Msg. 21 of 26       
Quote: --- Original message by: SBB_Michelle
Preferably you order these in in order of: thing you want to be 0, 0.
This is just for clarity and you can shrug it off as me being picky.


https://www.youtube.com/watch?v=Z8JRJRyCVwU

I have no rhyme or reason as to what order I place the variables when dealing with > or <, I flip back and forth. But (= 0 is always the way. Return to the light.

Quote: --- Original message by: SBB_Michelle
Again watch out with this too (deadhamster's example):

(= 0 (ai_living_count test_encounter) 5)


This checks if (0 == (ai_living_count test_encounter) == 5)

And that can never be true as 0 != 5



O_O Yikes! Thank you for fixing that for me michelle. What that was intended for was;

(sleep_until (= 0 (ai_living_count test_encounter)) 5)

Which would check for the value to be true every 5 ticks as opposed to once per second as is stock. Missed a ) and completely disregarded putting in the (sleep_until out front.

I had typed out this really verbose post listing different methods of having AI retreat and using trigger volumes to move AI around a BSP area based on where the player went. It took so long to type the browser lost my session, and I lost my post. So I said screw that and just typed out that command really quick. A bad command, it would seem.


But I should be all set to retype most of that post out now;

Halo CE Guy

Rest of the post is towards you.


So, you shouldn't be using (= 0 (ai_living_count)

First, like michelle said get Notepad++ and then after download this;

Hamp's Custom Blamscript Language

That's a style sheet I've been using and customizing for 4-5 years now. Not perfect, but it's helpful for sure. CMT also released one, feel free to disregard me completely and find theirs instead.

To install the styles, open notepad++, go to the language menubar item, scroll to the bottom and click "Define Your Language". Import the .xml file in the download, and then Click Save As and name it BLAM or whatever. Now, close the Define Your Language menu, go BACK to the Language menubar item, scroll BACK to the bottom and select BLAM or whatever you saved it as. Now your blamscripts will look like this instead;



Unless you disregarded me completely and downloaded CMTs. Then it probably won't look like that at all.

This separates different functions. I might have mixed some up, but the general rule of thumb is;

Red- Script startup lines (script, global, startup, dormant)
Green- Script functions (sleep, if, begin, cond, set)
Blue- Game Functions (ai_place, object_create)
Orange- Return Functions (unit_get_health, volume_test_objects, device_get_position)
Brown- Variables or Object Properties (vehicle_name, short, object_list, trigger_volume)
Purple- Inherent Values (True, False, None, Void, Min, Max)

This makes breaking a script apart much easier, as each part of the script is sectioned off from the rest by obvious color differences.



But, again, you shouldn't be using (sleep_until (= 0 (ai_living_count encounter))5)

You should be using something like this



This waits until the AI are almost dead. Then it makes them retreat, or call in reinforcements. The AI in the game are all different, and should be treated as such. Not even an alien army is fearless of death; grunts should retreat, jackals regroup to higher ground. You can use trigger volumes to read how the player is moving around the map, and then run something like this based on where the player is;



This checks if the player is either in cliffs or the beach, and moves the snipers away from him and the elites and jackals towards him. This is assuming you have two squads made, where cliff AI has firing points around some cliffs, and Beach AI has them on the beach. Or whatever, not limited to cliffs and beaches obviously. Just concepts.


Also, instead of just checking for one variable (AI being less than 4), why not two?


(sleep_until (or (> 4 (ai_living_count encounter)) (= 0 (ai_living_count encounter/elites)) 5)

That will sleep until either 4 total AI are left, or both elites have been killed, sending their subordinates into a panic perhaps. Or maybe, having given up hope, the grunts perform a suicide rush with grenades. Or maybe at that point Krypto the superdog descends from the heavens and bites the master chief square in his crotch. Only you get to make that decision.


SBB_Michelle
Joined: Nov 4, 2015

Floof


Posted: Nov 30, 2018 05:21 PM    Msg. 22 of 26       
I'm here to pick a fight now. I will explain my rationale for:

(= (value_to_check) 0)


The reason is simple.

I will use a more generic style for this kind of comparison to explain this:

if (value_to_check == 0)


The rationale is that we're checking if value_to_check is 0. Not if 0 is value_to_check. Switching that around outside of halomaps will get you called out.

This is for clarity.

It's way easier to explain that you are checking if there is less than 4 enemies alive in your encounter, than it is to explain that you are checking if 4 is higher than the enemies alive.
It makes your code harder to read.

I suggest:
(sleep_until (or (>= (ai_living_count encounter) 4) (= (ai_living_count encounter/elites) 0) 5)



Quote: --- Original message by: Halo CE Noob Modder117
Keep forgetting to download that program, those pretty colours make it that much more attractive.


I suggest you download the program so scripting will be easier, not because it looks better. If all you're seeing is black and white the only thing that will save you is proper formatting.

Edit: Btw Hamster, you can also do:
(sleep_until ((unit_get_health banshee1) (unit_get_health banshee2) 0) 5)


And even more useful for you, an improvement to your 'secret save routine'
(sleep_until (game_safe_to_save) 5)
(game_save_totally_unsafe)

This value only rings true under much of the same conditions as (game_all_quiet) EXCEPT, it doesn't ring true when the player is airborne. Fixing your falling death save issue.

Edit: Screwed a thing up.
Edited by SBB_Michelle on Dec 1, 2018 at 12:56 AM


DeadHamster
Joined: Jun 8, 2014


Posted: Nov 30, 2018 06:12 PM    Msg. 23 of 26       
Quote: --- Original message by: SBB_Michelle
Edit: Btw Hamster, you can also do:
(sleep_until ((unit_get_health banshee1) (unit_get_health banshee2) 0) 5)


And even more useful for you, an improvement to your 'secret save routine'
(sleep_until (game_safe_to_save) 5)
(game_save_totally_unsafe)

This value only rings true under much of the same conditions as (game_all_quiet) EXCEPT, it doesn't ring true when the player is airborne. Fixing your falling death save issue.
Edited by SBB_Michelle on Nov 30, 2018 at 05:31 PM


I assumed you missed the = sign and meant

(sleep_until (= (unit_get_health banshee1) (unit_get_health banshee2) 0) 5)

Definitely much cleaner that way.

I always assumed (mistakenly, apparently) that game_all_quiet checked for more than the game_safe_to_save did. Good to know, updating all that immediately. Thanks for the tip.


Halo CE Noob Modder117
Joined: Aug 9, 2018

Some tutorials would be nice...


Posted: Dec 1, 2018 03:46 AM    Msg. 24 of 26       
Well we did it. Cortana now talks and the rest all happens AFTER clearing that encounter... I swapped it to a dormant script of course because the encounter itself doesn't spawn until later in the mission so as a startup script due to nothing being spawned yet everything triggered at the beginning of the mission. But I managed to clear everything else up. Couldn't have done it without you guys.


DeadHamster
Joined: Jun 8, 2014


Posted: Dec 7, 2018 06:22 PM    Msg. 25 of 26       
Quote: --- Original message by: Halo CE Noob Modder117
Well we did it. Cortana now talks and the rest all happens AFTER clearing that encounter... I swapped it to a dormant script of course because the encounter itself doesn't spawn until later in the mission so as a startup script due to nothing being spawned yet everything triggered at the beginning of the mission. But I managed to clear everything else up. Couldn't have done it without you guys.


Just an FYI, better a startup script that sleeps until the conditions are met, IE a trigger volume or a sequence of events.

If you create a single startup script that runs dormant scripts, the player may break sequence by escaping a section of the level or finding an exit you didn't think of, whatever it may be. If that becomes the case, your main script is waiting for a sequence of events that the player already bypassed, and all the rest of the dormant scripts can't get called because the main script that would call them is waiting for something that will never happen.

If you instead have a separate startup for each section of the level, it'll sleep_until the conditions are met and start immediately. If the player leaves before completing that section, that's okay. The next section has it's own script and will start as soon as the player enters the area, or whatever the sleep_until has it's requirement filled. The player can break sequence and still play out the rest of the level.


Halo CE Noob Modder117
Joined: Aug 9, 2018

Some tutorials would be nice...


Posted: Dec 8, 2018 07:28 AM    Msg. 26 of 26       
Yeah I figured that. Normally my OCD would have killed me however, I thought of Halo 2's Delta Halo. There is a chance you can screw up the entire mission if you don't go through all the trigger points correctly, climb out of bounds of the map, skip parts etc.

Though that doesn't mean I'd cut corners... I compensated for some scripts and actually added a variety of alternative things to happen should you not proceed to each waypoint accordingly. I've even scripted in invisible blockers and some locked doors that are removed once certain conditions are met depending on mission progression.

I cannot believe of all things... I'm scripting up a campaign mission. One of the hardest things I believed there was and that I swore I'd never try, I'm having fun doing. And I still cannot edit a simple campaign bsp. I think when I finish with this mission, I'll go back to trying to use 3DS MAX after my recent scenery successes.

Again thanks for all the help.

 

 
Previous Older Thread    Next newer Thread







Time: Mon December 17, 2018 6:09 AM 250 ms.
A Halo Maps Website