Commit Graph

120 Commits

Author SHA1 Message Date
hendricks266 1cc9d13ccf The great repository rearrangement of 2017.
Files moved but not modified. Changes to follow in a subsequent commit.

You down with CPP?

git-svn-id: https://svn.eduke32.com/eduke32@6055 1a8010ca-5511-0410-912e-c29ae57300e0
2017-02-01 10:01:11 +00:00
terminx e8e34de6ef Rename ud.tickrate to ud.showfps internally. DONT_BUILD.
git-svn-id: https://svn.eduke32.com/eduke32@6021 1a8010ca-5511-0410-912e-c29ae57300e0
2017-01-18 22:23:20 +00:00
hendricks266 0a14982d4e Some recent cleanup changed uses of int32_t to int, but missed changing every function prototype. This is very bad when int != int32_t.
git-svn-id: https://svn.eduke32.com/eduke32@5979 1a8010ca-5511-0410-912e-c29ae57300e0
2017-01-01 13:23:29 +00:00
terminx c6617a98b2 More cleanup. DONT_BUILD.
git-svn-id: https://svn.eduke32.com/eduke32@5830 1a8010ca-5511-0410-912e-c29ae57300e0
2016-08-27 01:41:33 +00:00
terminx 4575148c02 Use size_t or ssize_t in for loops where possible
git-svn-id: https://svn.eduke32.com/eduke32@5829 1a8010ca-5511-0410-912e-c29ae57300e0
2016-08-27 01:41:21 +00:00
terminx aae66ccb11 Further cleanup. DONT_BUILD.
git-svn-id: https://svn.eduke32.com/eduke32@5828 1a8010ca-5511-0410-912e-c29ae57300e0
2016-08-27 01:41:04 +00:00
terminx 34453f5090 Continued cleanup. DONT_BUILD.
git-svn-id: https://svn.eduke32.com/eduke32@5827 1a8010ca-5511-0410-912e-c29ae57300e0
2016-08-27 01:40:56 +00:00
terminx 5c6d8c96ad The great cleanup continues. This one also adds a new feature, SFLAG_WAKEUPBADGUYS. When awoken (changed to an active actor), any sprite with this flag set will wake up any enemy it has line of sight with.
git-svn-id: https://svn.eduke32.com/eduke32@5826 1a8010ca-5511-0410-912e-c29ae57300e0
2016-08-27 01:40:46 +00:00
terminx 52f678a743 Massive readability cleanup of game code part 1. DONT_BUILD.
git-svn-id: https://svn.eduke32.com/eduke32@5825 1a8010ca-5511-0410-912e-c29ae57300e0
2016-08-27 01:40:35 +00:00
terminx 5800cd588c tsectortype -> usectortype
twalltype -> uwalltype
tspritetype -> uspritetype

No other changes.

git-svn-id: https://svn.eduke32.com/eduke32@5796 1a8010ca-5511-0410-912e-c29ae57300e0
2016-06-21 00:33:58 +00:00
terminx dbbc7b1e13 Break out screen drawing stuff from game.c into screens.c and command line processing stuff into cmdline.c
git-svn-id: https://svn.eduke32.com/eduke32@5618 1a8010ca-5511-0410-912e-c29ae57300e0
2016-02-13 21:05:57 +00:00
terminx 023bc40020 Break all of the text printing stuff out of game.c and into a separate screentext.c/h
git-svn-id: https://svn.eduke32.com/eduke32@5614 1a8010ca-5511-0410-912e-c29ae57300e0
2016-02-07 02:38:23 +00:00
terminx 5b7a4a9a78 Break out status bar code into sbar.c/h
git-svn-id: https://svn.eduke32.com/eduke32@5613 1a8010ca-5511-0410-912e-c29ae57300e0
2016-02-07 02:38:16 +00:00
terminx 51bc13a9d7 Break cheat code stuff out of game.c and into cheats.c/h. Remove unnecessary header includes from several modules (all relevant headers are already pulled in by duke3d.h).
git-svn-id: https://svn.eduke32.com/eduke32@5611 1a8010ca-5511-0410-912e-c29ae57300e0
2016-02-07 02:38:03 +00:00
terminx ba54de3ab3 Further cleanup of A_InsertSprite().
git-svn-id: https://svn.eduke32.com/eduke32@5567 1a8010ca-5511-0410-912e-c29ae57300e0
2016-01-15 07:58:52 +00:00
hendricks266 344e10628f Part two of more const casting, this time affecting argv instances.
git-svn-id: https://svn.eduke32.com/eduke32@5552 1a8010ca-5511-0410-912e-c29ae57300e0
2016-01-12 10:30:56 +00:00
terminx a7e6ed8745 Fix quite a few issues with casting away const and volatile qualifiers, found with -Wcast-qual. If we're going to use const everywhere, we should really mean it!
git-svn-id: https://svn.eduke32.com/eduke32@5540 1a8010ca-5511-0410-912e-c29ae57300e0
2016-01-11 05:05:38 +00:00
hendricks266 3a8d53573c Remove actors_inline, game_inline, and sector_inline objects, and move their code into other headers, set up to be compiled into well-fitting objects if inlining them is disabled.
git-svn-id: https://svn.eduke32.com/eduke32@5529 1a8010ca-5511-0410-912e-c29ae57300e0
2016-01-08 01:33:35 +00:00
hendricks266 4aae9378d0 Implement NAM and WWII GI's replacement cheats.
Whereas Duke starts cheats with DN, NAM starts with NVA and WWII GI starts with WW2. (Hackily: CheatKeys[] is still size 2, and the third character is at the start of every CheatString.)

The cheats hyper (NAM-only), coords, view, skill, weapons, and inventory were not originally present but since they work properly and this is EDuke32, I have re-added them. Non-working cheats are now disabled.

git-svn-id: https://svn.eduke32.com/eduke32@5451 1a8010ca-5511-0410-912e-c29ae57300e0
2015-11-25 12:08:28 +00:00
hendricks266 c0e7dba4c1 Restructure the basepaltable subsystem to support up to 256 palettes and use dynamic allocation like palookup and blendtable.
git-svn-id: https://svn.eduke32.com/eduke32@5348 1a8010ca-5511-0410-912e-c29ae57300e0
2015-09-23 17:55:02 +00:00
helixhorned ff56964e1b Game: fix displayed viewscreen when its x/yrepeat isn't evenly divisible by 4.
git-svn-id: https://svn.eduke32.com/eduke32@5312 1a8010ca-5511-0410-912e-c29ae57300e0
2015-07-25 17:23:22 +00:00
hendricks266 ab58a33ec6 Menus: Add a Cheats menu to options.
It's old-school.

git-svn-id: https://svn.eduke32.com/eduke32@5084 1a8010ca-5511-0410-912e-c29ae57300e0
2015-03-24 10:49:03 +00:00
terminx 61f35b827a Remove WeaponChoice* from eduke32.cfg and transition setting to "wchoice" cvar. This commit also removes an Android hack and changes the order of some of the in-game "F" key handling, just because it bugged me that some of them were out of order.
git-svn-id: https://svn.eduke32.com/eduke32@5065 1a8010ca-5511-0410-912e-c29ae57300e0
2015-03-24 00:39:52 +00:00
terminx 31b557ef61 More Android changes. DONT_BUILD.
git-svn-id: https://svn.eduke32.com/eduke32@4989 1a8010ca-5511-0410-912e-c29ae57300e0
2015-02-11 05:22:19 +00:00
terminx cc4ddf9ce7 Minor sound cleanup... clean up crappy old code, remove obsolete "FXDevice" and "MusicDevice" variables, etc.
git-svn-id: https://svn.eduke32.com/eduke32@4986 1a8010ca-5511-0410-912e-c29ae57300e0
2015-02-11 05:22:00 +00:00
hendricks266 d7f846d0b6 Factor out generation of strings for time values in the bonus screen. This involves the creation of ud.playerbest.
git-svn-id: https://svn.eduke32.com/eduke32@4968 1a8010ca-5511-0410-912e-c29ae57300e0
2015-02-08 08:03:30 +00:00
hendricks266 93a3ff34e8 Add events EVENT_DISPLAYINACTIVEMENU and EVENT_DISPLAYINACTIVEMENUREST and userdef members m_origin_x and m_origin_y.
This allows for CON screen display code to use menu animations. The following is an example of how to adapt screen features that should animate.

before:

onevent EVENT_DISPLAYMENUREST
    ifvare current_menu 0 // main menu
    {
        setvar x 1
        setvar y 1
        rotatesprite x y zoom ang tilenum shade pal orientation 0 0 xdim ydim
    }
endevent

after:

state DisplayMenuCommon
    ifvare RETURN 0 // main menu
    {
        getuserdef[THISACTOR].m_origin_x x
        getuserdef[THISACTOR].m_origin_y y
        addvar x 65536
        addvar y 65536
        rotatesprite16 x y zoom ang tilenum shade pal orientation 0 0 xdim ydim
    }
ends

onevent EVENT_DISPLAYMENUREST state DisplayMenuCommon endevent
onevent EVENT_DISPLAYINACTIVEMENUREST state DisplayMenuCommon endevent

git-svn-id: https://svn.eduke32.com/eduke32@4945 1a8010ca-5511-0410-912e-c29ae57300e0
2015-01-25 12:16:58 +00:00
terminx cdaa25ef07 Implement better fade-out for quotes and for the mouse cursor in the menu.
git-svn-id: https://svn.eduke32.com/eduke32@4919 1a8010ca-5511-0410-912e-c29ae57300e0
2015-01-15 06:45:14 +00:00
terminx c591711fe8 MSVC C++ build fixes. DONT_BUILD.
git-svn-id: https://svn.eduke32.com/eduke32@4890 1a8010ca-5511-0410-912e-c29ae57300e0
2015-01-11 04:52:15 +00:00
hendricks266 eca33954db Fix the MAXJOYBUTTONS discrepancy between _control.h and gamedefs.h.
git-svn-id: https://svn.eduke32.com/eduke32@4826 1a8010ca-5511-0410-912e-c29ae57300e0
2014-12-18 18:15:51 +00:00
helixhorned 70cbde87eb Move g_noFloorPal[] to the engine side and adapt other stuff accordingly.
- 'nofloorpalrange' DEF token: now handled for both game and editor (for the
  latter, it's effective only for "shade preview" mode, [']+[X]).
- in generatefogpals(), assign g_noFloorPal[] = 1 for every generated (default)
  fog pal; get rid of its return value / g_firstFogPal

git-svn-id: https://svn.eduke32.com/eduke32@4811 1a8010ca-5511-0410-912e-c29ae57300e0
2014-12-13 22:33:04 +00:00
hendricks266 9268b9f0b6 Make a bunch of things extern "C". This should fix C++ builds on OS X and with Lunatic. DONT_BUILD.
git-svn-id: https://svn.eduke32.com/eduke32@4766 1a8010ca-5511-0410-912e-c29ae57300e0
2014-11-26 04:39:23 +00:00
terminx 99e21ffa94 Part 1 of attempting to adhere to C standard section 7.1.3. It turns out it's illegal to use identifiers that begin with _ or have __ anywhere in them. DONT_BUILD.
git-svn-id: https://svn.eduke32.com/eduke32@4747 1a8010ca-5511-0410-912e-c29ae57300e0
2014-11-22 12:32:56 +00:00
hendricks266 164d9ccb41 Set up mouse cursor display in menus, with idle timeout fully implemented. No functionality yet. DONT_BUILD.
git-svn-id: https://svn.eduke32.com/eduke32@4738 1a8010ca-5511-0410-912e-c29ae57300e0
2014-11-17 07:39:12 +00:00
hendricks266 5dd1abd647 Two files forgotten in the previous commit. DONT_BUILD.
git-svn-id: https://svn.eduke32.com/eduke32@4687 1a8010ca-5511-0410-912e-c29ae57300e0
2014-10-27 07:24:37 +00:00
terminx 1e2fdef0e2 Forgot this in a previous commit, just removes a function prototype I moved elsewhere
git-svn-id: https://svn.eduke32.com/eduke32@4677 1a8010ca-5511-0410-912e-c29ae57300e0
2014-10-25 03:34:50 +00:00
helixhorned 3dc5c9e144 Allow DEFining music for which there is no CON music; Add 'music' OSD command.
The OSD command is invoked like "music E5L3" (case insensitively).

git-svn-id: https://svn.eduke32.com/eduke32@4587 1a8010ca-5511-0410-912e-c29ae57300e0
2014-09-07 18:10:13 +00:00
hendricks266 b0e82d4264 Split parts of loadlookups() into generatefogpals() and fillemptylookups(), and move Duke-specific LOOKUP.DAT behavior to G_LoadLookups() in source/common.c, which contains the call to loadlookups() as factored out from astub.c and game.c.
DONT_BUILD.

git-svn-id: https://svn.eduke32.com/eduke32@4564 1a8010ca-5511-0410-912e-c29ae57300e0
2014-07-28 06:45:53 +00:00
hendricks266 16cd8b8aaa Progress towards KenBuild Editor, part 2.
DONT_BUILD.

git-svn-id: https://svn.eduke32.com/eduke32@4560 1a8010ca-5511-0410-912e-c29ae57300e0
2014-07-28 06:44:14 +00:00
hendricks266 b48f3b44e3 Progress towards KenBuild Editor, part 1.
DONT_BUILD.

git-svn-id: https://svn.eduke32.com/eduke32@4558 1a8010ca-5511-0410-912e-c29ae57300e0
2014-07-28 06:43:16 +00:00
hendricks266 e8949e1c31 Elimininate some codedup between game.c and astub.c.
DONT_BUILD.

git-svn-id: https://svn.eduke32.com/eduke32@4557 1a8010ca-5511-0410-912e-c29ae57300e0
2014-07-28 06:42:28 +00:00
hendricks266 c1c01f0e0b Replace the funkily-formatted GNU.TXT with the FSF's official gpl-2.0.txt. Also, update the FSF's address in all source files that contain it.
DONT_BUILD.

git-svn-id: https://svn.eduke32.com/eduke32@4541 1a8010ca-5511-0410-912e-c29ae57300e0
2014-07-20 08:55:56 +00:00
hendricks266 f4becd06d5 Instead of displaying "Unknown GRP - EDuke32", simply display "EDuke32".
Much classier this way.

git-svn-id: https://svn.eduke32.com/eduke32@4516 1a8010ca-5511-0410-912e-c29ae57300e0
2014-06-16 23:17:11 +00:00
hendricks266 45deabc782 Add the following LOGO_FLAGS:
LOGO_NOE1ENDSCREEN
LOGO_NOE2ENDSCREEN
LOGO_NOE3RADLOGO
LOGO_NODUKETEAMTEXT
LOGO_NODUKETEAMPIC

As part of this, the LOGO_NOE*BONUSSCENE flags no longer remove the entire end sequence in one go. They now only remove the primary cinematic. If you want their previous effect, you'll have to add these additional bits.

git-svn-id: https://svn.eduke32.com/eduke32@4514 1a8010ca-5511-0410-912e-c29ae57300e0
2014-06-16 23:16:37 +00:00
hendricks266 11e9b8f4ce Ball-busting new menus. Still WIP.
Mouse/touch/pointer support is yet to come. #SOON.

Exposure to scripting is a LONG way off. Months. The spec and data structure needs time for comment and revision. The eventual scripting access will be Lua-only.

git-svn-id: https://svn.eduke32.com/eduke32@4496 1a8010ca-5511-0410-912e-c29ae57300e0
2014-05-31 12:26:41 +00:00
helixhorned 0c2776e7fc game.c: in A_Spawn(), protect CSTAT_SPRITE_NOSHADE of spawned MASKWALL* sprites.
git-svn-id: https://svn.eduke32.com/eduke32@4478 1a8010ca-5511-0410-912e-c29ae57300e0
2014-05-22 11:17:50 +00:00
hendricks266 a755e95c2c Replace some constants with preprocessor macros.
git-svn-id: https://svn.eduke32.com/eduke32@4472 1a8010ca-5511-0410-912e-c29ae57300e0
2014-05-17 12:36:40 +00:00
helixhorned 63fee16ca5 CON: in rotatespritea and screentext, if alpha < 0, make -alpha denote blend.
For convenience, orientation gets bit 1 (translucency) set automatically.
Again, test/screentext.con is updated to show off this functionality (the
code there assumes that additive blending tables are loaded at blend
numbers 101 -- 132).

BUILD_LUNATIC.

git-svn-id: https://svn.eduke32.com/eduke32@4428 1a8010ca-5511-0410-912e-c29ae57300e0
2014-04-09 18:51:35 +00:00
terminx ba0c64971c Widespread use of ARRAY_SIZE macro.
git-svn-id: https://svn.eduke32.com/eduke32@4385 1a8010ca-5511-0410-912e-c29ae57300e0
2014-03-22 09:25:15 +00:00
helixhorned 7e7507746d Factor out common parts of loading LOOKUP.DAT into engine.c:loadlookups().
Also, error if didn't read enough data and account for TITLE and REALMS
swap between basepal number and on-disk order (sigh).

git-svn-id: https://svn.eduke32.com/eduke32@4334 1a8010ca-5511-0410-912e-c29ae57300e0
2014-02-16 19:16:03 +00:00