Commit Graph

2205 Commits

Author SHA1 Message Date
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 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
helixhorned d975a6a24f Fix build.lua's loadarts(), add bigytiles.lua.
git-svn-id: https://svn.eduke32.com/eduke32@3312 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-23 14:00:00 +00:00
helixhorned 518ac7b4df Mapster32: in 3D mode's tile info, highlight members of swapped bottom walls.
- If aiming at a swapped bottom wall, display "Wall <wallnum> -> <otherwallnum>"
- highlight pic, shade, pal, cstat in yellow then
- in printext256, accept at most 3 digits for the color format string (e.g. ^123)

git-svn-id: https://svn.eduke32.com/eduke32@3308 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-20 12:04:39 +00:00
helixhorned 192e863dd6 Mapster32: when pasting single wall, take over bits 4, 1+64 and 8+256.
That is, everything concerning orientation. Previously, it was wrongly
the bitwise NOT of these bits that got taken over. In particular, if bit
2 (swap bottom walls) would get pasted, ridiculousness could ensue.

git-svn-id: https://svn.eduke32.com/eduke32@3306 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-18 22:40:49 +00:00
helixhorned 5bda3a6ebf Don't enable fog in polymost_printext256() and when drawing tile view in M32.
The new "r_usenewshading 2" mode could darken these otherwise.

git-svn-id: https://svn.eduke32.com/eduke32@3302 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-16 19:18:13 +00:00
helixhorned 922aa3ca8b Classic-like visibility/fog for OpenGL modes, r_usenewshading 2 (new default).
Implemented using GL_LINEAR fog. The only source of difference (besides the
obvious indexed vs. true color) should now be the distance constant, which
still had to be determined experimentally.  Polymer implements this mode in
its fog fragment program part.

Parallaxed skies are always drawn with full visibility, I'm not sure if there
are any maps that expect otherwise.

Also, accidentally committed: factor out initialization code from
polymost_printext256() into gen_font_glyph_tex(), small game.c changes.

git-svn-id: https://svn.eduke32.com/eduke32@3301 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-16 19:18:10 +00:00
helixhorned 441e2ed220 Fix savegame loading. Bump BYTEVERSION.
git-svn-id: https://svn.eduke32.com/eduke32@3295 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-15 11:28:56 +00:00
hendricks266 54e0fc260c Replace the scrolling contributor credits with a static programmatic three-column layout.
git-svn-id: https://svn.eduke32.com/eduke32@3294 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-14 23:11:26 +00:00
helixhorned 243bea66dd Mapster32: correct message when changing shade by small steps ([+], [-], mwheel)
git-svn-id: https://svn.eduke32.com/eduke32@3289 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-14 19:28:11 +00:00
helixhorned 92dabb3694 Rename global visibility to g_visibility, remove useless casts & old fog code.
git-svn-id: https://svn.eduke32.com/eduke32@3287 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-14 19:28:05 +00:00
helixhorned 65e5ebcdbc Add command line option "-rotatesprite-no-widescreen".
This global option will set bit 1024 and clear bits 256 and 512 for all
rotatesprite calls, fixing complex HUD drawing code relying on precise
alignment of individual elements (widescreen rotatesprite is entirely
unsuitable for this purpose).

git-svn-id: https://svn.eduke32.com/eduke32@3284 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-14 19:27:55 +00:00
terminx ba8d1a5c1e Change a few paths in various MSVC Makefiles to better suit my current dev environment. This doesn't really affect anyone else since these paths need to be customized to fit whatever machine by anyone building with MSVC anyway.
git-svn-id: https://svn.eduke32.com/eduke32@3282 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-14 17:13:17 +00:00
helixhorned 049e63d7f3 Mapster32: In 3D mode, [,] auto-aligns walls to the left.
git-svn-id: https://svn.eduke32.com/eduke32@3281 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-13 22:21:22 +00:00
hendricks266 dac94ce284 Win64 support! (Meaning it works, not that we recommend it for everyday use.)
This includes a complete Windows header and library refresh, including the addition of 64-bit compiled libs:
*libogg 1.3.0
*libvorbis 1.3.3
*zlib 1.2.7
*libpng 1.5.13
*libvpx 9a3de881c0e681ba1a79a166a86308bbc84b4acd
*SDL_mixer 1.2.12 (for RENDERTYPE=SDL)
*DirectX import libraries: dsound and dxguid (now included)

To build in 64-bit, you essentially need MinGW's MSYS (but not MinGW itself) and MinGW-w64 at the top of your PATH. The target is automatically detected using `$(CC) -dumpmachine`. The EDukeWiki will get detailed instrucitons.

All compiler and linker warnings when building in 64-bit mode have been fixed.

Remaining 64-bit to-do:
 - The ebacktrace dll does not build under 64-bit. It uses code specific to the format of 32-bit executables and will have to be ported to work with 64-bit executables. A future 64-bit version will be named ebacktrace1-64.dll.
 - RENDERTYPE=SDL crashes in SDL_mixer's Mix_Linked_Version().
 - DirectInput gives an error and does not function. This only affects joysticks, and the error never happens without any plugged in.
 - Port the classic renderer ASM to 64-bit. (Just kidding, this is way out of my league.)

This commit includes a fair bit of Makefile development spanning all platforms, including simplifying the SDLCONFIG code, fixing build on Mac OS X (thanks rhoenie!), globally factoring Apple brew/port inclusion, enforcing that all -L come before all -l, and ensuring that $(shell ) is always :='d.

In addition, I have resurrected the old GCC_MAJOR and GCC_MINOR detection using `$(CC) -dumpversion`, but I have made it failsafe in case the command fails or the version is manually specified. I have applied this new fine-grained detection where applicable, including allowing LTO, and restraining -W's to versions that support them.

git-svn-id: https://svn.eduke32.com/eduke32@3278 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-13 02:37:20 +00:00
hendricks266 70aecb2e75 Fix declaration-after-statement warning in game.c after r3270.
git-svn-id: https://svn.eduke32.com/eduke32@3277 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-13 02:35:06 +00:00
hendricks266 2f8dbd94c3 Update credits.
git-svn-id: https://svn.eduke32.com/eduke32@3276 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-13 02:34:49 +00:00
hendricks266 9fcba228b1 Build tweaks:
Set up the use of {Windows,Apple}/{include,lib} regardless of feature toggles in Makefile.common using $(abspath ) in reference to the directory Makefile.common is in.
Add the three DirectX headers that are actually used to the repo. (from: http://alleg.sourceforge.net/files/dx9mgw.zip)
Since current MinGW versions include DirectX libs (for dynamic linking), remove "-L$(DXROOT)/lib".
The DirectX headers are no longer a separate dependency for building.
Add $(SDLROOT_OVERRIDE). $(SDLROOT) only functions for Windows and Mac OS X.
Factor handling of $(DXROOT_OVERRIDE) and $(SDLROOT_OVERRIDE) into Makefile.shared using $(abspath ).

git-svn-id: https://svn.eduke32.com/eduke32@3275 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-13 02:34:30 +00:00
hendricks266 6f2fa332dd Port system gamearray access from M32Script to CON. Expose tilesizx and tilesizy.
Also, fix deficient logic in Gv_Free and Gv_Clear (both M32 and CON) so that gamevar and gamearray erasure results are (closer to) correct, and so that the game does not crash when system arrays are accessed from CON because they all have been nulled.

git-svn-id: https://svn.eduke32.com/eduke32@3274 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-13 02:33:53 +00:00
hendricks266 a2f585fcfb jaudiolib: Modify OGG looping code to support the LOOP_LENGTH tag (where internally LOOP_START + LOOP_LENGTH = LOOP_END), and all three tags without the underscore.
As a note, libvorbis' vorbis_comment_query() checks for tags case-insensitively.

(This was done to support the output of vgmstream's "test.exe -g".)

git-svn-id: https://svn.eduke32.com/eduke32@3273 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-13 02:33:23 +00:00
terminx 977764e57a Fix building as C instead of C++
git-svn-id: https://svn.eduke32.com/eduke32@3271 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-12 02:53:15 +00:00
terminx fbdbca2952 Networking patch from Jasper Foreman
git-svn-id: https://svn.eduke32.com/eduke32@3270 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-12 02:53:13 +00:00
terminx 5c59f785a1 Recognize the .pk4 file extension when loading grps and zips for shits and giggles (.pk3 was already recognized).
git-svn-id: https://svn.eduke32.com/eduke32@3269 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-12 02:53:10 +00:00
terminx 1c3f31b099 Move the definitions like MAXGAMEVARS out of the enums used for the gamevar flags, because it didn't really make a whole lot of sense for them to be there.
git-svn-id: https://svn.eduke32.com/eduke32@3268 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-12 02:53:08 +00:00
terminx 5d031ec257 Replace the separate full Gv_AddVar/SubVar/etc functions with a macro that generates them since they were all the same anyway (other than the operator, obviously)
git-svn-id: https://svn.eduke32.com/eduke32@3267 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-12 02:53:05 +00:00
helixhorned 9d2260c3c8 Replace outer apScriptGameEvent[...] checks with G_HaveEvent().
git-svn-id: https://svn.eduke32.com/eduke32@3266 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-10 18:17:57 +00:00
helixhorned 99f56fd295 Don't call setaspect_new() at end of rotatesprite.
This fixes 2nd and following rotatesprite calls drawing differently from
the first in a context with custom set-up aspect, as reported by Lezing here:
http://forums.duke4.net/topic/775-eduke32-20-and-polymer/page__view__findpost__p__143090

Also, back up and restore the aspect state across EVENT_DISPLAYREST.

git-svn-id: https://svn.eduke32.com/eduke32@3265 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-10 18:17:53 +00:00
helixhorned 10ae7e342c CON: proper bound checks for {re,}definequote commands.
git-svn-id: https://svn.eduke32.com/eduke32@3262 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-09 13:42:38 +00:00
helixhorned f2a9af0bae Rearrange {net,}actor_t for 4-byte alignment of int32_t members.
Bump BYTEVERSION.

git-svn-id: https://svn.eduke32.com/eduke32@3261 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-09 13:24:46 +00:00
helixhorned fc048658dc Experimental NETCODE Makefile variable, enabled by default.
Disabling netcode compilation can be interesting on memory-constrained
systems, or those that have no means of accessing the network anyway.
Note: I'm OK with maintaining this myself, i.e. it's fine if netcode dev
breaks compilation with NETCODE=0.

git-svn-id: https://svn.eduke32.com/eduke32@3260 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-09 13:24:44 +00:00
helixhorned 1588a80442 Lunatic: drowning in code.
git-svn-id: https://svn.eduke32.com/eduke32@3259 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-09 13:24:39 +00:00
helixhorned 5c06ef08bf Make EventNames[] an array of (const char *) instead of const tokenlist.
git-svn-id: https://svn.eduke32.com/eduke32@3258 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-09 13:24:36 +00:00
helixhorned 599d9232f1 Initialize BADGUY sprite flags for hardcoded enemies.
... instead of switch/case-ing them in A_CheckEnemyTile().
Because this requires bumping BYTEVERSION, we also get rid of the
excess trailing bytes in the save game's "rest" data. (See r3052.)

git-svn-id: https://svn.eduke32.com/eduke32@3257 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-09 13:24:32 +00:00
helixhorned 541fca6dac Lunatic: gasping for some air.
That is, fix some oversights introduced in the preceding runs.
listglobals.sh is a helper to find global accesses.
Translator: add "number-conversion" warning option, max. error limit.

git-svn-id: https://svn.eduke32.com/eduke32@3256 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-09 13:24:28 +00:00
helixhorned 2212e4e6f8 Lunatic translator: warning options, on_state_end, more bad-identifier chars.
git-svn-id: https://svn.eduke32.com/eduke32@3255 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-03 18:24:33 +00:00
helixhorned 99c67c0190 Lunatic: submerging in code.
git-svn-id: https://svn.eduke32.com/eduke32@3254 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-03 18:24:30 +00:00
helixhorned b062d5f572 Lunatic: knee-deep in code.
- more codegen
- make more members const, some char unsigned
- fix some "geom" metamethods
- '^' operator

git-svn-id: https://svn.eduke32.com/eduke32@3253 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-03 18:24:25 +00:00
helixhorned 2bcf8aa8ec gameexec.c: rip out some inline code into VM_Fall() and VM_ResetPlayer().
git-svn-id: https://svn.eduke32.com/eduke32@3252 1a8010ca-5511-0410-912e-c29ae57300e0
2012-12-03 18:24:20 +00:00
helixhorned 76b970e547 Lunatic: implement the non-local control flow needed for some commands.
git-svn-id: https://svn.eduke32.com/eduke32@3250 1a8010ca-5511-0410-912e-c29ae57300e0
2012-11-30 18:57:59 +00:00
helixhorned 5b07f67627 Lunatic: player stuff (protect some members etc.)
git-svn-id: https://svn.eduke32.com/eduke32@3249 1a8010ca-5511-0410-912e-c29ae57300e0
2012-11-30 18:57:55 +00:00
helixhorned b850d04f8d Lunatic: Makefile tweaks, protect sprite[].picnum.
git-svn-id: https://svn.eduke32.com/eduke32@3248 1a8010ca-5511-0410-912e-c29ae57300e0
2012-11-30 18:57:50 +00:00
helixhorned 354a1a70ef Lunatic: expose more stuff, more codegen (the easy ones).
git-svn-id: https://svn.eduke32.com/eduke32@3247 1a8010ca-5511-0410-912e-c29ae57300e0
2012-11-30 18:57:46 +00:00
helixhorned 16c596b31b Some Lunatic cleanup.
git-svn-id: https://svn.eduke32.com/eduke32@3246 1a8010ca-5511-0410-912e-c29ae57300e0
2012-11-30 18:57:40 +00:00
helixhorned c4abfc405a Windows: Fix potential crash in version checker.
1) see if we actually received anything
(if http://eduke32.sourceforge.net/VERSION is unavailable, this returns now
instead of continuing with nonsensical data)
2) check if we're getting a token from strtok()

git-svn-id: https://svn.eduke32.com/eduke32@3244 1a8010ca-5511-0410-912e-c29ae57300e0
2012-11-29 12:49:41 +00:00
helixhorned 7614a78cc5 Factor dist() and ldist() into common.c.
git-svn-id: https://svn.eduke32.com/eduke32@3243 1a8010ca-5511-0410-912e-c29ae57300e0
2012-11-29 12:49:38 +00:00
helixhorned 375d164138 Move enum vmflags_t to gameexec.c since it's an implementation detail.
git-svn-id: https://svn.eduke32.com/eduke32@3242 1a8010ca-5511-0410-912e-c29ae57300e0
2012-11-29 12:49:34 +00:00
hendricks266 890aba88eb Fix warnings involving printf() requiring explicit casts on tracked types.
git-svn-id: https://svn.eduke32.com/eduke32@3238 1a8010ca-5511-0410-912e-c29ae57300e0
2012-11-26 08:26:04 +00:00