Fix culling bug
This commit is contained in:
parent
ff3830cb02
commit
dab40e47bc
5 changed files with 29 additions and 9 deletions
3
TODO.txt
3
TODO.txt
|
@ -1,5 +1,8 @@
|
|||
=========== GENERAL ==============
|
||||
|
||||
- culling is very slow now, it showed that distance bailout can accelerate it
|
||||
a lot, try to make a more accurate bailaout and see if it's faster (watch
|
||||
out for bugs due to false positives)
|
||||
- improve the car unstucking? maybe we can just keep the position of the car
|
||||
and ONE wheel (other joint positions can be computed)
|
||||
- some kind of special map block that would say where 3D triangles don't have
|
||||
|
|
29
data
29
data
|
@ -4,9 +4,28 @@
|
|||
#Btestmap;
|
||||
|
||||
#Maaaaa;4321 0
|
||||
:*B1vJ :!wct :!wcA
|
||||
:=n0s :fiba
|
||||
:xo1t :fgb8
|
||||
:*B2vJ
|
||||
|
||||
:]o1tI :fg11 :|o2tI :fg11
|
||||
:]o1A :fg11 :|o2A :fg11
|
||||
box
|
||||
:=n0s :fida
|
||||
:=n6s2 :fi1a
|
||||
:xo2t :fgm8
|
||||
|
||||
:^ocs2 :fg11 :vncs2L
|
||||
:^ocB2I :fg11 :vEcs2I
|
||||
:^nct2J :f118 :vncB2
|
||||
:^Ect2L :f118 :vEcB2J
|
||||
|
||||
:xo1w :fg12
|
||||
|
||||
ramps
|
||||
:]o2tI :fg11 :|o3tI :fg11
|
||||
:'o1uI :fg11
|
||||
:<o1vI :fg11
|
||||
|
||||
:]o2A :fg11 :|o3A :fg11
|
||||
:'o1z :fg11
|
||||
:<o1y :fg11
|
||||
|
||||
finish
|
||||
:!vdt :!vdA
|
||||
|
|
2
map.h
2
map.h
|
@ -800,9 +800,7 @@ void LCR_mapGetBlockShape(uint8_t blockType, uint8_t transform,
|
|||
case LCR_BLOCK_LEFT:
|
||||
case LCR_BLOCK_BOTTOM_LEFT:
|
||||
case LCR_BLOCK_BOTTOM_LEFT_FRONT:
|
||||
|
||||
case LCR_BLOCK_LEFT_FRONT:
|
||||
|
||||
case LCR_BLOCK_FULL_ACCEL:
|
||||
case LCR_BLOCK_FULL_FAN:
|
||||
case LCR_BLOCK_BOTTOM_ACCEL:
|
||||
|
|
2
racing.h
2
racing.h
|
@ -54,7 +54,7 @@ typedef int32_t LCR_GameUnit; ///< abstract game unit
|
|||
#include "tinyphysicsengine.h"
|
||||
|
||||
#define LCR_GRAVITY (LCR_PHYSICS_UNIT / 160)
|
||||
#define LCR_FAN_FORCE 3
|
||||
#define LCR_FAN_FORCE 4
|
||||
#define LCR_FAN_FORCE_DECREASE 6
|
||||
|
||||
#define LCR_CAR_FORWARD_FRICTION (TPE_F / 180)
|
||||
|
|
|
@ -594,7 +594,7 @@ uint8_t _LCR_rendererCheckMapTriCover(const S3L_Index *t1, const S3L_Index *t2)
|
|||
S3L_abs(vertices[0][0] - vertices[3][0]) +
|
||||
S3L_abs(vertices[0][1] - vertices[3][1]) +
|
||||
S3L_abs(vertices[0][2] - vertices[3][2]) >
|
||||
(3 * LCR_RENDERER_UNIT / 2))
|
||||
(3 * LCR_RENDERER_UNIT))
|
||||
return 0;
|
||||
|
||||
vertices[1] = LCR_renderer.mapVerts + 3 * t1[1];
|
||||
|
|
Loading…
Reference in a new issue