Commit Graph

3513 Commits

Author SHA1 Message Date
helixhorned e4caa58cf2 Move DukePlayer_t's .palette down so that 2-byte-sized members are 2-byte-aligned.
Bump BYTEVERSION.

git-svn-id: https://svn.eduke32.com/eduke32@3363 1a8010ca-5511-0410-912e-c29ae57300e0
2013-01-02 22:33:22 +00:00
helixhorned 2528fd3bf5 player.c: factoring continued.
New local functions:
Proj_DoRandDecalSize, SectorContainsSE13, HandleHitWall, Proj_CheckBlood,
Proj_HandleKnee.

git-svn-id: https://svn.eduke32.com/eduke32@3362 1a8010ca-5511-0410-912e-c29ae57300e0
2013-01-01 15:24:42 +00:00
helixhorned 10feaeb5b4 player.c: cleanup. "ProjectileData[atwith]." --> "proj->", ...
The diff may look daunting, but it's clear what is changed with
git diff (...) --color-words='[a-zA-Z0-9_]+|[^[:space:]]' -b

git-svn-id: https://svn.eduke32.com/eduke32@3361 1a8010ca-5511-0410-912e-c29ae57300e0
2013-01-01 15:24:39 +00:00
helixhorned 552708103f player.c: finish hitscan projectile handling cleanup.
Factoring out 2x almost duplicated code into {P,A}_PostFireHitscan().

git-svn-id: https://svn.eduke32.com/eduke32@3360 1a8010ca-5511-0410-912e-c29ae57300e0
2013-01-01 15:24:36 +00:00
helixhorned f65f547fef player.c: hitscan projectile handling cleanup continued.
git-svn-id: https://svn.eduke32.com/eduke32@3359 1a8010ca-5511-0410-912e-c29ae57300e0
2013-01-01 15:24:33 +00:00
helixhorned 15b7444b46 player.c: factor out 2x almost dup'd code preparing hitscan weapon firing.
The code is duplicated with small changes for the hardcoded and custom
projectiles.
Adding local functions P_PreFireHitscan(), A_PreFireHitscan() and
Proj_MaybeAddSpread().

git-svn-id: https://svn.eduke32.com/eduke32@3358 1a8010ca-5511-0410-912e-c29ae57300e0
2013-01-01 15:24:31 +00:00
helixhorned eda5b22030 Lunatic: more code...
git-svn-id: https://svn.eduke32.com/eduke32@3357 1a8010ca-5511-0410-912e-c29ae57300e0
2013-01-01 15:24:28 +00:00
helixhorned a24ab8d4fa Factor out some code into C_AllocQuote() and C_InitQuotes().
In Lunatic-only build, also always allocate the first 128 quotes.

git-svn-id: https://svn.eduke32.com/eduke32@3356 1a8010ca-5511-0410-912e-c29ae57300e0
2013-01-01 15:24:25 +00:00
helixhorned 311967f425 Lunatic: definesound, more control.lua fixes.
git-svn-id: https://svn.eduke32.com/eduke32@3355 1a8010ca-5511-0410-912e-c29ae57300e0
2013-01-01 15:24:22 +00:00
helixhorned fd390efe2a Lunatic: compile out more code with LUNATIC_ONLY.
git-svn-id: https://svn.eduke32.com/eduke32@3354 1a8010ca-5511-0410-912e-c29ae57300e0
2013-01-01 15:24:18 +00:00
helixhorned 37d8cda701 Clean up actors.c and player.c.
git-svn-id: https://svn.eduke32.com/eduke32@3353 1a8010ca-5511-0410-912e-c29ae57300e0
2013-01-01 15:24:14 +00:00
helixhorned 25f6255d28 Lunatic: fix stack discipline.
Preventing a continuously growing stack top and inevitable program termination.
Also, commonize the error handling to live on the engine side.

git-svn-id: https://svn.eduke32.com/eduke32@3352 1a8010ca-5511-0410-912e-c29ae57300e0
2013-01-01 15:24:11 +00:00
Plagman b6fdabc21f Revert "Make synthesis use i686-w64-mingw32-gcc-4.7.2-release-linux64 + native NASM."
This reverts commit 53756fb79f.

git-svn-id: https://svn.eduke32.com/eduke32@3351 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-31 23:39:36 +00:00
terminx e0acee6356 Replace the osdcvar_t members that needed to be kept in sync with cvar_t with an actual cvar_t. If this is questionable for any reason I'm forgetting, feel free to revert!
git-svn-id: https://svn.eduke32.com/eduke32@3350 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-31 01:51:03 +00:00
terminx 5c74bc6f56 Surround "debug1" and "debug2" with #ifdef DEBUGGINGAIDS
git-svn-id: https://svn.eduke32.com/eduke32@3349 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-31 01:50:45 +00:00
Plagman 53756fb79f Make synthesis use i686-w64-mingw32-gcc-4.7.2-release-linux64 + native NASM.
If you see any weird behavior in synthesis builds after this change, please
let Plagman know!

git-svn-id: https://svn.eduke32.com/eduke32@3348 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-31 01:24:22 +00:00
terminx cbf9d2cff3 Clean up a couple of other getrendermode() related bits that the previous commit missed
git-svn-id: https://svn.eduke32.com/eduke32@3347 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-30 20:34:55 +00:00
terminx 79e45c23d5 Add predefined REND_CLASSIC, REND_POLYMOST and REND_POLYMER constants and use them everywhere getrendermode() is called.
git-svn-id: https://svn.eduke32.com/eduke32@3346 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-30 20:34:34 +00:00
helixhorned 5fc9bb9779 Lunatic: more glue, fixes, backtrace for code called back from C.
git-svn-id: https://svn.eduke32.com/eduke32@3345 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-29 15:21:32 +00:00
helixhorned 80f3e132b0 Replace "if (g_tile[..].execPtr)" -> "if (G_HaveActor(...))".
git-svn-id: https://svn.eduke32.com/eduke32@3344 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-29 15:21:28 +00:00
helixhorned 80ee967b8e Lunatic: beginning to glue things together. Introducing LUNATIC_ONLY.
git-svn-id: https://svn.eduke32.com/eduke32@3343 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-29 15:21:24 +00:00
helixhorned 4ad4f9ebb7 Remove commented code using former engine variable "automapping".
git-svn-id: https://svn.eduke32.com/eduke32@3342 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-29 15:21:20 +00:00
helixhorned 7d1879b777 Fix LTO=1 RELEASE=1 Lunatic build.
git-svn-id: https://svn.eduke32.com/eduke32@3341 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-29 15:21:16 +00:00
hendricks266 bf566e10a8 Rectify.
git-svn-id: https://svn.eduke32.com/eduke32@3340 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-29 11:27:07 +00:00
hendricks266 e19b944fd8 Fix SVN mime-types of binary files.
Windows batch file:
for /r %%G in (*.a) do svn propset svn:mime-type application/octet-stream "%%~G"
for /r %%G in (*.lib) do svn propset svn:mime-type application/octet-stream "%%~G"
for /r %%G in (*.dll) do svn propset svn:mime-type application/x-msdownload "%%~G"
for /r %%G in (*.ico) do svn propset svn:mime-type image/vnd.microsoft.icon "%%~G"
for /r %%G in (*.icns) do svn propset svn:mime-type image/icns "%%~G"
for /r %%G in (*.bmp) do svn propset svn:mime-type image/bmp "%%~G"
for /r %%G in (*.png) do svn propset svn:mime-type image/png "%%~G"
for /r %%G in (*.xcf) do svn propset svn:mime-type image/x-xcf "%%~G"
for /r %%G in (*.psd) do svn propset svn:mime-type image/vnd.adobe.photoshop "%%~G"
for /r %%G in (*.nib) do svn propset svn:mime-type application/octet-stream "%%~G"
for /r %%G in (*.map) do svn propset svn:mime-type application/octet-stream "%%~G"
svn propset -R svn:mime-type application/octet-stream polymer/eduke32/Apple/lib
svn propset -R svn:mime-type application/octet-stream polymer/eduke32/Windows/lib/32
svn propset -R svn:mime-type application/octet-stream polymer/eduke32/Windows/lib/64
svn propset -R svn:mime-type application/octet-stream polymer/eduke32/source/jaudiolib/third-party/Apple/lib
svn propset -R svn:mime-type application/octet-stream polymer/eduke32/source/jaudiolib/third-party/Windows/lib/32
svn propset -R svn:mime-type application/octet-stream polymer/eduke32/source/jaudiolib/third-party/Windows/lib/64


git-svn-id: https://svn.eduke32.com/eduke32@3339 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-29 11:07:43 +00:00
hendricks266 be03f29484 Clean up and factor jaudiolib.
git-svn-id: https://svn.eduke32.com/eduke32@3338 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-29 10:59:21 +00:00
hendricks266 b6ddc6149e Replace initialize_globals() with global initialization.
git-svn-id: https://svn.eduke32.com/eduke32@3337 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-29 10:58:38 +00:00
hendricks266 11e0897def Fix the gap between loops of ambient MUSICANDSFX sounds like BAR_MUSIC.
git-svn-id: https://svn.eduke32.com/eduke32@3336 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-29 10:58:09 +00:00
hendricks266 3933471e4b All kneel, king FLAC is here.
FLAC source from git commit 0920bc1ffb07f038b317e7e8056509fe0e4b680e, patched by me.

Windows libFLAC.a built using i686-MinGW-w64 and x86_64-MinGW-w64.

HUGE thanks to rhoenie for building the Mac fat library (ppc, i686, x86_86).

git-svn-id: https://svn.eduke32.com/eduke32@3335 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-29 10:57:24 +00:00
hendricks266 95dd57154e Clean up some file and directory structure.
* Renamed source/jaudiolib/third-party/mingw32 to source/jaudiolib/third-party/Windows.
* Moved source/jaudiolib/third-party/Windows/include to source/jaudiolib/third-party/common/include to use both on Windows and Apple.
* Deleted Apple/lib/include/{ogg,vorbis}/, see previous point.
* Deleted Apple/lib/libvorbisenc.a, 6MB saved.
* Moved Apple/lib/lib{ogg,vorbis,vorbisfile}.a to source/jaudiolib/third-party/Apple/lib, where they belong.
* Moved source files in Apple/ to source/, where they belong. (SDLMain.[mh] stay.)
* Deleted source/jaudiolib/third-party/{ogg,vorbis}.framework, not used any more.
* Renamed "StartupWinController*" to "startosx*".

git-svn-id: https://svn.eduke32.com/eduke32@3334 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-29 10:54:35 +00:00
terminx 8e61bff6f1 Bump DirectSound version to 8. This shouldn't really affect anything as the API is the same for all of the bits we make use of, but certain sets of DirectX headers/libs seem to be lacking v7 support.
git-svn-id: https://svn.eduke32.com/eduke32@3333 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-29 05:23:28 +00:00
terminx feaf4a7988 Remove FX_ASSVersion and related code since it wasn't used anywhere
git-svn-id: https://svn.eduke32.com/eduke32@3332 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-29 05:23:14 +00:00
terminx 61a8eaf666 Throw a compiler warning when building with only the null sound driver
git-svn-id: https://svn.eduke32.com/eduke32@3331 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-29 05:22:55 +00:00
terminx 0ae2d9ad60 Fix DirectSound in MSVC builds and remove the dependency on the DirectX SDK
git-svn-id: https://svn.eduke32.com/eduke32@3330 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-29 05:22:39 +00:00
helixhorned d970283582 DEF "voxel": fix a tile range check failure message.
git-svn-id: https://svn.eduke32.com/eduke32@3329 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-28 17:18:18 +00:00
helixhorned 9c328bf0a5 Encapsulate aplWeapon* array accesses in a PWEAPON(Player, Weapon, Wmember) macro.
In the normal game, these arrays are conceptually [MAX_WEAPONS][MAXPLAYERS],
allocated as CON per-player gamevars (e.g. WEAPONx_WORKSLIKE).
For Lunatic, they are replaced with
weapondata_t g_playerWeapon[MAXPLAYERS][MAX_WEAPONS].

git-svn-id: https://svn.eduke32.com/eduke32@3328 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-28 17:18:16 +00:00
helixhorned f1b1ce2cc3 Replace wall of dup'd code in Gv_AddSystemVars with something more readable.
Specifically, have a weapondata_t type mimicking the aplWeapon* arrays.
Keep a list weapondefaults[] which undergoes some static->dynamic tweaks
and then makes its way to the WEAPONx_XXX per-player gamevars.

git-svn-id: https://svn.eduke32.com/eduke32@3327 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-28 17:18:12 +00:00
helixhorned b30d00dd91 Replace initialize_engine_globals() with array initialization.
git-svn-id: https://svn.eduke32.com/eduke32@3326 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-28 17:18:09 +00:00
helixhorned 279a197e27 Lunatic translator: pack all translation units into one big blob.
git-svn-id: https://svn.eduke32.com/eduke32@3325 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-28 17:18:06 +00:00
helixhorned cc090a2ea8 Lunatic: sinking in code.
git-svn-id: https://svn.eduke32.com/eduke32@3324 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-28 17:18:02 +00:00
helixhorned d7cfde9d3d Make get{zs,ceilz,florz}ofslope (now ...ptr) accept sectortype pointer.
And rewrite the original functions as wrappers around these.

git-svn-id: https://svn.eduke32.com/eduke32@3323 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-28 17:17:58 +00:00
helixhorned 4f2639f4d7 Clean up spawning / actor initialization code.
git-svn-id: https://svn.eduke32.com/eduke32@3322 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-28 17:17:53 +00:00
helixhorned 0dd78fb029 Cleanup of console/on-screen-display (OSD) functionality.
- Rewrite the "clear background" routine in a no-brainer way instead of
  juggling around with rotatesprite(). Make it common to game+editor.
  Expose glRectd to glbuild.
- Don't stop OSD text line drawing when encountering a non-printable char.
  Instead, treat it as space.
- In OSD_SetTextMode(), don't use swaplong (which really swaps 32-bit ints)
  to swap pointers. Write an analogous "swapptr" instead.
- When changing from/to OSD, don't inject a pause key. This *might* have been
  the cause of the reported pausing problems.
- clean up the code...
(Yes, this commit throws together too much stuff. I suck sometimes. :P)

git-svn-id: https://svn.eduke32.com/eduke32@3321 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-25 16:13:50 +00:00
helixhorned fa2ac57674 Lunatic: event chaining.
git-svn-id: https://svn.eduke32.com/eduke32@3320 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-25 16:13:45 +00:00
helixhorned 41bfa1b841 Lunatic: print -> OSD_Printf, error reporting.
git-svn-id: https://svn.eduke32.com/eduke32@3319 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-25 16:13:41 +00:00
helixhorned 255c84c5a2 Clip printext256() at xdim, don't crash OSD_Printf() with empty string.
git-svn-id: https://svn.eduke32.com/eduke32@3318 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-25 16:13:36 +00:00
helixhorned 596b83aec1 Add a couple of test CONs: non-local control flow, rotation-fixed useractors.
git-svn-id: https://svn.eduke32.com/eduke32@3317 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-23 19:24:25 +00:00
helixhorned 6a4add81bd Fix rotation-fixed useractors (those having usertype bit 4 set).
Rotation-fixing happens for a couple of hard-coded statnums that presumably
never move (DEFAULT, STANDABLE, FX, FALLER, LIGHT), but for actors it wouldn't
make sense since the common case is that they do move. For this reason, bit 4
was introduced in r1934. The position of such useractors will not diverge
due to error roundoff accumulation in rotating sectors (SE0, train).

git-svn-id: https://svn.eduke32.com/eduke32@3316 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-23 19:24:21 +00:00
helixhorned 4ea9f799b1 Lunatic: more complete gameactor(), misc. translator tweaks.
git-svn-id: https://svn.eduke32.com/eduke32@3315 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-23 19:24:16 +00:00
helixhorned 48c47af5dc Pack actor_t's bposx/bposy/bposz members into a vec3_t named "bpos".
git-svn-id: https://svn.eduke32.com/eduke32@3314 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-23 14:00:08 +00:00