BFEVFL: Difference between revisions
Jump to navigation
Jump to search
→Event
imported>Leoetlino (→Actor) |
imported>Leoetlino (→Event) |
||
Line 259: | Line 259: | ||
=== Event === | === Event === | ||
{{ | ==== EventType enum ==== | ||
{|class="wikitable" | |||
! Value !! Name !! Description | |||
|- | |||
| 0 || Action || Invokes an actor function ("action") with no return value. | |||
|- | |||
| 1 || Switch || Invokes an actor function ("query") with an int return value and branches execution flow depending on it. | |||
|- | |||
| 2 || Fork || Branches execution flow unconditionally. | |||
|- | |||
| 3 || Join || Used to reunify execution flow after a fork finishes executing. | |||
|- | |||
| 4 || Sub flow || Invokes an entry point in the same or in a different event flow. Similar to a function call. | |||
|} | |||
==== Main event structure ==== | |||
{|class="wikitable" | |||
!rowspan=2|Offset | |||
!rowspan=2|Type | |||
!colspan=5|Description | |||
|- | |||
! Action !! Switch !! Fork !! Join !! Sub flow | |||
|- | |||
| 0x0 || PascalString* ||colspan=5| Name | |||
|- | |||
| 0x8 || EventType (u8) ||colspan=5| Type | |||
|- | |||
| 0x9 || u8 ||colspan=5| Padding | |||
|- | |||
| 0xa || u16 || Next event index || Number of cases (>=0) || Number of forks (>0) ||colspan=2| Next event index | |||
|- | |||
| 0xc || u16 ||colspan=2 Actor index || Join event index (required) ||colspan=3| Unused | |||
|- | |||
| 0xe || u16 || Actor action index || Actor query index ||colspan=3| Unused | |||
|- | |||
| 0x10 || void* ||colspan=2| Container* (optional parameters) || u16* (fork event indexes) || Unused || Container* (optional parameters) | |||
|- | |||
| 0x18 || void* || Unused || SwitchCases* (0x0: u32 value, 0x4: u16 event index, 0x6: u16 padding) ||colspan=2| Unused || PascalString* (flowchart name) | |||
|- | |||
| 0x20 || void* ||colspan=4| Unused || PascalString* (entry point name) | |||
|} | |||
=== Entry point === | === Entry point === |