Skip to content

H1A - Scripting - Stubs - Function Body Now Required. #149

@ChaOtoko

Description

@ChaOtoko

As titled. I don't know if this has always been the case, or its specific to H1A or its due to an update to MCC. But I discovered this while experimenting with stubs.

If you try to create a stub without defining it the following error is produced when the script is compiled.

[test_script line 1] i expected (script stub <type> <name> <expression(s)>): (script stub void say_hello)

Looking through the level scripts "base_a10.hsc" has stub scripts with bodies.

...
(script stub void halo_setup (print "Joe's Cool Cinematic"))
...

When compiled single/multiplayer maps are run in MCC their stub scripts will still execute.

So they're overridable static scripts. But can only be overridden once (it can still be in a different script file).

Metadata

Metadata

Assignees

Labels

contentWritten content required for the wiki

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions