Darryl Pogue
70d037353f
Fix for timeval on OSX.
10 years ago
Michael Hansen
085c00706c
Some fixes for Clang
11 years ago
Michael Hansen
094b0fe557
Move <algorithm> header out of HeadSpin.h
11 years ago
Michael Hansen
751d760772
Use standard (f)abs functions
11 years ago
Michael Hansen
ce53a71990
There is no benefit to the hsFopen macro
11 years ago
Michael Hansen
1a987173d6
Use std::swap
11 years ago
Michael Hansen
72f18e8ebb
Complete the previous commit by also removing the inline min and max
...
functions defined in HeadSpin.h without breaking (3ds)Max compilation
11 years ago
Michael Hansen
e36220cca5
Use std::min and std::max
11 years ago
Michael Hansen
474b54396b
Reintroduce (and enforce use of) hsLockFor{Reading,Writing}
11 years ago
Michael Hansen
f83ec34c67
Move the old IPC-based semaphore to hsGlobalSemaphore, and provide a
...
"normal" (inter-thread only) semaphore class.
11 years ago
Michael Hansen
2947acb2c8
Replace hsMutex with std::mutex
11 years ago
Darryl Pogue
a0da984cdc
Work towards killing TimeGetMs.
...
Only remaining uses are in pnAsyncCore stuff, and I'm not touching that
until the std::thread merge is figured out.
11 years ago
Darryl Pogue
a3ae4201a2
Template-ize hsTimer return values.
11 years ago
Christian Walther
689941ba64
Modulate text shadow opacity by the alpha of the text color to make the player lists fade properly.
...
Also, the text of the faded-out player list is re-rendered with alpha == 0 every time the mouse enters its area, do a little less needless work in that case.
11 years ago
Adam Johnson
63af63574c
Revert "Fix dupe callbacks in VaultAddChildNode"
...
This reverts commit b393947cd5
.
The commit was seemingly harmless, but it created or otherwise uncovered
stack corruption deep inside the vault voodoo. While I would like to know
what was up, I'm tired of dealing with it. The crash addressed here was
fixed in a subsequent moul-scripts commit, so let's just toss this one.
11 years ago
Adam Johnson
f187d98a76
Revert "Fix inappropriate UnRefing in VaultCreateNodeTrans"
...
This reverts commit 8f8bad63f0
. It didn't do
what it claimed to.
11 years ago
Adam Johnson
8f8bad63f0
Fix inappropriate UnRefing in VaultCreateNodeTrans
11 years ago
Michael Hansen
d113642a61
Fix typo in non-Win32 logging code
11 years ago
Adam Johnson
b393947cd5
Fix dupe callbacks in VaultAddChildNode
...
This code called back into the python vault operation thingy, which
deletes itself. So, anytime we got dupe CBs, there was a use-after-free
error. Nasty crashes. I tightened up the CB management, threw away some
weird faux-management mess, and squashed some potential silent bugs.
11 years ago
Michael Hansen
aee2f7f7ca
Make hsRefCnt atomic, and merge with hsAtomicRefCnt
11 years ago
Michael Hansen
39867610a2
Fix leak check race condition, and remove an unintentional circular ref
11 years ago
Michael Hansen
403528a24b
Use hsRef for storage of the remaining vault nodes
11 years ago
Michael Hansen
8fa9171415
Also use hsRef for the vault functions which "return" lists
11 years ago
Michael Hansen
d2a05929f8
Replace most vault *IncRef() API functions with hsRef versions
11 years ago
Michael Hansen
aa2a1de5d0
Provide an easier/safer way to manage hsRefCnt subclasses
11 years ago
Adam Johnson
92a0da34a8
Fix invalid format string
11 years ago
Michael Hansen
b666637a5d
Fix debug crash due to ref miscounting
11 years ago
Michael Hansen
8b43d46ea5
Use moar stringstreams (where appropriate)
11 years ago
Michael Hansen
5c6b6bbc7c
Fix the rest of the plString::Format calls
11 years ago
Adam Johnson
dc9497cf90
Shutdown code de-duplication
11 years ago
Michael Hansen
3892a84f52
No need to duplicate this...
11 years ago
Michael Hansen
48ca0fde19
More plFormat -- some may make minor changes to certain debug output
...
(mostly regarding bools)
11 years ago
Michael Hansen
281f95638d
Better padding string generation
11 years ago
Michael Hansen
1debf8180b
Convert many of the now-deprecated plString::Format calls to plFormat
11 years ago
Michael Hansen
1a0420127c
Provide some plFormat samples with floats/doubles
11 years ago
Michael Hansen
933ae6ec17
Provide some sample conversions to plFormat for testing and copying
11 years ago
Adam Johnson
f2dee21063
Nuke std::wstring from plDynamicTextMsg
11 years ago
Michael Hansen
34b2eb1836
More std::atomic and friends
11 years ago
Michael Hansen
23a071860e
pnUtRef started at zero refs instead of one, and this is simpler
...
than finding and removing all the extra Ref() calls.
11 years ago
Michael Hansen
d713a13dbe
Merge pnUtRef with hsRefCnt, and remove the former
11 years ago
Michael Hansen
d4465a2168
Port plFontConverter to Qt5
11 years ago
Michael Hansen
e929708a3b
Use std::atomic_int for hsSafeRefCnt, and move it to hsRefCnt.h/cpp
11 years ago
Adam Johnson
bc76f4d760
Fix floating/exploding dynamic physicals
...
Only put dynamics to sleep if they're at the initial location. This
prevents baskets from exploding on touch by an avatar and should
theoretically make the doggone slave cave kickables activate the pressure
plates.
11 years ago
Adam Johnson
d4dbc81522
Fix another book-sharing message leak...
11 years ago
Adam Johnson
b3d6afc1c1
Can you say KABOOM?
...
The data is interleaved. If you randomly change it up, OpenAL *will* crash
on you...
11 years ago
Michael Hansen
07810ffd9c
Apparently these need to be at the top to work in a purely
...
command-line (msbuild) environment
11 years ago
Adam Johnson
f78deb37d3
Fix memory leak in Relto sharing
11 years ago
Adam Johnson
783f0e9eb1
Fix unlikely plStateDescriptor leak
11 years ago
Christian Walther
0c8fc6d559
Undo the kRenderJustXForceLeft bugfix of 4 commits back.
...
The fix (adding adjustment of fRenderInfo.fDestPtr) made kRenderJustXForceLeft behave as intended (left-aligning the edge of the bitmap rather than the side bearing of the first character) but cuts off shadows in some places (e.g. at the left edges of "BUDDIES" and "NEIGHBORS" in the mini KI). To ensure enough space for the shadow, and considering that all content was developed and visually optimized with the bug in place, it seems better to preserve the buggy behavior and make kRenderJustXForceLeft work exactly like kRenderJustXLeft.
11 years ago
Adam Johnson
1967178e37
Link shadowed text rendering to the plDynamicTextMap::kFontShadowed flag.
...
Conveniently enough, this existing but unimplemented flag is already set mostly the way we want it in the current PRPs.
11 years ago