Commit 459c393
committed
UPBGE: Refactor scene suspended time managment.
Previously when a scene was suspended, the function UpdateSuspendedScenes
was checking that the suspended scene has a valid suspended time, this
value is the clock time when the scene was suspended. If this value was
to zero it was set.
After, when the scene was resumed, the same function checked if the
suspended time was not zero, in this case the scene was just resumed, the
delta suspended time (the time passed during the scene suspend) wad set
and the suspended time was set to zero.
This mechanism is to complicated for the informations we need, indeed
only the suspended delta time is used for animations. This delta time
could be incremented each frame by the frame step.
So the suspended time of a scene is removed and UpdateSuspendedScenes get
as argument the frame step which is incremented to the scene suspended
delta time.
Tested with #D1569.1 parent a09fbbb commit 459c393
File tree
5 files changed
+14
-59
lines changed- source/gameengine/Ketsji
5 files changed
+14
-59
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
246 | 246 | | |
247 | 247 | | |
248 | 248 | | |
249 | | - | |
| 249 | + | |
250 | 250 | | |
251 | 251 | | |
252 | 252 | | |
| |||
379 | 379 | | |
380 | 380 | | |
381 | 381 | | |
382 | | - | |
| 382 | + | |
| 383 | + | |
383 | 384 | | |
384 | 385 | | |
385 | 386 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
102 | 102 | | |
103 | 103 | | |
104 | 104 | | |
105 | | - | |
106 | | - | |
107 | 105 | | |
108 | 106 | | |
109 | 107 | | |
| |||
480 | 478 | | |
481 | 479 | | |
482 | 480 | | |
483 | | - | |
| 481 | + | |
484 | 482 | | |
485 | 483 | | |
486 | 484 | | |
| |||
493 | 491 | | |
494 | 492 | | |
495 | 493 | | |
496 | | - | |
| 494 | + | |
497 | 495 | | |
498 | 496 | | |
499 | 497 | | |
500 | 498 | | |
501 | | - | |
502 | | - | |
503 | | - | |
504 | | - | |
505 | | - | |
506 | | - | |
507 | | - | |
508 | | - | |
509 | | - | |
510 | | - | |
| 499 | + | |
511 | 500 | | |
512 | 501 | | |
513 | 502 | | |
| |||
800 | 789 | | |
801 | 790 | | |
802 | 791 | | |
803 | | - | |
804 | | - | |
805 | 792 | | |
806 | 793 | | |
807 | 794 | | |
| |||
1489 | 1476 | | |
1490 | 1477 | | |
1491 | 1478 | | |
1492 | | - | |
1493 | | - | |
1494 | | - | |
1495 | | - | |
1496 | | - | |
1497 | 1479 | | |
1498 | 1480 | | |
1499 | 1481 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
139 | 139 | | |
140 | 140 | | |
141 | 141 | | |
142 | | - | |
143 | | - | |
144 | | - | |
145 | 142 | | |
146 | 143 | | |
147 | 144 | | |
| |||
221 | 218 | | |
222 | 219 | | |
223 | 220 | | |
224 | | - | |
| 221 | + | |
225 | 222 | | |
226 | | - | |
| 223 | + | |
227 | 224 | | |
228 | 225 | | |
229 | 226 | | |
| |||
361 | 358 | | |
362 | 359 | | |
363 | 360 | | |
364 | | - | |
365 | | - | |
366 | | - | |
367 | | - | |
368 | | - | |
369 | | - | |
370 | 361 | | |
371 | 362 | | |
372 | 363 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
151 | 151 | | |
152 | 152 | | |
153 | 153 | | |
| 154 | + | |
154 | 155 | | |
155 | 156 | | |
156 | 157 | | |
157 | 158 | | |
158 | | - | |
159 | | - | |
160 | 159 | | |
161 | 160 | | |
162 | 161 | | |
| |||
1817 | 1816 | | |
1818 | 1817 | | |
1819 | 1818 | | |
1820 | | - | |
1821 | | - | |
1822 | | - | |
1823 | | - | |
1824 | | - | |
1825 | | - | |
1826 | | - | |
1827 | | - | |
1828 | | - | |
| 1819 | + | |
1829 | 1820 | | |
1830 | 1821 | | |
1831 | 1822 | | |
1832 | | - | |
| 1823 | + | |
1833 | 1824 | | |
1834 | 1825 | | |
1835 | 1826 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
248 | 248 | | |
249 | 249 | | |
250 | 250 | | |
| 251 | + | |
251 | 252 | | |
252 | 253 | | |
253 | 254 | | |
| |||
287 | 288 | | |
288 | 289 | | |
289 | 290 | | |
290 | | - | |
291 | | - | |
292 | | - | |
293 | 291 | | |
294 | 292 | | |
295 | 293 | | |
| |||
596 | 594 | | |
597 | 595 | | |
598 | 596 | | |
599 | | - | |
600 | | - | |
601 | | - | |
602 | | - | |
603 | | - | |
604 | | - | |
605 | | - | |
606 | | - | |
607 | 597 | | |
608 | 598 | | |
609 | 599 | | |
610 | 600 | | |
611 | | - | |
| 601 | + | |
612 | 602 | | |
613 | 603 | | |
614 | 604 | | |
615 | 605 | | |
616 | | - | |
| 606 | + | |
617 | 607 | | |
618 | 608 | | |
619 | 609 | | |
| |||
0 commit comments