Commit Graph

5841 Commits (b1292a3421876416bf9d317391268215dfdad0f2)
 

Author SHA1 Message Date
Tobias Zwick f5592a49e6 build fix 2013-12-08 04:05:56 +07:00
Tobias Zwick 4f416c3147 replace global function GetTime() with class function C4TimeMilliseconds::Now() 2013-12-07 21:28:06 +07:00
Tobias Zwick fe2a400c02 replace global function GetTime() with class function C4TimeMilliseconds::Now() 2013-12-07 21:27:01 +07:00
Tobias Zwick 3c4ba7f494 do not lazy-initialize C4GUI::tLastChange time 2013-12-07 14:04:35 +07:00
Tobias Zwick 44f1887003 split up Plants library into crop (harvestable), tree (choppable) and plant (plant reproduction)
This should make the plants not overloaded with functionality so that odd stuff like #904 can happen. I think the plants need more cleanup still.
2013-12-05 11:23:22 +07:00
Tobias Zwick 95c3b0b75a fix scrollbar drawing and remove code duplication (#1004) 2013-12-05 10:40:17 +07:00
Tobias Zwick a54eed6b9b add name to One Million Particles so it can be found from ingame gui 2013-12-05 10:39:45 +07:00
Tobias Zwick 9ffad10d51 add note to documentation of FinishCommand (#390) 2013-12-05 10:39:26 +07:00
Julius Michaelis ebff82641c Linux build fix for Newton 2013-12-04 19:19:33 +01:00
Tobias Zwick 554deb5273 fix zoom is reset on resizing the viewport (#881) 2013-12-04 23:36:27 +07:00
Tobias Zwick 57fb0b48ca fix: on response from masterserver, also check if CSID reply is empty (#703) 2013-12-04 20:59:53 +07:00
Tobias Zwick 3e5268ab19 buildfix for linux (missed out on a Linux-specific StdSchedulerProc) 2013-12-04 20:47:12 +07:00
Tobias Zwick 94c618d153 add new type C4TimeMilliseconds for time measurements to solve problems when GetTime() overflows (#251)
The new type C4TimeMilliseconds behaves for the most part like a uint32_t but is overflow-proof in comparisons.
In some places, a 0-value (or uint_max) of the variable storing the time had the special meaning "not set yet". This has been resolved by having it as a pointer to C4TimeMilliseconds with NULL meaning that it has not been set yet.
2013-12-04 19:35:07 +07:00
Tobias Zwick c03effd104 fix possible bug: pPeer->GetTimeOut() already includes GetTime() + some offset, adding GetTime() another time here is wrong. 2013-12-04 14:35:17 +07:00
Tobias Zwick a8a8322dfb use %u to format unsigned ints (times) 2013-12-04 12:51:46 +07:00
Tobias Zwick 7de660ba79 fix possible bug: respect iMaxTime parameter in C4NetIOUDP::Execute 2013-12-04 12:46:07 +07:00
Tobias Zwick 6116b0079c fix link to Map scripts in documentation index 2013-12-03 12:49:47 +07:00
David Dormagen c57929508a dynamic particles: possibly fixed a theoretical crash when creating particles
(race condition between initializing the particle and executing the particle calculation/removing the particle)
2013-12-02 20:05:45 +01:00
David Dormagen 0a69450d12 dynamic particles: log missing-glPRI-warning only to log file and not player-visible output
The warning is nothing that should bother the average player (mainly because they possibly can't do anything against it anyway). However, it might turn out to be useful for debugging purposes.
2013-12-02 19:39:29 +01:00
David Dormagen 3c34857c0f added particle test scenario that spawns a million particles (and heavy effects afterwards)
The honorable goal of the particle system should be that this scenario always runs fluently. Even though optimizing the drawing will not be possible after a certain point, the particle system should scale down the drawing automatically to allow for a fluent game.
2013-12-01 23:50:54 +01:00
Sven Eberhardt f75424ef6c Fix network 2013-12-01 18:14:20 +01:00
Sven Eberhardt 6407c7cd2b Some more fixes for time_t change.
Some format strings had to be adjusted and clients always had ping timeout on join. Let's hope this fixes it.
2013-12-01 16:34:47 +01:00
Nicolas Hake c3f021cc5b dodocs: Fix another incorrect closing tag 2013-12-01 16:18:34 +01:00
Nicolas Hake 78139a9107 docs: Fix incorrect closing tag 2013-12-01 15:21:35 +01:00
Sven Eberhardt 21d05fa97f Build fix for 32bit Windows autobuilds (I hope).
Note that the code is still broken if timeGetTime() overflows while the engine is running (related to issue #251).
2013-12-01 14:49:06 +01:00
Nicolas Hake 77b1da5238 mape: Update StartSoundEffectAt dummy
ceca8b8 changed the signature of StartSoundEffectAt, but didn't update
mape's dummy function.
2013-12-01 13:13:56 +01:00
Nicolas Hake 15fcd8c51d Add missing <time.h> include 2013-12-01 13:09:39 +01:00
David Dormagen 3351ccd9d5 dynamic particles: correctly check for the absence of glPrimitiveRestartIndex 2013-11-30 13:43:46 +01:00
David Dormagen 7ede55eeee improved the aesthetics of the lightning strike's particle effect 2013-11-30 13:43:46 +01:00
Tobias Zwick e9853dc493 don't display the death message on graves if the message is empty (#896) 2013-11-30 14:42:52 +07:00
Tobias Zwick 17ab2c53a3 update documentation around DefCore, remove some obsolete fields (2) 2013-11-30 14:15:42 +07:00
Tobias Zwick 666a51b3d9 update documentation around DefCore, remove some obsolete fields 2013-11-30 14:14:18 +07:00
Tobias Zwick 5bee448745 update documentation around ActMap (2) 2013-11-30 13:11:36 +07:00
Tobias Zwick 932853d1d8 update documentation around ActMap 2013-11-30 11:45:31 +07:00
David Dormagen 764171d1d8 dynamic particles: reserve keyframes vector memory before assigning (for performance) and minor code cleanups 2013-11-30 01:11:06 +01:00
David Dormagen bc6daaea22 dynamic particles: retain old model-view matrix (fixes weird effects under certain situations - some code seems to rely on the current matrix being the identity) 2013-11-29 23:05:49 +01:00
David Dormagen b0bc2d627f implemented fallback for particle drawing in case glPrimitiveRestartIndex is not supported (#995) 2013-11-29 22:43:36 +01:00
Tobias Zwick b4732f50c3 document properties of definitions, mark the ones missing yet in the source file 2013-11-30 00:39:29 +07:00
Tobias Zwick 133628c656 link the MapScript documentation in the index 2013-11-30 00:38:02 +07:00
Tobias Zwick e10f7abe1b add a fadeout sound for the earthquake (#884) 2013-11-29 21:48:09 +07:00
Tobias Zwick 009e08edd1 Document the default planes of the categories 2013-11-29 21:07:30 +07:00
Tobias Zwick 270f0406d8 make invaluable materials be displayed behind more important stuff (#990)
In detail: Invaluable materials (450), normal materials (460), valuable materials and processed materials (470), processed valuable materials like ruby, gold (480), all other items (default: 500), ... explosives (530)
2013-11-29 21:07:29 +07:00
Nicolas Hake 52fd2679cd Fix line endings broken by ecf538c, 7b9c1d5, and ceca8b8 2013-11-29 14:18:48 +01:00
Tobias Zwick ceca8b8fc7 add SoundAt function in C4Script (part of #238), document
also, extend the documentation for Sound with previously undocumented parameters; threw out undocumented and also unused "multiple" parameter.
2013-11-29 18:20:36 +07:00
Tobias Zwick 7b9c1d5a9e refactor: consistently use time_t t... variables for times in network system, scheduler, gui
The network used to cast GetTime() to int, but GetTime() is an unsigned long. This might cause problems if GetTime() returns big integers (see #251). To solve this, the StdSchedulerProc interface had to be extended with another function in order to eliminate the magic return value -1 of GetNextTick for "no scheduled execution".
2013-11-29 17:28:04 +07:00
Tobias Zwick ecf538cd1f refactor: consistently use time_t t... variables for times in sound system, stats, application and player controls 2013-11-29 14:16:14 +07:00
David Dormagen 30619ae7fd removed unused particle definitions & cleaned up Particle.txt of LightningBolt particle 2013-11-28 23:44:24 +01:00
David Dormagen 54fdb2cec1 updated some remainers of the old particle system to use the new one 2013-11-28 23:38:26 +01:00
David Dormagen 8461fb9822 changed dynamite/dynamite box/powder keg fuse effect to use the new particle system 2013-11-28 23:29:25 +01:00
David Dormagen 0b346d67ff made pretty fireworks (with new particle system) 2013-11-28 23:28:33 +01:00