Przeglądaj źródła

Runs again. Wrong SkeletalModels used?

Thomas Buck 10 lat temu
rodzic
commit
4061e9ff5e
3 zmienionych plików z 17 dodań i 3 usunięć
  1. 4
    0
      ChangeLog.md
  2. 5
    0
      TODO.md
  3. 8
    3
      src/SkeletalModel.cpp

+ 4
- 0
ChangeLog.md Wyświetl plik

2
 
2
 
3
 ## OpenRaider (0.1.3) xythobuz <xythobuz@xythobuz.de>
3
 ## OpenRaider (0.1.3) xythobuz <xythobuz@xythobuz.de>
4
 
4
 
5
+    [ 20140516 ]
6
+    * Finished moving the Entity/SkeletalModel logic into classes
7
+    * Currently seems as if wrong SkeletalModels are used for entities?
8
+
5
     [ 20140515 ]
9
     [ 20140515 ]
6
     * Slight cmake script improvements
10
     * Slight cmake script improvements
7
     * Created Entity class that will also get animation state
11
     * Created Entity class that will also get animation state

+ 5
- 0
TODO.md Wyświetl plik

17
 ## Changes
17
 ## Changes
18
 
18
 
19
 * Using std::vector with [] is not bound checked. Segfaults were caused because the upper bound of the argument was never checked and garbage was returned... Do consistent checks, or use .at() as it throws an exception
19
 * Using std::vector with [] is not bound checked. Segfaults were caused because the upper bound of the argument was never checked and garbage was returned... Do consistent checks, or use .at() as it throws an exception
20
+* Creating the Room class has introduced a bug that crashes when walking the level:
21
+
22
+    Assertion failed: (sector < (int)mRooms.at(room)->sizeSectors()), function isWall, file /Users/thomas/Projekte/OpenRaider/src/World.cpp, line 180.
23
+
24
+* The wrong SkeletalModels are used by other entities...?
20
 
25
 
21
 ## Cmake
26
 ## Cmake
22
 
27
 

+ 8
- 3
src/SkeletalModel.cpp Wyświetl plik

81
     tr2_moveable_t *moveable = tr.Moveable();
81
     tr2_moveable_t *moveable = tr.Moveable();
82
     tr2_item_t *item = tr.Item();
82
     tr2_item_t *item = tr.Item();
83
 
83
 
84
-    pos[0] = (short)*frame[*frame_offset + 6];
85
-    pos[1] = (short)*frame[*frame_offset + 7];
86
-    pos[2] = (short)*frame[*frame_offset + 8];
84
+    /*!
85
+     * \fixme Do we really need to keep frame and frame_offset
86
+     * at the top level, passing pointers?!
87
+     */
88
+
89
+    pos[0] = (short)((*frame)[(*frame_offset) + 6]);
90
+    pos[1] = (short)((*frame)[(*frame_offset) + 7]);
91
+    pos[2] = (short)((*frame)[(*frame_offset) + 8]);
87
 
92
 
88
     yaw = ((item[i].angle >> 14) & 0x03);
93
     yaw = ((item[i].angle >> 14) & 0x03);
89
     yaw *= 90;
94
     yaw *= 90;

Ładowanie…
Anuluj
Zapisz