-
Notifications
You must be signed in to change notification settings - Fork 11
/
Copy pathTODO
170 lines (149 loc) · 6.06 KB
/
TODO
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
FOCUS: architecture & API
ROADMAP:
1. replace map viewer (weeks); application development
2. performance optimizations (months); technology
replace q3mapviewer
- collision
- gravity
- debug render
- audio support
- render player's current weapon
render system
refactor:
- replace IORef usage with StateT + IO; will simplify RenderSystem module
- generalize MD3 loading and triggering of pipeline recompilation
small and obvious:
- character support: player character
- load materials
- cache loaded model (GPUMD3) to speed up instantiation (CharacterInstance); store multiple models to feed instances from
big:
- collision:
query MD3 collision shapes by name
query inline model collision shape
description:
entity's shape (box,sphere,ray or rays)
collides with each other and inline models (level is model id 0)
collision result (content flags, entity type) is passed to interact
- make the interface monadic; explicit resource allocation and release
- precache support
- new renderable: BSPInlineModel
high level, to be elaborated
- pass optional debug options to render system; e.g. collision geometry and lightmap only
- control game character animation
- performance benchmark
- restructure code: engine, game; design engine architecture (submodules, api, sample code)
- draw hud
- audio support
- font/text support
- manual pipeline optimization:
ok - optimize lambdacube-gl: skip pipeline setup commands before empty slots; avoid useless state changes; this may require to change the IR
result: minor preformance improvement
- use per object texture unforms for each layers of stage textures
- use dedicated shader for default materials: lightmap + diffuse; diffuse
- precompile and cache all non-default shaders
- minimize render call count: build shared vertex and index buffer; use instanced rendering; use uniform block or instanced arrays; build texture atlas
draw call >= shader count
draw call = different models * instance count; however instance count may differ for models
game
refactor:
- split game logic; framework, entity logic
small and obvious:
big:
ok - make simulation independent from rendering: http://gafferongames.com/game-physics/fix-your-timestep/
- split to client and server
- collision detection
- gravity
- door handling; need inline model support
- refactor entities to use q3 item types
- Allow entities to indirectly modify other entities:
In each frame, when an entity gets updated, it can inspect the previous state of any entity
Use case: shooting
Based on this information, the entity can make Actions
After every entity has been updated, the collected actions are processed, putting the entities in their final state for the next frame
- Hit detection (Ray -> Entity)
Blocker:
No general method yet for entity collision geometry query (Problem: which frame?)
refactor notes:
- use proper resource monad
- manage subsystems elegantly
Binary: BSP.hs, MD3.hs
- factor out common functions from BSP and MD3 loaders
Megaparsec: Character.hs. Entity.hs, ShaderParser.hs
- factor out common parts
- use same floating number parser
Material.hs
- rename CommonAttrs and StageAttrs (also modify Graphics.lc)
install guide:
- local build: lambdacube-quake3:
works well, it finds the local lc directory and lambdacube-compiler finds the prelude in the installed place
- test local build with lambdacube-compiler and lambdacube-quake3
problem: lambdacube-compiler does not find prelude
solution: copy the prelude to lc
note: lambdacube-quake3 devs dont need this, only compiler+quake3 devs
----
- sky rendering
- fog rendering
- projectile rendering
- particle system support
- explosion
- smoke
- deferred rendering
- autosprite support
debug rendering:
- color bsp models
- draw brushes
- draw model's min/max box
- draw bsp leaf min/max box
- color surfaces (with same material)
- draw collision rays
game engine:
- level collision support (e.g. http://openzone.googlecode.com/git-history/f73bb8dfe8e6a16c13d39aba1c8f6537ee263d07/doc/Quake3BSP.html)
- ray, sphere, box collision with each other
required for e.g.: bullet - model, player - ammo collision
- collision for md3 models
- fix teleport collision
- implement q3 entity system
- items
- spawns
- generic entity collision shape (bsp inline model) trigger support
questions:
how does bsp surface and bsd inline model rendering work?
are the doors inline bsp models? yes. how are they moved? per object worldMat.
- character <-> item collision (e.g. ammo)
- fix collision with patches
- improve camera move
- swim in water
- optimize collision code, fix memory leak
- spectator camera
done - character camera with gravity and collision
- third person character camera
- attach weapon to character hand according tags
- animate items (e.g. ammos and armors)
done - level sounds
- simulate level actors (e.g. doors, jump pads)
quake sprint May 12-23:
- door opening/closing
- implement item entity handling (placement + spawn)
- implement item collision
- weapon and firing
- logic for items (e.g. armor, health, quad damage)
- generate collision geometry for bezier sufraces
networking: http://www.gdcvault.com/play/1022195/Physics-for-Game-Programmers-Networking
----
separate graphics and collision code
server side:
bsp load
md3 load
collision
entity handling - data for game rules
client side:
rendering
milestone 1:
client - server
spectator camera with collision
Renderer design problems:
- the whole storage needs to be loaded when new resource appears; this shoud be incremental
documentation:
http://wiki.ioquake3.org/Entities
http://fabiensanglard.net/quake3/
http://caia.swin.edu.au/reports/110209A/CAIA-TR-110209A.pdf