Skip to main content

ExternalFormHandler

Trait ExternalFormHandler 

Source
pub trait ExternalFormHandler: Send + Sync {
    // Required method
    fn dispatch_form(
        &self,
        ctx: &mut CommandContext,
        form_id: u32,
        args: &[Value],
    ) -> Result<bool>;
}
Expand description

Optional external handler for numeric forms.

The project can keep game-specific implementations (e.g. SCREEN/MSGBK) outside this crate, while still letting the VM dispatch through here.

Required Methods§

Source

fn dispatch_form( &self, ctx: &mut CommandContext, form_id: u32, args: &[Value], ) -> Result<bool>

Return true if the form ID was handled.

Implementors§