summaryrefslogtreecommitdiff
path: root/particle.go
blob: 4f6bce59d8b73ad0c6d6c90b7003288345544b4a (plain) (blame)
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
package mt

type AttractionKind uint8

const (
	NoAttraction    AttractionKind = iota // None
	PointAttraction                       // Point
	LineAttraction                        // Line
	PlaneAttraction                       // Plane
)

//go:generate stringer -linecomment -type AttractionKind

type ParticleSpawnerFlags uint8

const (
	AttractorKill ParticleSpawnerFlags = 1 << iota // Particle dies on contact
)

//go:generate stringer -linecomment -type ParticleSpawnerFlags

type ParticleTextureFlags uint8

const (
	Animated ParticleTextureFlags = 1 << iota // Animated
)

//go:generate stringer -linecomment -type ParticleTextureFlags

type ParticleTexture struct {
	Flags ParticleTextureFlags
	Alpha TweenF32
	Scale TweenV2F32

	//mt:if %s.Flags & Animated == Animated
	Animation TileAnim
	//mt:end
}