forked from mirrors/principia
Clean out some old notes in doc, move some Doxygen stuff
This commit is contained in:
parent
e4bb88b9d4
commit
22d7d57e37
6 changed files with 5 additions and 1452 deletions
4
.gitignore
vendored
4
.gitignore
vendored
|
|
@ -11,8 +11,8 @@ opengl32.dll
|
||||||
compile_commands.json
|
compile_commands.json
|
||||||
|
|
||||||
# Doxygen documentation
|
# Doxygen documentation
|
||||||
doc/doxy/
|
doxy/
|
||||||
doc/doxygen-awesome.css
|
doxygen-awesome.css
|
||||||
|
|
||||||
# Model junk files
|
# Model junk files
|
||||||
*.blend1
|
*.blend1
|
||||||
|
|
|
||||||
6
Doxyfile
6
Doxyfile
|
|
@ -14,7 +14,7 @@ BUILTIN_STL_SUPPORT = YES
|
||||||
# Input
|
# Input
|
||||||
RECURSIVE = YES
|
RECURSIVE = YES
|
||||||
STRIP_FROM_PATH = src
|
STRIP_FROM_PATH = src
|
||||||
INPUT = doc/main_page.dox \
|
INPUT = src/main_page.dox \
|
||||||
src/src/ src/tms/
|
src/src/ src/tms/
|
||||||
|
|
||||||
# Dot graphs
|
# Dot graphs
|
||||||
|
|
@ -26,7 +26,7 @@ DOT_MULTI_TARGETS = YES
|
||||||
DOT_IMAGE_FORMAT = svg
|
DOT_IMAGE_FORMAT = svg
|
||||||
|
|
||||||
# Output
|
# Output
|
||||||
OUTPUT_DIRECTORY = doc/doxy/ # /tmp/doxy/
|
OUTPUT_DIRECTORY = doxy/ # /tmp/doxy/
|
||||||
GENERATE_LATEX = NO
|
GENERATE_LATEX = NO
|
||||||
REFERENCED_BY_RELATION = YES
|
REFERENCED_BY_RELATION = YES
|
||||||
REFERENCES_RELATION = YES
|
REFERENCES_RELATION = YES
|
||||||
|
|
@ -35,4 +35,4 @@ DISABLE_INDEX = YES
|
||||||
GENERATE_TREEVIEW = YES
|
GENERATE_TREEVIEW = YES
|
||||||
HTML_DYNAMIC_SECTIONS = YES
|
HTML_DYNAMIC_SECTIONS = YES
|
||||||
HTML_TIMESTAMP = YES
|
HTML_TIMESTAMP = YES
|
||||||
HTML_EXTRA_STYLESHEET = doc/doxygen-awesome.css
|
HTML_EXTRA_STYLESHEET = doxygen-awesome.css
|
||||||
|
|
|
||||||
71
doc/banor
71
doc/banor
|
|
@ -1,71 +0,0 @@
|
||||||
|
|
||||||
Bana 1
|
|
||||||
Help the robot get to the goal!
|
|
||||||
Touch and drag the wooden plank to move it on the screen. Rotate the plank by dragging the small rotation icon next to it.
|
|
||||||
When you are happy with how you placed it, click the play button to try it out.
|
|
||||||
|
|
||||||
** .-##
|
|
||||||
-- ...'''--
|
|
||||||
--
|
|
||||||
|
|
||||||
Bana 2
|
|
||||||
Any object with a small blinking star above it can be moved. Two of the three wooden planks here can be moved.
|
|
||||||
|
|
||||||
**
|
|
||||||
--
|
|
||||||
|
|
||||||
ooooooo
|
|
||||||
o o ##
|
|
||||||
o o
|
|
||||||
------------
|
|
||||||
|
|
||||||
Bana 3
|
|
||||||
It's time to start building! Place the edge of one plank against another plank, a small hammer symbol will appear.
|
|
||||||
Click the hammer to nail the two planks together. To remove all nails from a plank, first select the plank by touching it
|
|
||||||
and then click on the second button in the bottom left corner of the screen.
|
|
||||||
Try to build something that allows the robot to reach the goal.
|
|
||||||
|
|
||||||
|
|
||||||
**
|
|
||||||
--
|
|
||||||
..--##
|
|
||||||
oooo''
|
|
||||||
o o
|
|
||||||
o o
|
|
||||||
o o
|
|
||||||
o o
|
|
||||||
---------------------
|
|
||||||
|
|
||||||
Bana 5
|
|
||||||
Well look what we have here, a door is blocking the robot's path! There seems to be some kind of suspicious button
|
|
||||||
hooked up to the door's security system, maybe you should try to make an object press it.
|
|
||||||
|
|
||||||
___o/
|
|
||||||
| /
|
|
||||||
+]
|
|
||||||
o---------
|
|
||||||
|- /
|
|
||||||
| / ___
|
|
||||||
** | / [???]
|
|
||||||
------------##-
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
OOOOO.,.,.,.,.,.X
|
|
||||||
O
|
|
||||||
o O
|
|
||||||
ooooo
|
|
||||||
x------
|
|
||||||
|
|
||||||
|
|
@ -1,57 +0,0 @@
|
||||||
All highscore data is stored in the impregnable data.bin.
|
|
||||||
|
|
||||||
When we submit highscores to the server, we submit the data.bin file directly.
|
|
||||||
|
|
||||||
However, it's possible to cheat by modifying the memory where the score number is located before submitting your score.
|
|
||||||
|
|
||||||
**SCORE SUBMISSIONS NEED TO BE DISABLED FOR STATE LOADS!!!!!!!**
|
|
||||||
|
|
||||||
To circumvent this, we will store extra verification numbers that are modified at the same time as ```G->state.score```.
|
|
||||||
|
|
||||||
``G->state.score`` should therefore never be updated directly, but should use the helper function we will create in game,
|
|
||||||
``G->set_score(int new_score)``, ``int G->get_score()``, ``bool G->verify_score()``, ``G->add_score(int score_mod)``.
|
|
||||||
|
|
||||||
In addition to this, we should insert some data into data.bin before we submit it.
|
|
||||||
|
|
||||||
What we need is:
|
|
||||||
* crc32 of the level buf (so the level hasn't been modified)
|
|
||||||
* revision of level
|
|
||||||
* local timestamp
|
|
||||||
|
|
||||||
So, how do we store this data?
|
|
||||||
We push it into some fake position of data.bin.
|
|
||||||
```c++
|
|
||||||
int base_fake_id = 1402
|
|
||||||
forward = 1
|
|
||||||
backwards = -1
|
|
||||||
int dir = forward
|
|
||||||
switch (community_id % 5) {
|
|
||||||
case 0:
|
|
||||||
fake_level_id = base_fake_id + 4
|
|
||||||
dir = forward
|
|
||||||
|
|
||||||
case 1:
|
|
||||||
fake_level_id = base_fake_id
|
|
||||||
dir = forward
|
|
||||||
|
|
||||||
case 2:
|
|
||||||
fake_level_id = base_fake_id + 1
|
|
||||||
dir = backwards
|
|
||||||
|
|
||||||
case 3:
|
|
||||||
fake_level_id = base_fake_id + 1
|
|
||||||
dir = forward
|
|
||||||
|
|
||||||
case 4:
|
|
||||||
fake_level_id = base_fake_id + 6
|
|
||||||
dir = backwards
|
|
||||||
}
|
|
||||||
|
|
||||||
char crcdata[32] = crc32(level.buf + level.name + level.revision + local_timestamp);
|
|
||||||
for (int x=0; x<32; ++x) {
|
|
||||||
progress[fake_level_id+(x*dir)].top_score = crcdata[x];
|
|
||||||
}
|
|
||||||
|
|
||||||
progress[fake_level_id-3].last_score = level.revision
|
|
||||||
progress[fake_level_id+4].last_score = local_timestamp
|
|
||||||
```
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue