-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstage.go
More file actions
39 lines (36 loc) · 942 Bytes
/
stage.go
File metadata and controls
39 lines (36 loc) · 942 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
package bevi
// Stage represents a scheduling stage in the ECS execution pipeline.
type Stage int
const (
// PreStartup runs once before the main Startup stage.
PreStartup Stage = iota
// Startup runs once at application initialization.
Startup
// PostStartup runs once after Startup for early initialization finalization.
PostStartup
// PreUpdate runs once before the main Update stage for preparatory systems.
PreUpdate
// Update runs every frame for game logic.
Update
// PostUpdate runs once after the main Update stage for cleanup or finalization.
PostUpdate
)
// String returns the string representation of a stage.
func (s Stage) String() string {
switch s {
case PreStartup:
return "PreStartup"
case Startup:
return "Startup"
case PostStartup:
return "PostStartup"
case PreUpdate:
return "PreUpdate"
case Update:
return "Update"
case PostUpdate:
return "PostUpdate"
default:
return "Unknown"
}
}