Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

hooks: rewrite so dct initializes from hooks #242

Merged
merged 3 commits into from
Sep 2, 2023
Merged

Conversation

jtoppins
Copy link
Owner

It seems DCS has several bugs where scripts in the .miz might be run by the client. To fix this remove the requirement to have mission designers apply the dct-mission-init.lua script as a do-script-from-file mission start trigger. It is expected only servers will have the hooks installed and so this should avoid the client side issues.

As part of the rewrite the dct hooks dropped support for exporting data about the server. There are several other third-party server monitoring tools/hooks out there that provide far greater capability than the dct hook could provide.

@jtoppins jtoppins force-pushed the feature-hooks-rewrite branch 3 times, most recently from acc6d26 to eb4b182 Compare December 30, 2022 03:57
@jtoppins jtoppins force-pushed the feature-hooks-rewrite branch 5 times, most recently from d653c55 to f72a743 Compare March 20, 2023 18:10
It seems DCS has several bugs where scripts in the .miz might be run by
the client. To fix this remove the requirement to have mission designers
apply the `dct-mission-init.lua` script as a do-script-from-file mission
start trigger. It is expected only servers will have the hooks installed
and so this should avoid the client side issues.

As part of the rewrite the dct hooks dropped support for exporting data
about the server. There are several other third-party server monitoring
tools/hooks out there that provide far greater capability than the dct
hook could provide.
Mission designers are layering other scripts on top of DCT. This means
there initialization needs to be completed before players should be
allowed to join slots. To allow for this use case, a well known mission
flag can be used. The DCT hooks script will then use this flag to
determine if hooks are globally enabled or not. Finally a server level
configuration can be set to initially set this flag true/false. With the
default being true so DCT will enable slots as normal as soon as it is
ready.
DCT is being used as a base for some mission designers and then they are
building on top of DCT by layering on other scripts like MOOSE to
customize their mission. To allow sequencing of these other scripts emit
an init complete event for all event handlers in the DCS mission
environment so that proper sequencing can take place.
@jtoppins jtoppins merged commit e17b6fd into master Sep 2, 2023
1 of 2 checks passed
@jtoppins jtoppins deleted the feature-hooks-rewrite branch September 2, 2023 23:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant