Commit Graph

4389 Commits (77bc79ab8816fe1f5ecbc55f6dce88170664d36e)

Author SHA1 Message Date
Giel van Schijndel 77bc79ab88 Remove the TARGET option (I shouldn't have added it back) and select the windows-specific link line for the win32 makefiles
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5475 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-10 19:52:33 +00:00
Giel van Schijndel 66bfab9dcf Prefix all propulsion types (from enum PROPULSION_TYPE) with `PROPULSION_TYPE_` to qualify these names more fully
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5474 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-10 17:59:35 +00:00
Giel van Schijndel 6fcbc73c2c Merge the DATA build option (for the win32 makefile build system) into INSTALLER as the data packages are only required when building an installer
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5473 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-10 17:51:31 +00:00
Giel van Schijndel a81de28500 Add the TARGET option to the win32 makefile system's config template
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5472 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-10 17:36:37 +00:00
Giel van Schijndel d914e3cccd Don't use the `mingw32-` prefix in the win32 makefiles, as MinGW's default distribution doesn't provide all executables with `mingw32-` prefix, but it does provide all of them without the prefix
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5471 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-10 17:26:11 +00:00
Giel van Schijndel da5f5edd81 include config.mk from the `makerules` directory, not the base/root directory
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5470 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-10 17:19:17 +00:00
Giel van Schijndel 26a9168ca9 Add a new configuration option "music_enabled" which can be used to disable the ingame music with
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5468 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-10 16:05:19 +00:00
Giel van Schijndel 623044cf7c Add some debug messages when failing to create an AUDIO_STREAM in sound_PlayStreamWithBuf
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5467 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-10 15:47:27 +00:00
Giel van Schijndel f6853ed368 * Get rid of enumerator INVALID_PROP_TYPE from PROPULSION_TYPE
* Modify getPropulsionType's API so that we don't need to depend on enum PROPULSION_TYPE containing an "invalid" enumerator

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5466 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-10 15:47:21 +00:00
Giel van Schijndel b5ff9610ea * Remove TODO comment about needing to add an IMD_Model type, because that type already exists
* Add a comment, describing the `flameModel` field


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5465 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-10 11:03:39 +00:00
Giel van Schijndel a80776b9fa don't use the file header template if it isn't available in the c_structdef code generator
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5464 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-10 10:58:13 +00:00
Dennis Schridde faf8153b50 Old versions for Flex do not like the space in -o filename
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5463 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-10 09:35:10 +00:00
Giel van Schijndel b3c43881a8 Don't #include "stats-db2.h" as it doesn't exist (is a testing file in my working copy)
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5462 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 21:02:13 +00:00
Giel van Schijndel af9a1c2a18 Declare propulsionType as PROPULSION_TYPE (enum) instead of UBYTE in PROPULSION_STATS (struct)
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5461 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 21:00:09 +00:00
Giel van Schijndel c5b87954bc Add a new field type to the mini database scheme meta language: C-only-field
* This is a dummy type that causes the rest of the line to be included literally in the struct's definition
 * Use this field type to add ppIMDList (member var of BODY_STATS in statsdef.h)


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5460 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 20:47:17 +00:00
Giel van Schijndel 2d6958306e Fix a compile error; forgot to declare variable "dummyVal" in r5454
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5459 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 20:43:24 +00:00
Giel van Schijndel 1170798c66 Add a field to hold a component's body points (COMPONENT now fully matches COMPONENT_STATS from statsdef.h)
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5458 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 19:17:19 +00:00
Dennis Schridde b770951532 makefile.raw -> makefile.win32
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5457 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 19:17:15 +00:00
Per Inge Mathisen 1f831ebd3d Add beginnings of self-test to openal and general audio subsystems.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5456 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 19:07:42 +00:00
Giel van Schijndel 47e7107aea Remove `systemPoints` from the code as it's never used.
It's loaded in from the stats files but unused throughout the rest of the code.

Read into a temporary dummy variable when loading stats.

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5455 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 19:07:20 +00:00
Giel van Schijndel 0d997d617f Remove `hitPoints` from the code as it's never used.
It's loaded in from the stats files and copied all over a dozen places, but never actually __used__.

NOTE: This __shouldn't__ break savegames, I've checked it quite thoroughly, but game.c is evil & large enough that the chance exists I made a mistake in this department.

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5454 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 19:02:19 +00:00
Giel van Schijndel c6c5c981e6 Remove all TECH_LEVEL related cruft from the code as it's read from the stats files but unused throughout the rest of the code.
Read into a temporary dummy variable when loading stats.

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5453 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 18:28:37 +00:00
Giel van Schijndel 44f3bf5f69 Only declare the function name of the %loadFunc directive to be declared in the file where the %loadFunc directive is located.
Don't declare the return type and parameter list to originate from the "original" source file.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5452 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 17:55:18 +00:00
Giel van Schijndel be7aef1a17 Convert dashes (-) to undersquores (_) as well in header guards (fixes a syntax error with C's preprocessor)
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5451 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 17:45:56 +00:00
Giel van Schijndel db03e5b276 include (perl directive "require") code generators from the same directory as the language parser
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5450 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 17:15:44 +00:00
Freddie Witherden 7d5723455c Add keycode.h to the repository (which I forgot in r5445).
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5449 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 16:51:17 +00:00
Per Inge Mathisen 2aeda4d91e Improve playlist selftest. It now covers the entire playlist API. Remove unused
playlist declaration from header file.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5448 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 16:19:57 +00:00
Giel van Schijndel 2e3280a845 Pass the output file as a command line parameter (and fall back to stdout if none is provided)
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5446 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 16:05:41 +00:00
Freddie Witherden 631ff7879b Add a dedicated text input event. Switch to our own custom keycode enum rather than depending on SDLs.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5445 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 15:46:46 +00:00
Giel van Schijndel c8dbcd6d2d * Don't refer to a "flame IMD" when loading an IMD_Model, refer to "the IMD for field \"$fieldName\"" instead
* Reference records by their ID number (unique_inheritance_id) instead of some user-code dependent function

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5444 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 15:30:13 +00:00
Giel van Schijndel 03cf003811 * Add line information to the AST of %preLoadTable and %postLoadRow struct-level directives
* Use these line numbers in the output of the SQLite C loading code generator to produce #line directives

git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5443 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 15:25:46 +00:00
Giel van Schijndel d3c8f34aaf Add function prototypes for the SQLite DB load functions (declared using %loadFunc) to the struct definition header
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5442 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 15:25:42 +00:00
Giel van Schijndel 052c32e8ec Slightly rework c_structdef_cg.pm's header-template processing code to be more similar to c_sqliteload_cg.pm's header-template processing code
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5441 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 15:02:10 +00:00
Giel van Schijndel df7b09c6fa Wrap the "header/start/leader" template contents in #line directives for the SQLite C code generator's output
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5440 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 15:01:02 +00:00
Giel van Schijndel f8f4ce0854 Make sure to count __all__ lines, also those who start a new "scope" (anything that finishes with "end")
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5439 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 14:58:04 +00:00
Giel van Schijndel 3b57831282 * Add line numbers to the AST for %loadFunc directives
* Utilize these line numbers to generate #line directives in the output file


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5438 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 14:47:16 +00:00
Giel van Schijndel 1ceafee327 Add line-counting code to the mini database scheme meta language parser
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5437 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 14:36:27 +00:00
Giel van Schijndel 46fc5cc97e * Make it possible to use forward declarations to the generated struct types
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5436 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 13:59:23 +00:00
Giel van Schijndel 707d5cf718 * Print from a template for the C struct definition code generator as well
* Add a template for the struct definition header; adds some #include directives required to be able to compile the generated header


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5435 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 13:57:26 +00:00
Giel van Schijndel 2d1b9d8694 Only shift the next parameter from ARGV if there are more than one (1) left in the C SQLite code generator
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5434 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 13:49:49 +00:00
Giel van Schijndel 74784e3f6e Add two new struct-level directives to the mini database scheme meta language:
* %preLoadTable which specifies a code block to be executed just __before__ loading in all rows in a database
 * %postLoadRow which specifies a code block to be executed after every row has been succesfully loaded in a struct


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5433 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 13:09:53 +00:00
Giel van Schijndel 2b6b037ade * Rename and modify the SQL SELECT statement code generator to a code generator that produces C code for loading in the contents of database tables
* Add a template file which is used by this new code generator as a file "header"
 * Add a new struct-level directive to the mini database meta scheme language: %loadFunc which specifies that the above code generator should generate a loading function for this type plus what its name should be
 * Add a new entry for this code generator to the Makefile for testing purposes


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5432 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 13:04:10 +00:00
Giel van Schijndel 40742f8d8a Give the code generators the ability to process command line arguments (before the parsing begins)
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5431 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 12:46:53 +00:00
Giel van Schijndel 3f0b1959f2 For struct-fields of an enum type store references to the enum instead of just their name
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5430 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-09 12:16:55 +00:00
Per Inge Mathisen ba1df9e976 Fix bug #11979: Distorted terrain tiles after savegame r5399, caused by r5399.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5429 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-08 19:20:00 +00:00
Per Inge Mathisen ee6452eb64 Revert r5426. It will not work quite like that, since the pointers refer
to a list in audio.c. The horror! The horror!


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5428 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-08 18:24:42 +00:00
Dennis Schridde f77542e2f8 Move config dir on Windows back to My Documents
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5427 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-08 17:46:45 +00:00
Per Inge Mathisen 74aeca0093 Change current_queue_sample to a pointer to an AUDIO_SAMPLE instead of
an integer value. This fixes the problem of AL_INVALID being used for
invalid values, while it is really a perfectly valid ID for a sample.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5426 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-08 17:45:33 +00:00
Per Inge Mathisen 4d1d5b4c11 Add an error check to patch #1082: Fix AL_INVALID_NAME bug, to catch the
currently impossible case of the sample not being in the active list.


git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5425 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-08 17:11:58 +00:00
Freddie Witherden 4f07f76034 Add an initial spacer implementation.
git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@5424 4a71c877-e1ca-e34f-864e-861f7616d084
2008-07-08 16:55:15 +00:00