Compare commits

..
Author SHA1 Message Date
penguin 573a1f2fa3 updated 2002-08-13 04:31:25 +00:00
penguin a763d84b56 1. Disable CD checking
2. Add CVS tag to version string
2002-08-13 03:34:00 +00:00
penguin c06ccbb602 Bumped to version 3.2 2002-08-13 03:32:25 +00:00
drevil ffd8a5ae2a Rebuilding admin files 2002-08-11 23:08:20 +00:00
drevil aa753d5d6e Trash syncmail, it's worthless, use logaccum stuff instead 2002-08-11 23:05:15 +00:00
drevil 1cf042064f Yet more updates for syncmail 2002-08-11 22:36:01 +00:00
drevil a4e14a94d2 Correct arguments to syncmail 2002-08-11 22:22:35 +00:00
drevil 5871d644cc Change which module syncinfo "hooks" to 2002-08-11 22:20:56 +00:00
drevil 145a149873 Updated syncmail to current CVS version 2002-08-11 22:17:16 +00:00
drevil 7492c51ee6 corrected path to syncmail 2002-08-11 22:04:47 +00:00
drevil be4954a69e Adding syncmail cvs commit notification 2002-08-11 22:02:45 +00:00
DTP 875a95b82e Implented -GF4FIX commandline switch & #include "cmdline/cmdline.h" 2002-08-07 00:45:25 +00:00
DTP f6b129577b Implented -GF4FIX commandline switch 2002-08-07 00:44:13 +00:00
penguin 4d30bbba3e Updated 2002-08-06 21:21:42 +00:00
phreak 8823dc67eb added wireframe targetbox feature 2002-08-06 16:50:44 +00:00
phreak 8690c9d7f6 added Targetbox_wire variable to check what mode the
hud targetbox uses
2002-08-06 16:50:13 +00:00
phreak f70d242903 added keybing for wireframe hud,
fixed previous missile cheat
2002-08-06 16:49:22 +00:00
penguin 5b4306dbd6 Use text strings for wingmen names instead of ANI 2002-08-06 04:39:26 +00:00
penguin 013870fc6a inserted "class" keyword on "friend" definitions (ANSI C++ ) 2002-08-06 03:50:48 +00:00
penguin 0e3d4e562f Fixed problem w/ compile options for Debug mode 2002-08-06 02:43:02 +00:00
penguin 48d1ec4575 Removed a couple more include dirs I missed 2002-08-06 01:49:47 +00:00
penguin 32ad077676 Renamed ccode members to cc_or and cc_and 2002-08-06 01:49:08 +00:00
penguin 9942308fc8 Moved ChangeLog to top-level directory 2002-08-04 05:43:13 +00:00
penguin af3b97aae5 Change version display 2002-08-04 05:13:00 +00:00
penguin c3c0b0e1f4 Display fs2_open version instead of "Freespace 2" 2002-08-04 05:12:42 +00:00
penguin 9d5863bc76 Change version display location 2002-08-04 05:12:10 +00:00
penguin 4b2d436b04 Update version number to 3.1 2002-08-04 05:11:36 +00:00
penguin 404195d389 Don't write version to registry; change way version string is formatted 2002-08-04 05:11:05 +00:00
randomtiger df29aad213 Fixed Geforce 4 bug that caused font and hall video distortion.
Very small change in 'gr_d3d_aabitmap_ex_internal'

Tested and works on the following systems

OUTSIDER Voodoo 3 win98
OUTSIDER Geforce 2 win2000
Me Geforce 4 PNY 4600 XP
JBX-Phoenix Geforce 4 PNY XP
Mehrunes GeForce 3 XP
WMCoolmon nVidia TNT2 M64 win2000
Orange GeForce 4 4200 XP
ShadowWolf_IH Monster2 win98
ShadowWolf_IH voodoo 2 win98
2002-08-03 19:42:17 +00:00
wmcoolmon 026601e350 Fixed Win32 debug configuration 2002-08-03 18:35:21 +00:00
wmcoolmon 05a48addc6 Sync with makefile 1.4 2002-08-03 17:42:40 +00:00
penguin a1e9e62b6e updated 2002-08-01 04:04:01 +00:00
penguin 64ea61c93a The big include file move 2002-08-01 02:00:46 +00:00
penguin a0bbf8fd54 The big include file move 2002-08-01 01:41:11 +00:00
wmcoolmon 15e9872bb5 Fixed a bug I added in ship_do_rearm_frame 2002-07-30 18:11:25 +00:00
wmcoolmon a1f592ffef Modified to add hull repair capabilities and toggling of them via a mission flag, MISSION_FLAG_SUPPORT_REPAIRS_HULL 2002-07-30 17:57:40 +00:00
wmcoolmon 07de43ffc4 Added mission flag "MISSION_FLAG_SUPPORT_REPAIRS_HULL" for toggling Support Ship hull repair on and off 2002-07-30 17:35:22 +00:00
unknownplayer 522fa4c906 Started work on DX8.1 implementation. Updated the project files to encompass
the new files. Disable the compiler tag to use old DX code (THERE IS NO
NEW CODE YET!)
2002-07-30 14:29:15 +00:00
penguin 7611e0a2d2 Added Network/fs2ox.cpp 2002-07-29 22:24:57 +00:00
penguin 9290659edf First attempt at "fs2_open exchange" (PXO substitute) screen 2002-07-29 22:24:26 +00:00
penguin 3a88c2f9e3 We finally have a ChangeLog 2002-07-29 22:14:48 +00:00
penguin a732686bf6 Moved extern declaration of ssm_create outside of block (it wouldn't compile w/ gcc) 2002-07-29 20:48:51 +00:00
penguin 2ede27a557 added #ifdef _WIN32 around windows-specific system headers 2002-07-29 20:12:31 +00:00
penguin 8300b018f0 removed bogus #include windows.h 2002-07-29 20:12:02 +00:00
penguin 93aed25251 added #ifdef _WIN32 around windows-specific system headers 2002-07-29 19:52:48 +00:00
penguin 591563118c added #ifdef _WIN32 around windows-specific system headers 2002-07-29 19:37:21 +00:00
penguin b59b5dd5d8 added #ifdef _WIN32 around windows-specific system headers 2002-07-29 19:17:21 +00:00
penguin bb0bde6409 added #ifdef _WIN32 around windows-specific system headers 2002-07-29 19:04:48 +00:00
DTP 66a392ddae Forgot to Bump MAX_MODEL_SUBSYSTEMS from 128 to 200 2002-07-29 08:31:52 +00:00
DTP 8bfc9fa709 BUMPED MAX_POLYGON_MODELS TO 198 , MAX_SHIP_TYPES - 2 = 198 2002-07-29 08:28:00 +00:00
DTP ccbdeeff67 Bumped all MAX_SHIPS, and SHIP_LIMIT to 400.(let the mission designers decide what is good, and what is bad 2002-07-29 08:24:42 +00:00
DTP 0f1176adaf Bumped MAX_SHIP_SUBOBJECTS to 2100(2100 /(average fighter has 7 subsystems) = 400 fighters 2002-07-29 08:22:42 +00:00
DTP b75fce3d5c Bumped MAX_SUBSYS_LIST from 32 to 200 2002-07-29 08:19:41 +00:00
DTP ab68ad4855 -almission(autoload mission) commandline arguement handling implemented 2002-07-29 08:05:20 +00:00
DTP 426cf0b969 FIX; Startgame arguement dont go ahead when a singleplayer pilot is selected 2002-07-29 07:56:10 +00:00
DTP 2d1f7ba50f added -almission commandline arguement, will autoload mission i.e fs2_open.exe -almission kickass will autoload kickass.fs2 which should be a multiplayer mission. 2002-07-29 06:35:15 +00:00
DTP 69145e65f1 FIX -stargame commandline arguement will now let you quit, a thing not possible before when using the startgame arguement 2002-07-28 15:07:43 +00:00
penguin 3dcb4b380a Testing commit as penguin 2002-07-26 18:02:33 +00:00
drevil 8e996fdf67 Updated password file 2002-07-26 17:59:31 +00:00
penguin 7367d8a31f renamed 'big' and 'small' (conflict w/ MS include file) 2002-07-26 16:17:46 +00:00
penguin d5fcfc773c fixed bug where winsock.h wasn't defined 2002-07-26 16:12:05 +00:00
wmcoolmon 5cdd3a676d Added Bobboau's beam tiling code 2002-07-26 03:11:24 +00:00
wmcoolmon fd95da4c0a Added Bobboau's fighter-beam code. 2002-07-25 04:50:48 +00:00
penguin 1aa613e0f5 Added ifndef NO_STANDALONE 2002-07-22 01:39:24 +00:00
penguin 7d91a35878 Stub defines for NO_SOUND 2002-07-22 01:37:24 +00:00
penguin fa2c566b3f Linux port -- added NO_STANDALONE ifdefs 2002-07-22 01:22:26 +00:00
penguin f2b7f9718a Made more compatible w/ Win32; defines for NO_SOUND, NO_JOYSTICK, NO_NETWORK 2002-07-22 01:14:09 +00:00
penguin 08c0bd3aee Moved the dummy "sound" definitions to main program (freespace.cpp) 2002-07-22 01:10:10 +00:00
penguin 3a39133e04 More defines for winsock compatibility 2002-07-22 01:06:04 +00:00
penguin c3ec5825a4 took out GAME_CD_CHECK define 2002-07-22 01:04:37 +00:00
DTP baddd6703d Bumped Max Shield Icons to 80 2002-07-20 23:51:59 +00:00
DTP 0c3733d2cd Fixed multiplayer music. succes music on all Primary goals complete, fail music
if otherwise
2002-07-20 23:50:53 +00:00
DTP c536d49afd Fixed Secondary bank bug, where next valid secondary bank inherits current
valid banks FULL fire delay
2002-07-20 23:49:46 +00:00
DTP b031aee73a bumped MAX_MISSION_TEXT to 1000000 in code/parse/parselo.h 2002-07-20 19:21:13 +00:00
penguin c480e2c944 Fixed bug (potential access of unitialized pointer) in hud_config_render_gauges() -- thanks to DTP for finding it! 2002-07-18 20:07:49 +00:00
unknownplayer c7cd913df4 no message 2002-07-18 14:36:53 +00:00
unknownplayer 58a465e805 Revised AI primary selection code again to be more intelligent. 2002-07-18 09:55:26 +00:00
unknownplayer cf08ff0cd5 Rewrote my original algorithm to search by proportional hull damage.
Does the same thing a little better.
2002-07-18 05:38:28 +00:00
unknownplayer c839e8168a Fixed AI problems with using the maxim on fighters. 2002-07-18 03:27:38 +00:00
unknownplayer 3257777c18 Added some commentry to the low detail shield function. 2002-07-18 03:26:35 +00:00
unknownplayer 1028e14398 no message 2002-07-18 03:25:10 +00:00
unknownplayer b733679875 Altered project files to properly build debug info. Should save you all some time. 2002-07-17 23:59:56 +00:00
unknownplayer 723cbd5938 Minor commenting added to two functions. 2002-07-17 23:58:46 +00:00
wmcoolmon 0e48ea11ac Added SSM code for Tag C from Bobboau. Note that strings.tbl may need to be updated. 2002-07-17 20:04:00 +00:00
unknownplayer 57ab92645c Added a custom build step to copy to c:\games\freespace2\fs2_open.exe
when you build.
2002-07-17 12:52:01 +00:00
unknownplayer 2431f5db2c Updated to enable compilation under MSVC++ - all changes are marked
with my name ##UnknownPlayer##
2002-07-16 14:39:16 +00:00
unknownplayer 34d960638a This is the code project file. Use the workspace file I included to get at this. 2002-07-16 14:37:51 +00:00
unknownplayer 3bb26b10a3 This is the workspace for freespace2.dsp - it contains everything needed to
compile fs2_open.exe
2002-07-16 14:37:09 +00:00
unknownplayer 3cdc511b2d This is the project file to compile fs2_open. It's a real project file - use the
workspace though
2002-07-16 14:36:30 +00:00
penguin 4543d0c80c Changed so that debug make debug and release makes release :) 2002-07-16 01:15:59 +00:00
penguin 2a740ad2c8 Commented out "fs2_open.dep" stuff 2002-07-16 01:15:15 +00:00
inquisitor 7187da0233 Visual Studio files
compiles fs2_open.exe - 0 error(s), 7 warning(s)
2002-07-15 22:36:08 +00:00
wmcoolmon ab43e4d987 Added support for toggling ship trails 2002-07-15 02:11:00 +00:00
wmcoolmon 8056476db1 Added initial code for "ship-lights-on" and "ship-lights-off" SEXPs 2002-07-13 09:16:18 +00:00
penguin 4b471d6045 Added flags2 (ran out of bits in flags!) to ship struct; bit 0 will be used
to toggle Bobboau's lights.
2002-07-12 16:59:04 +00:00
penguin 8b19d7c8eb Removed dummy include file 2002-07-12 02:56:07 +00:00
penguin 90c6679f03 Fixed endian-ness of new "GLOW" IDs 2002-07-12 02:44:18 +00:00
wmcoolmon 4c73e5fe20 Added Bobboau's glow code; all comments include "-Bobboau" 2002-07-10 18:42:14 +00:00
penguin dd3a3138a7 Back-port to MSVC 2002-07-07 19:56:00 +00:00
penguin 9e8a091172 Makefile for Microsoft Visual C++ 2002-07-07 19:49:42 +00:00
drevil 5d72560a30 Adding mysterial and penguin to CVS's admin files 2002-06-08 19:21:16 +00:00
drevil 2a9c65bd3f Changing my password 2002-06-08 19:10:16 +00:00
drevil 6b4cca55be Changing my password 2002-06-08 19:04:53 +00:00
penguin c18139e73f Added machine-independent version of MulDiv (in case we don't know
the processor type)
2002-06-04 06:38:21 +00:00
407 changed files with 16029 additions and 5381 deletions

No files matched your search

+2
View File
@@ -11,3 +11,5 @@
# [<whitespace>]<filename><whitespace><error message><end-of-line>
#
# comment lines begin with '#'
new_commit_prep Error checking out/updating CVSROOT/new_commit_prep
new_log_accum Error checking out/updating CVSROOT/new_log_accum
+2
View File
@@ -13,3 +13,5 @@
#
# If the name "ALL" appears as a regular expression it is always used
# in addition to the first matching regex or "DEFAULT".
DEFAULT $CVSROOT/CVSROOT/new_commit_prep
CVSROOT $CVSROOT/CVSROOT/new_commit_prep
+4
View File
@@ -24,3 +24,7 @@
#DEFAULT (echo ""; id; echo %s; date; cat) >> $CVSROOT/CVSROOT/commitlog
# or
#DEFAULT (echo ""; id; echo %{sVv}; date; cat) >> $CVSROOT/CVSROOT/commitlog
DEFAULT $CVSROOT/CVSROOT/new_log_accum -m [email protected] %{sVv}
CVSROOT $CVSROOT/CVSROOT/new_log_accum -m [email protected] %{sVv}
+104
View File
@@ -0,0 +1,104 @@
#!/usr/bin/perl -w
#
# Copyright (C) 2000 by Kevin L. Mitchell <[email protected]>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
# 02111-1307, USA.
#
# Script to store the last visited directory for newlogaccum.pl.
#
# $Id: new_commit_prep,v 1.1 2002-08-11 23:05:15 drevil Exp $
use strict;
# This routine removes everything in a directory
sub clear_dir {
my ($dir) = @_;
my ($file);
opendir(DIR, $dir) || die "Cannot clear directory $dir: $!";
while ($file = readdir(DIR)) {
next
if ($file eq "." || $file eq "..");
$file = "$dir/$file";
if (-d $file) {
# It's a directory, recurse into it, then delete it.
clear_dir($file);
rmdir($file);
} else {
# It's a file, delete it.
unlink($file);
}
}
closedir(DIR);
}
# This routine prepares a temporary directory, hopefully in a secure
# fashion; it uses the process group to make secondary programs be able
# to find it.
sub tmpdir (;$) {
my ($clear) = @_;
my ($pgrp, $own, $mode, $tmpdir);
$pgrp = getpgrp();
die "Don't run $0 setuid!"
unless ($< == $>);
# Decide on the directory name, using various environment variables
$tmpdir = ($ENV{TMPDIR} || $ENV{TMP} || $ENV{TEMP} || "/tmp") .
"/.#cvs.$pgrp";
# Doesn't exist, but we can't create it...
die "Can't create temporary directory $tmpdir: $!"
unless (-e $tmpdir || mkdir($tmpdir, 0700));
die "Temporary directory $tmpdir is not a directory"
unless (-d $tmpdir);
# Check ownership and permissions
(undef, undef, $mode, undef, $own, undef) = stat($tmpdir);
die "Temporary directory $tmpdir not owned by $< (owned by $own)"
unless ($own == $<);
die "Temporary directory $tmpdir group-writable"
if ($mode & 0020);
die "Temporary directory $tmpdir other-writable"
if ($mode & 0002);
# If we're supposed to clear the directory, do so...
clear_dir($tmpdir)
if ($clear);
return $tmpdir;
}
# This routine writes a single line to a file
sub write_line ($$) {
my ($fname, $line) = @_;
open(FILE, ">$fname") || die "Cannot open file $fname for writing";
print FILE "$line\n";
close(FILE);
}
# Create and empty the temporary directory
my ($tmpdir) = (tmpdir(1));
# Store the directory name
write_line("$tmpdir/lastdir", shift(@ARGV));
+757
View File
@@ -0,0 +1,757 @@
#!/usr/bin/perl -w
#
# Copyright (C) 2000 by Kevin L. Mitchell <[email protected]>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
# 02111-1307, USA.
#
# Script to accumulate log messages for an entire tree and send them along
# with the diffs; deals correctly with all manner of branching (I hope)
#
# $Id: new_log_accum,v 1.1 2002-08-11 23:05:15 drevil Exp $
#
use strict;
use vars qw($MAILER $CVS $debug $boundary);
use MD5;
# Set this to the full path of a mailer that takes a list
# of email addresses as arguments...
$MAILER = "/usr/sbin/sendmail -oi -oeq";
# Set this to the path of the CVS binary responsible for this tree...
$CVS = "/usr/bin/cvs";
# Don't touch this; use the -d command line option
$debug = 0;
# This is initialized by build_mailheader()
$boundary = '';
use POSIX qw(setsid);
# We have to dissociate from our parent, so that the CVS commit can
# complete, before we try to extract the diffs
sub daemonize {
defined(my $pid = fork()) || die "Can't fork: $!";
exit(0)
if $pid;
setsid() || die "Can't start a new session: $!";
}
# Debugging output
sub debug (@) {
print STDERR @_
if ($debug);
}
# Constants used in the FSM below for parsing the log message
sub STATE_NONE { 0 }
sub STATE_MODIFIED { 1 }
sub STATE_ADDED { 2 }
sub STATE_REMOVED { 3 }
sub STATE_LOG1 { 4 }
sub STATE_LOG2 { 5 }
# This routine removes everything in a directory
sub clear_dir {
my ($dir) = @_;
my ($file);
opendir(DIR, $dir) || die "Cannot clear directory $dir: $!";
while ($file = readdir(DIR)) {
next
if ($file eq "." || $file eq "..");
$file = "$dir/$file";
if (-d $file) {
# It's a directory, recurse into it, then delete it.
clear_dir($file);
rmdir($file);
} else {
# It's a file, delete it.
unlink($file);
}
}
closedir(DIR);
}
# This routine prepares a temporary directory, hopefully in a secure
# fashion; it uses the process group to make secondary programs be able
# to find it.
sub tmpdir (;$) {
my ($clear) = @_;
my ($pgrp, $own, $mode, $tmpdir);
$pgrp = getpgrp();
die "Don't run $0 setuid!"
unless ($< == $>);
# Decide on the directory name, using various environment variables
$tmpdir = ($ENV{TMPDIR} || $ENV{TMP} || $ENV{TEMP} || "/tmp") .
"/.#cvs.$pgrp";
# Doesn't exist, but we can't create it...
die "Can't create temporary directory $tmpdir: $!"
unless (-e $tmpdir || mkdir($tmpdir, 0700));
die "Temporary directory $tmpdir is not a directory"
unless (-d $tmpdir);
# Check ownership and permissions
(undef, undef, $mode, undef, $own, undef) = stat($tmpdir);
die "Temporary directory $tmpdir not owned by $< (owned by $own)"
unless ($own == $<);
die "Temporary directory $tmpdir group-writable"
if ($mode & 0020);
die "Temporary directory $tmpdir other-writable"
if ($mode & 0002);
# If we're supposed to clear the directory, do so...
clear_dir($tmpdir)
if ($clear);
return $tmpdir;
}
# Routine to remove the temporary directory when done
sub cleanup_dir ($) {
# If we're debugging, we may want to look at the contents...
return
if ($debug);
clear_dir($_[0]);
rmdir($_[0]);
}
# Retrieve a single line from a specified file
sub get_line ($) {
my ($fname) = @_;
open(FILE, "<$fname") || die "Cannot open file $fname for reading";
my $line = <FILE>;
close(FILE);
# Chomp off the \n
chomp $line;
return $line;
}
# Routine that only allows one value to be pushed on the array;
# implemented by making the first element of the array a hash-reference.
# When we add a new value, we also increment the count of an element in
# the hash with the key being the array value...
sub push_once (\@@) {
my ($array, @values) = @_;
# If the array is empty, create our hash ref
push @{$array}, {}
if (@{$array} == 0);
foreach my $value (@values) {
push @{$array}, $value
if (!exists($array->[0]{$value}));
$array->[0]{$value}++;
}
return @{$array} - 1;
}
# Filter //, /./, and remove leading ./ or / from filenames
sub fname_filter ($) {
my ($fname) = @_;
$fname =~ s,//,/,g;
$fname =~ s,/\./,/,g;
$fname =~ s,^\.?/,,g;
return $fname;
}
# Store file data in a temporary file
sub names_to_file ($$@) {
my ($fname, $dir, @names) = @_;
if (@names > 0) {
open(FILE, ">>$fname") || die "Cannot open file $fname for appending";
# Store the directory data
print FILE "D $dir\n";
foreach my $name (@names) {
# Mark record as a file...
print FILE "F ";
# Store the tag, if there is one...
print FILE "$name->{tag}"
if (defined($name->{tag}));
# Then store old revision, new revision, and file name
print FILE ":$name->{old}:$name->{new}:$name->{file}\n";
}
close(FILE);
}
}
# Retrieve file data from temporary file; updates branch tags with what it
# reads
sub file_to_names (\@$) {
my ($btags, $fname) = @_;
my ($dir) = (undef);
my (@names) = ();
debug "Reading file names from $fname...\n";
# We may not have, say, added a file in this subdirectory...
return ()
if (!-e $fname);
open(FILE, "<$fname");
while(<FILE>) {
chomp;
# Get record type...
my ($type, $data) = split(' ', $_, 2);
# ok, it's a directory, remember that...
if ($type eq "D") {
$dir = $data;
debug "Read directory $dir\n";
next;
}
debug "Read file $data\n";
# Get all the information about the file
my ($tag, $old, $new, $file) = split(':', $data);
# and store it all
push(@names, { tag => $tag, old => $old, new => $new, file => $file,
dir => $dir, name => fname_filter("$dir/$file") });
# Remember the tags...
push_once(@{$btags}, $tag)
if (defined($tag) && $tag ne "");
}
close(FILE);
return @names;
}
# Create a text-formatted list of names
sub name_to_list (\@@) {
my ($btags, @names) = @_;
my (@nlist, @nline) = ();
debug "Tags:", join(':', @{$btags}), "\n";
# We group them by tag
foreach my $tag ("", @{$btags}[1..$#{$btags}]) {
debug "Processing tag $tag...\n";
@nlist = ();
# Get a list of files by the tag...
foreach my $name (@names) {
debug "Processing $name->{file}...\n";
next
if ($name->{tag} ne $tag);
debug "Pushing $name->{name} on \@nlist...\n";
push(@nlist, $name->{name});
}
# If the tag is not the empty string, list the tag...
push(@nline, " Tag: $tag", " ")
if ($tag ne "");
# Now list each file name
foreach my $name (@nlist) {
# indent if we run past the end of line limit
push(@nline, " ")
if (@nline == 0 || ($nline[$#nline] ne " " &&
length($nline[$#nline]) + length($name) + 1 > 70));
# add the file name to the list
debug "Adding $name to \@nline...\n";
$nline[$#nline] .= " $name";
}
}
return @nline;
}
# write the log message to a temporary file
sub write_log ($@) {
my ($fname, @text) = @_;
open(FILE, ">$fname") || die "Cannot open file $fname for writing";
print FILE join("\n", @text), "\n";
close(FILE);
}
# Build the header of the commit message: CVSROOT, module name, any
# branch tags, and the commit time
sub build_header ($@) {
my ($module, $subject, $mailto, @branch_tags) = @_;
my (@text, @mailto);
my ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = gmtime(time());
my ($user, $dummy);
my ($digest);
($user, $dummy, $dummy, $dummy, $dummy, $dummy, $dummy) = getpwuid($<);
@mailto = @{$mailto};
# generate a unique boundary by calculating the md5sum of the
# current time
$digest = new MD5;
$digest->reset();
$digest->add(time() . rand());
$boundary = "----=MIME." . unpack("H*", $digest->digest());
# Build the mail header
push(@text, "From: $user");
push(@text, "To: " . join(' ', @mailto));
push(@text, "Subject: $subject");
push(@text, "MIME-Version: 1.0");
push(@text, "Content-Type: multipart/mixed; boundary=\"$boundary\"");
push(@text, "");
push(@text, "This is a multipart message as defined by RFC2049 (MIME)");
push(@text, "");
push(@text, "--$boundary");
push(@text, "Content-Type: text/plain; charset=us-ascii");
push(@text, "Content-Disposition: inline");
push(@text, "");
# Build the commit message header
push(@text, "Commiter : $user");
push(@text, "CVSROOT : $ENV{CVSROOT}");
push(@text, "Module : $module");
push(@text, "Branch tags: " . join(' ', @branch_tags[1..$#branch_tags]))
if (@branch_tags > 0);
push(@text, sprintf("Commit time: %04d-%02d-%02d %02d:%02d:%02d UTC",
$year + 1900, $mon + 1, $mday, $hour, $min, $sec));
return @text, "";
}
# Send the mail message
sub send_mail {
my ($mailto, $text) = @_;
my (@mailto, @text);
# I <heart> perl
@mailto = @{$mailto};
@text = @{$text};
open(MAIL, "|$MAILER " . join(' ', @mailto));
push(@text, "--$boundary--", "");
print MAIL join("\n", @text), "\n";
close(MAIL);
}
# Find the tmp directory
my ($tmpdir) = (tmpdir());
my (@mailto) = ();
my (@files) = ();
my (@path) = ();
my ($modname, $repdir, $dir) = (undef, undef, undef);
# Process command line arguments
while (@ARGV > 0) {
my ($arg) = (shift(@ARGV));
if ($arg eq '-d') {
# Turn on debugging
$debug++;
} elsif ($arg eq '-M') {
# Module name explicitly set -- XXX Not tested, use at your own risk
die "Argument for -M missing"
unless (@ARGV > 0);
$modname = shift(@ARGV);
} elsif ($arg eq '-m') {
# An address to mail the notification to
die "Argument for -m missing"
unless (@ARGV > 0);
push(@mailto, shift(@ARGV));
} else {
# the list of filenames passed by CVS--you *must* use %{sVv}!
die "Too many arguments!"
unless (@files == 0);
@files = split(" ", $arg);
}
}
die "Nobody to mail to"
unless (@mailto > 0);
die "No files to process"
unless (@files > 1);
# The repository directory
$repdir = shift(@files);
# break it appart...
@path = split("/", $repdir);
# Now we know the module name, if it wasn't explicitly set
$modname = $path[0]
unless (defined($modname));
# Figure out what our directory is
if (@path == 1) {
$dir = ".";
} else {
$dir = join("/", @path[1..$#path]);
}
# append a / to it...
$dir .= "/";
debug "module = $modname\n";
debug "dir = $dir\n";
debug "path = ", join(":", @path), "\n";
debug "files = ", join(":", @files), "\n";
debug "tmpdir = $tmpdir\n";
my (%fversions);
# Unless its a new directory or imported sources, create file records
unless (defined($files[1]) && defined($files[2]) &&
(($files[1] eq "New" && $files[2] eq "directory") ||
($files[1] eq "Imported" && $files[2] eq "sources"))) {
foreach my $fname (@files) {
# You *must* use %{sVv} in the call in loginfo!
die "Invalid filenames"
unless ($fname =~ /^(.*),([0-9.]+|NONE),([0-9.]+|NONE)$/);
$fversions{$1} = {
old => ($2 eq "NONE" ? "0" : $2),
new => ($3 eq "NONE" ? "0" : $3),
};
}
}
# process log message
my ($state, $tag) = (STATE_NONE, undef);
my (@modified, @added, @removed, @log, @branch_tags) = ();
while (<STDIN>) {
chomp;
debug "State $state, line:$_\n";
# Ignore empty space at the beginning of the log message
next
if ($state == STATE_LOG1 && /^\s*$/);
# We're done ignoring empty space
if ($state == STATE_LOG1) {
$state = STATE_LOG2;
}
if ($state == STATE_LOG2) {
# Don't modify the lines at all if we're processing the log message
push(@log, $_);
next;
} else {
# Strip out leading and trailing space
s/^\s*(.*?)\s*$/$1/;
}
if (/^Modified Files/) {
# Collect list of modified files
debug "State switching to STATE_MODIFIED\n";
$state = STATE_MODIFIED;
$tag = undef;
next;
} elsif (/^Added Files/) {
# Collect list of added files
debug "State switching to STATE_ADDED\n";
$state = STATE_ADDED;
$tag = undef;
next;
} elsif (/^Removed Files/) {
# Collect list of removed files
debug "State switching to STATE_REMOVED\n";
$state = STATE_REMOVED;
$tag = undef;
next;
} elsif (/^Log Message/) {
# Collect log message
debug "State switching to STATE_LOG1\n";
$state = STATE_LOG1;
$tag = undef;
next;
} elsif (/^Revision\/Branch/) {
# Parse old-style Revision/Branch field
debug "Found a branch tag\n";
/^[^:]+:\s*(.*)/;
push_once(@branch_tags, $1);
warn "Tag == $tag"
if (defined($tag));
next;
}
# Ignore the stuff at the top of the commit report
next
if ($state == STATE_NONE);
if (/^Tag:\s*(.*)$/) {
# Remember the tag
debug "Setting tag to $1\n";
$tag = $1;
next;
}
my (@tfiles) = ();
# Find the file in our command line list of files
foreach my $file (split) {
die "Nothing known about file $file!"
unless (exists($fversions{$file}));
push @tfiles, {
file => $file,
tag => $tag,
old => $fversions{$file}{old},
new => $fversions{$file}{new},
};
}
# Store the file list in the correct array
push(@modified, @tfiles)
if ($state == STATE_MODIFIED);
push(@added, @tfiles)
if ($state == STATE_ADDED);
push(@removed, @tfiles)
if ($state == STATE_REMOVED);
}
# Remove trailing blank lines from the log message
while (@log > 0 && $log[$#log] =~ /^\s*$/) {
pop(@log);
}
# If a new directory was added, we're done...
if (defined($files[1]) && defined($files[2]) &&
$files[1] eq "New" && $files[2] eq "directory") {
my (@text) = ();
# If there was a sticky tag for the directory, make it a branch tag
if ($log[$#log] =~ /^--> Using per-directory sticky tag \`(.*)\'$/) {
push_once(@branch_tags, $1);
pop(@log);
}
# Build the message...
push(@text, build_header($modname, "Module $modname: New directory $dir",
\@mailto, @branch_tags));
push(@text, "Log message:", "", @log);
# and send it (synchronously)
send_mail(\@mailto, \@text);
# Clean up after ourselves and exit.
cleanup_dir($tmpdir);
exit(0);
}
# If an import was done, we're done...
if (defined($files[1]) && defined($files[2]) &&
$files[1] eq "Imported" && $files[2] eq "sources") {
my (@text) = ();
# Build the message...
push(@text, build_header($modname, "Module $modname: Imported $dir",
\@mailto, @branch_tags));
push(@text, "Log message:", "", @log);
# and send it (synchronously)
send_mail(\@mailto, \@text);
# Clean up after ourselves and exit.
cleanup_dir($tmpdir);
exit(0);
}
debug "Searching for log file index...";
my ($i);
# Look for an empty log file or one that matches our current log message
for ($i = 0; ; $i++) {
my (@text);
# found one that doesn't exist...
last
if (!-e "$tmpdir/logfile.$i");
# read in the log file
open(FILE, "<$tmpdir/logfile.$i");
while (<FILE>) {
chomp;
push(@text, $_);
}
close(FILE);
# If the log file was empty, use it
last
if (@text == 0);
# If the log messages are identical, use that
last
if (join(' ', @log) eq join(' ', @text));
}
debug "$tmpdir/logfile.$i\n";
# Store modified, added, and removed file lists, along with the log message
names_to_file("$tmpdir/modified.$i", $dir, @modified);
names_to_file("$tmpdir/added.$i", $dir, @added);
names_to_file("$tmpdir/removed.$i", $dir, @removed);
write_log("$tmpdir/logfile.$i", @log);
# Now check to see if we're at the end of our rope
my ($lastdir) = (get_line("$tmpdir/lastdir"));
debug "Checking $ENV{CVSROOT}/$repdir against lastdir $lastdir\n";
# Nope, exit instead of sending a message
exit(0)
if ($lastdir ne "$ENV{CVSROOT}/$repdir");
debug "At last, we've reached the end\n";
# We have to daemonize and sleep so that there isn't any lock hanging
# around when we get to the cvs rdiff below...
daemonize();
sleep(10);
# Build the mail message...
my (@text) = ();
@files = ();
@branch_tags = ();
for ($i = 0; ; $i++) {
# No more log files
last
if (!-e "$tmpdir/logfile.$i");
# read and insert the log message
open(FILE, "<$tmpdir/logfile.$i");
push(@text, "Log message:", "");
while (<FILE>) {
chomp;
push(@text, $_);
}
push(@text, "");
close(FILE);
# read modified list and list all modified files if non-empty
@modified = file_to_names(@branch_tags, "$tmpdir/modified.$i");
push(@text, "Modified files:", name_to_list(@branch_tags, @modified), "")
if (@modified > 0);
# read added list and list all added files if non-empty
@added = file_to_names(@branch_tags, "$tmpdir/added.$i");
push(@text, "Added files:", name_to_list(@branch_tags, @added), "")
if (@added > 0);
# read removed list and list all removed files if non-empty
@removed = file_to_names(@branch_tags, "$tmpdir/removed.$i");
push(@text, "Removed files:", name_to_list(@branch_tags, @removed), "")
if (@removed > 0);
# remember all the files we looked at
push(@files, @modified, @added, @removed);
}
# Now that name_to_list has rebuilt our list of branch tags, we can build the
# header and prepend it to the message
unshift(@text, build_header($modname, "Module $modname: Change committed",
\@mailto, @branch_tags));
# sort the files out for our diff
@files = sort { $a->{name} cmp $b->{name} } @files;
my ($user, $filename);
my ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = gmtime(time());
$user = getpwuid($<);
$filename = sprintf("%s.%04d%02d%02d.%02d%02d%02d.%s.diff", $modname,
$year + 1900, $mon + 1, $mday, $hour, $min, $sec, $user);
push(@text, "--$boundary");
push(@text, "Content-Type: text/plain; name=\"$filename\"");
push(@text, "Content-Disposition: attachment; filename=\"$filename\"");
push(@text, "Content-Transfer-Encoding: 8bit");
push(@text, "");
foreach my $file (@files) {
debug "Diffing file $file->{name}...\n";
# Run cvs rdiff, extracting a diff between the old version and the new
open(DIFF, "$CVS -Q rdiff -u -r $file->{old} -r $file->{new} " .
"$modname/$file->{name}|");
while (<DIFF>) {
chomp;
push(@text, $_);
}
close(DIFF);
}
# send the mail...
send_mail(\@mailto, \@text);
# and clean up after ourselves
cleanup_dir($tmpdir);
+9 -4
View File
@@ -1,4 +1,9 @@
drevil:nNwcK94cKMqZI:fs2source
inquisitor:Jh.dOjaiO2jHk:fs2source
anonymous:EqQXnO5cz9yBA:fs2source
drevil:f76FWdDTUBG5c:fs2source
mysterial:f7nJUwoIhmSrg:fs2source
wmcoolmon:f7JRB.js9Q1sE:fs2source
inquisitor:f7BVkOvwjDlWk:fs2source
penguin:Jh.dOjaiO2jHk:fs2source
DTP:f7M92Z/6/uep.:fs2source
unknownplayer:f79BgAn.IzJs6:fs2source
phreak:f7WQyGiT/jzlM:fs2source
anonymous:oIKtWP1q6GDt6:fs2source
+2 -1
View File
@@ -1,3 +1,4 @@
drevil
inquisitor
mysterial
penguin
+1274
View File
File diff suppressed because it is too large. Load diff
+148
View File
@@ -0,0 +1,148 @@
# Microsoft Developer Studio Project File - Name="Freespace2" - Package Owner=<4>
# Microsoft Developer Studio Generated Build File, Format Version 6.00
# ** DO NOT EDIT **
# TARGTYPE "Win32 (x86) Application" 0x0101
CFG=Freespace2 - Win32 Debug
!MESSAGE This is not a valid makefile. To build this project using NMAKE,
!MESSAGE use the Export Makefile command and run
!MESSAGE
!MESSAGE NMAKE /f "Freespace2.mak".
!MESSAGE
!MESSAGE You can specify a configuration when running NMAKE
!MESSAGE by defining the macro CFG on the command line. For example:
!MESSAGE
!MESSAGE NMAKE /f "Freespace2.mak" CFG="Freespace2 - Win32 Debug"
!MESSAGE
!MESSAGE Possible choices for configuration are:
!MESSAGE
!MESSAGE "Freespace2 - Win32 Release" (based on "Win32 (x86) Application")
!MESSAGE "Freespace2 - Win32 Debug" (based on "Win32 (x86) Application")
!MESSAGE
# Begin Project
# PROP AllowPerConfigDependencies 0
# PROP Scc_ProjName ""$/Freespace2", RHWBAAAA"
# PROP Scc_LocalPath "."
CPP=cl.exe
MTL=midl.exe
RSC=rc.exe
!IF "$(CFG)" == "Freespace2 - Win32 Release"
# PROP BASE Use_MFC 0
# PROP BASE Use_Debug_Libraries 0
# PROP BASE Output_Dir "Release"
# PROP BASE Intermediate_Dir "Release"
# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 0
# PROP Output_Dir "Release"
# PROP Intermediate_Dir "Release\Profile"
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /c
# ADD CPP /nologo /G5 /MT /W4 /GX /Zi /Ot /Ow /Og /Oi /Oy /I "code" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "WIN32" /U "_DEBUG" /YX /FD /c
# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
# ADD BASE RSC /l 0x409 /d "NDEBUG"
# ADD RSC /l 0x409 /d "NDEBUG"
BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo
LINK32=link.exe
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /machine:I386
# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib wsock32.lib winmm.lib vfw32.lib msacm32.lib comctl32.lib code.lib /nologo /subsystem:windows /map /machine:I386 /nodefaultlib:"libc.lib" /nodefaultlib:"libcd.lib" /out:"c:\games\freespace2\fs2_open.exe" /libpath:"release"
!ELSEIF "$(CFG)" == "Freespace2 - Win32 Debug"
# PROP BASE Use_MFC 0
# PROP BASE Use_Debug_Libraries 1
# PROP BASE Output_Dir "Debug"
# PROP BASE Intermediate_Dir "Debug"
# PROP BASE Target_Dir ""
# PROP Use_MFC 0
# PROP Use_Debug_Libraries 1
# PROP Output_Dir "Debug"
# PROP Intermediate_Dir "Debug\Profile"
# PROP Ignore_Export_Lib 0
# PROP Target_Dir ""
# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /YX /FD /GZ /c
# ADD CPP /nologo /G5 /MTd /W4 /Gm /Gi /GX /ZI /Od /I "code" /D "WIN32" /D "_WINDOWS" /D "_DEBUG" /D "NO_CD_CHECK" /D "USE_DX81" /U "NDEBUG" /Fr /YX /FD /GZ /c
# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
# ADD BASE RSC /l 0x409 /d "_DEBUG"
# ADD RSC /l 0x409 /d "_DEBUG"
BSC32=bscmake.exe
# ADD BASE BSC32 /nologo
# ADD BSC32 /nologo /o"debug/profile/Freespace2.bsc" "./debug/profile/*.sbr"
LINK32=link.exe
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /debug /machine:I386 /pdbtype:sept
# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib wsock32.lib winmm.lib vfw32.lib msacm32.lib comctl32.lib code.lib /nologo /subsystem:windows /debug /debugtype:both /machine:I386 /nodefaultlib:"libc.lib" /nodefaultlib:"libcd.lib" /out:"Debug/fs2_open.exe" /libpath:"debug"
# SUBTRACT LINK32 /pdb:none /incremental:no /map
# Begin Custom Build - Copying $(InputPath) to c:\games\freespace2
InputPath=.\Debug\fs2_open.exe
SOURCE="$(InputPath)"
"c:\games\freespace2\fs2_open.exe" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
copy $(InputPath) c:\games\freespace2
# End Custom Build
!ENDIF
# Begin Target
# Name "Freespace2 - Win32 Release"
# Name "Freespace2 - Win32 Debug"
# Begin Source File
SOURCE=.\code\FREESPACE2\app_icon.ico
# End Source File
# Begin Source File
SOURCE=.\code\FREESPACE2\FreeSpace.cpp
# End Source File
# Begin Source File
SOURCE=.\code\FREESPACE2\FreeSpace.h
# End Source File
# Begin Source File
SOURCE=.\code\FREESPACE2\FreeSpace.rc
# End Source File
# Begin Source File
SOURCE=.\code\FREESPACE2\FreespaceResource.h
# End Source File
# Begin Source File
SOURCE=.\code\freespace2\goal_com.bmp
# End Source File
# Begin Source File
SOURCE=.\code\freespace2\goal_fail.bmp
# End Source File
# Begin Source File
SOURCE=.\code\freespace2\goal_inc.bmp
# End Source File
# Begin Source File
SOURCE=.\code\freespace2\goal_none.bmp
# End Source File
# Begin Source File
SOURCE=.\code\freespace2\goal_ord.bmp
# End Source File
# Begin Source File
SOURCE=.\code\FREESPACE2\LevelPaging.cpp
# End Source File
# Begin Source File
SOURCE=.\code\FREESPACE2\LevelPaging.h
# End Source File
# End Target
# End Project
+44
View File
@@ -0,0 +1,44 @@
Microsoft Developer Studio Workspace File, Format Version 6.00
# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE!
###############################################################################
Project: "Freespace2"=".\Freespace2.dsp" - Package Owner=<4>
Package=<5>
{{{
}}}
Package=<4>
{{{
Begin Project Dependency
Project_Dep_Name code
End Project Dependency
}}}
###############################################################################
Project: "code"=".\code\code.dsp" - Package Owner=<4>
Package=<5>
{{{
}}}
Package=<4>
{{{
}}}
###############################################################################
Global:
Package=<5>
{{{
}}}
Package=<3>
{{{
}}}
###############################################################################
+1
View File
@@ -78,3 +78,4 @@ mouse button down a little longer to get buttons to activate.
Mike Harris (HLP penguin)
02 June 2002
+342 -263
View File
@@ -1,376 +1,452 @@
TARGET = fs2
ifeq ($(USE_SOUND), 1)
SOUND_DEF=
SOUND_OBJS= \
gamesnd/eventmusic.o \
gamesnd/gamesnd.o \
object/objectsnd.o \
sound/acm.o \
sound/audiostr.o \
sound/ds.o \
sound/ds3d.o \
sound/dscap.o \
sound/midifile.o \
sound/rbaudio.o \
sound/rtvoice.o \
sound/sound.o \
sound/winmidi.o \
sound/winmidi_base.o \
vcodec/codec1.o
else
SOUND_DEF=-DNO_SOUND
SOUND_OBJS=
endif # USE_SOUND
ifeq ($(USE_JOYSTICK), 1)
JOYSTICK_DEF=
JOYSTICK_OBJS= \
io/joy.o \
io/joy_ff.o \
io/swff_lib.o
else
JOYSTICK_DEF=-DNO_JOYSTICK
JOYSTICK_OBJS=
endif # USE_JOYSTICK
ifeq ($(USE_NETWORK), 1)
# no support for standalone server yet... (UI is Win32 specific)
NETWORK_DEF=-DNO_STANDALONE
NETWORK_OBJS= \
hud/hudobserver.o \
network/multi.o \
network/multimsgs.o \
network/multiteamselect.o \
network/multiui.o \
network/multiutil.o \
network/multi_campaign.o \
network/multi_data.o \
network/multi_dogfight.o \
network/multi_endgame.o \
network/multi_ingame.o \
network/multi_kick.o \
network/multi_log.o \
network/multi_obj.o \
network/multi_observer.o \
network/multi_options.o \
network/multi_pause.o \
network/multi_pinfo.o \
network/multi_ping.o \
network/multi_pmsg.o \
network/multi_rate.o \
network/multi_respawn.o \
network/multi_team.o \
network/multi_voice.o \
network/multi_xfer.o \
network/psnet.o \
network/psnet2.o \
menuui/optionsmenumulti.o \
missionui/chatbox.o
#
# Network/stand_gui.o
#
else
NETWORK_DEF=-DNO_NETWORK -DNO_STANDALONE
NETWORK_OBJS=
endif # USE_NETWORK
ifeq ($(USE_OPENGL), 0)
OPENGL_DEF=
else
OPENGL_DEF=-DUSE_OPENGL
endif # USE_OPENGL
LDFLAGS = -g
LDLIBS = -L/usr/X11R6/lib -lSDL -lGL -lGLU -lpthread
CXXFLAGS = \
-g \
-I/usr/local/include/SDL \
-Iwindows_stub \
-IAnim -IAsteroid -IBmpman -ICFile -ICmdline -ICMeasure -IControlConfig \
-ICutscene -IDebris -IDebugConsole -IDirectX -IFireball -IGameHelp -IFREESPACE2 \
-IGameSequence -IGamesnd -IGlide -IGlobalIncs -IGraphics -IHud -IIo -IJumpNode \
-ILighting -IMath -IMenuUI -IMission -IMissionUI -IModel -INetwork -IObject \
-IObserver -IOsApi -IPalman -IParse -IParticle -IPcxUtils -IPhysics -IPlayerman \
-IPopup -IRadar -IRender -IShip -ISound -IStarfield -IStats -ITgaUtils -IUI -IVCodec \
-I. \
-fno-exceptions \
-IWeapon -ILocalization -INebula -IDemo -IInetfile -IExceptionHandler \
-D_DEBUG -DNO_CD_CHECK -UNDEBUG \
-DNO_DIRECT3D -DNO_SOUND -DNO_JOYSTICK -DNO_NETWORK
-DNO_DIRECT3D $(SOUND_DEF) $(JOYSTICK_DEF) $(NETWORK_DEF) $(OPENGL_DEF)
ANIM_OBJFILES = \
Anim/animplay.o \
Anim/packunpack.o
anim/animplay.o \
anim/packunpack.o
ASTEROID_OBJFILES = \
Asteroid/asteroid.o
asteroid/asteroid.o
BMPMAN_OBJFILES = \
Bmpman/bmpman.o
bmpman/bmpman.o
CFILE_OBJFILES = \
CFile/cfile.o \
CFile/cfilearchive.o \
CFile/cfilelist.o \
CFile/cfilesystem.o
cfile/cfile.o \
cfile/cfilearchive.o \
cfile/cfilelist.o \
cfile/cfilesystem.o
CMDLINE_OBJFILES = \
Cmdline/cmdline.o
cmdline/cmdline.o
CMEASURE_OBJFILES = \
CMeasure/cmeasure.o
cmeasure/cmeasure.o
CONTROLCONFIG_OBJFILES = \
ControlConfig/controlsconfig.o \
ControlConfig/controlsconfigcommon.o
controlconfig/controlsconfig.o \
controlconfig/controlsconfigcommon.o
CUTSCENE_OBJFILES = \
Cutscene/cutscenes.o
cutscene/cutscenes.o
DEBRIS_OBJFILES = \
Debris/debris.o
debris/debris.o
DEBUGCONSOLE_OBJFILES = \
DebugConsole/console.o
debugconsole/console.o
DEMO_OBJFILES = \
Demo/demo.o
demo/demo.o
EXCEPTIONHANDLER_OBJFILES = \
ExceptionHandler/exceptionhandler.o
exceptionhandler/exceptionhandler.o
FIREBALL_OBJFILES = \
Fireball/fireballs.o \
Fireball/warpineffect.o
fireball/fireballs.o \
fireball/warpineffect.o
GAMEHELP_OBJFILES = \
GameHelp/contexthelp.o \
GameHelp/gameplayhelp.o
gamehelp/contexthelp.o \
gamehelp/gameplayhelp.o
GAMESEQUENCE_OBJFILES = \
GameSequence/gamesequence.o
gamesequence/gamesequence.o
# Gamesnd/eventmusic.o
# Gamesnd/gamesnd.o
# gamesnd/eventmusic.o
# gamesnd/gamesnd.o
GAMESND_OBJFILES =
# glide/glide.o
GLIDE_OBJFILES =
#GLIDE_OBJFILES = \
# Glide/glide.o
# GlobalIncs/windebug.o
# globalincs/windebug.o
GLOBALINCS_OBJFILES = \
GlobalIncs/alphacolors.o \
GlobalIncs/crypt.o \
GlobalIncs/systemvars.o \
GlobalIncs/version.o
globalincs/alphacolors.o \
globalincs/crypt.o \
globalincs/systemvars.o \
globalincs/version.o
# Graphics/grd3d.o
# Graphics/grd3drender.o
# Graphics/grd3dtexture.o
# Graphics/grdirectdraw.o
# Graphics/grglide.o
# Graphics/grglidetexture.o
# Graphics/grsoft.o
# Graphics/scaler.o
# Graphics/tmapgenericscans.o
# Graphics/tmapscantiled128x128.o
# Graphics/tmapscantiled16x16.o
# Graphics/tmapscantiled256x256.o
# Graphics/tmapscantiled32x32.o
# Graphics/tmapscantiled64x64.o
# Graphics/tmapscanline.o
# Graphics/tmapper.o
# graphics/grd3d.o
# graphics/grd3drender.o
# graphics/grd3dtexture.o
# graphics/grdirectdraw.o
# graphics/grglide.o
# graphics/grglidetexture.o
# graphics/grsoft.o
# graphics/scaler.o
# graphics/tmapgenericscans.o
# graphics/tmapscantiled128x128.o
# graphics/tmapscantiled16x16.o
# graphics/tmapscantiled256x256.o
# graphics/tmapscantiled32x32.o
# graphics/tmapscantiled64x64.o
# graphics/tmapscanline.o
# graphics/tmapper.o
GRAPHICS_OBJFILES = \
Graphics/2d.o \
Graphics/aaline.o \
Graphics/bitblt.o \
Graphics/circle.o \
Graphics/colors.o \
Graphics/font.o \
Graphics/gradient.o \
Graphics/gropengl.o \
Graphics/grzbuffer.o \
Graphics/line.o \
Graphics/pixel.o \
Graphics/rect.o \
Graphics/shade.o
graphics/2d.o \
graphics/aaline.o \
graphics/bitblt.o \
graphics/circle.o \
graphics/colors.o \
graphics/font.o \
graphics/gradient.o \
graphics/gropengl.o \
graphics/grzbuffer.o \
graphics/line.o \
graphics/pixel.o \
graphics/rect.o \
graphics/shade.o
# Hud/hudobserver.o
# hud/hudobserver.o
HUD_OBJFILES = \
Hud/hud.o \
Hud/hudartillery.o \
Hud/hudbrackets.o \
Hud/hudconfig.o \
Hud/hudescort.o \
Hud/hudets.o \
Hud/hudlock.o \
Hud/hudmessage.o \
Hud/hudreticle.o \
Hud/hudshield.o \
Hud/hudsquadmsg.o \
Hud/hudtarget.o \
Hud/hudtargetbox.o \
Hud/hudwingmanstatus.o
hud/hud.o \
hud/hudartillery.o \
hud/hudbrackets.o \
hud/hudconfig.o \
hud/hudescort.o \
hud/hudets.o \
hud/hudlock.o \
hud/hudmessage.o \
hud/hudreticle.o \
hud/hudshield.o \
hud/hudsquadmsg.o \
hud/hudtarget.o \
hud/hudtargetbox.o \
hud/hudwingmanstatus.o
INETFILE_OBJFILES = \
Inetfile/cftp.o \
Inetfile/chttpget.o \
Inetfile/inetgetfile.o
inetfile/cftp.o \
inetfile/chttpget.o \
inetfile/inetgetfile.o
# Io/joy.o
# Io/joy_ff.o
# Io/swff_lib.o
# io/joy.o
# io/joy_ff.o
# io/swff_lib.o
IO_OBJFILES = \
Io/key.o \
Io/keycontrol.o \
Io/mouse.o \
Io/timer.o \
Io/xmouse.o
io/key.o \
io/keycontrol.o \
io/mouse.o \
io/timer.o \
io/xmouse.o
JUMPNODE_OBJFILES = \
JumpNode/jumpnode.o
jumpnode/jumpnode.o
LIGHTING_OBJFILES = \
Lighting/lighting.o
lighting/lighting.o
LOCALIZATION_OBJFILES = \
Localization/fhash.o \
Localization/localize.o
localization/fhash.o \
localization/localize.o
MATH_OBJFILES = \
Math/fix.o \
Math/floating.o \
Math/fvi.o \
Math/spline.o \
Math/staticrand.o \
Math/vecmat.o
math/fix.o \
math/floating.o \
math/fvi.o \
math/spline.o \
math/staticrand.o \
math/vecmat.o
# MenuUI/optionsmenumulti.o
# menuui/optionsmenumulti.o
MENUUI_OBJFILES = \
MenuUI/barracks.o \
MenuUI/credits.o \
MenuUI/fishtank.o \
MenuUI/mainhallmenu.o \
MenuUI/mainhalltemp.o \
MenuUI/optionsmenu.o \
MenuUI/playermenu.o \
MenuUI/readyroom.o \
MenuUI/snazzyui.o \
MenuUI/techmenu.o \
MenuUI/trainingmenu.o
menuui/barracks.o \
menuui/credits.o \
menuui/fishtank.o \
menuui/mainhallmenu.o \
menuui/mainhalltemp.o \
menuui/optionsmenu.o \
menuui/playermenu.o \
menuui/readyroom.o \
menuui/snazzyui.o \
menuui/techmenu.o \
menuui/trainingmenu.o
MISSION_OBJFILES = \
Mission/missionbriefcommon.o \
Mission/missioncampaign.o \
Mission/missiongoals.o \
Mission/missiongrid.o \
Mission/missionhotkey.o \
Mission/missionload.o \
Mission/missionlog.o \
Mission/missionmessage.o \
Mission/missionparse.o \
Mission/missiontraining.o
mission/missionbriefcommon.o \
mission/missioncampaign.o \
mission/missiongoals.o \
mission/missiongrid.o \
mission/missionhotkey.o \
mission/missionload.o \
mission/missionlog.o \
mission/missionmessage.o \
mission/missionparse.o \
mission/missiontraining.o
# MissionUI/chatbox.o
# missionui/chatbox.o
MISSIONUI_OBJFILES = \
MissionUI/missionbrief.o \
MissionUI/missioncmdbrief.o \
MissionUI/missiondebrief.o \
MissionUI/missionloopbrief.o \
MissionUI/missionpause.o \
MissionUI/missionrecommend.o \
MissionUI/missionscreencommon.o \
MissionUI/missionshipchoice.o \
MissionUI/missionstats.o \
MissionUI/missionweaponchoice.o \
MissionUI/redalert.o
missionui/missionbrief.o \
missionui/missioncmdbrief.o \
missionui/missiondebrief.o \
missionui/missionloopbrief.o \
missionui/missionpause.o \
missionui/missionrecommend.o \
missionui/missionscreencommon.o \
missionui/missionshipchoice.o \
missionui/missionstats.o \
missionui/missionweaponchoice.o \
missionui/redalert.o
MODEL_OBJFILES = \
Model/modelcollide.o \
Model/modelinterp.o \
Model/modeloctant.o \
Model/modelread.o
model/modelcollide.o \
model/modelinterp.o \
model/modeloctant.o \
model/modelread.o
NEBULA_OBJFILES = \
Nebula/neb.o \
Nebula/neblightning.o
nebula/neb.o \
nebula/neblightning.o
# Network/multi.o
# Network/multi_campaign.o
# Network/multi_data.o
# Network/multi_dogfight.o
# Network/multi_endgame.o
# Network/multi_ingame.o
# Network/multi_kick.o
# Network/multi_log.o
# Network/multimsgs.o
# Network/multi_obj.o
# Network/multi_observer.o
# Network/multi_oo.o
# Network/multi_options.o
# Network/multi_pause.o
# Network/multi_pinfo.o
# Network/multi_ping.o
# Network/multi_pmsg.o
# Network/multi_rate.o
# Network/multi_respawn.o
# Network/multi_team.o
# Network/multi_update.o
# Network/multi_voice.o
# Network/multi_xfer.o
# Network/multilag.o
# Network/multiteamselect.o
# Network/multiui.o
# Network/psnet.o
# Network/psnet2.o
# Network/stand_gui.o
# network/multi.o
# network/multi_campaign.o
# network/multi_data.o
# network/multi_dogfight.o
# network/multi_endgame.o
# network/multi_ingame.o
# network/multi_kick.o
# network/multi_log.o
# network/multimsgs.o
# network/multi_obj.o
# network/multi_observer.o
# network/multi_oo.o
# network/multi_options.o
# network/multi_pause.o
# network/multi_pinfo.o
# network/multi_ping.o
# network/multi_pmsg.o
# network/multi_rate.o
# network/multi_respawn.o
# network/multi_team.o
# network/multi_update.o
# network/multi_voice.o
# network/multi_xfer.o
# network/multilag.o
# network/multiteamselect.o
# network/multiui.o
# network/psnet.o
# network/psnet2.o
# network/stand_gui.o
NETWORK_OBJFILES = \
Network/multiutil.o
network/multiutil.o
# Object/objectsnd.o
# object/objectsnd.o
OBJECT_OBJFILES = \
Object/collidedebrisship.o \
Object/collidedebrisweapon.o \
Object/collideshipship.o \
Object/collideshipweapon.o \
Object/collideweaponweapon.o \
Object/objcollide.o \
Object/object.o \
Object/objectsort.o
object/collidedebrisship.o \
object/collidedebrisweapon.o \
object/collideshipship.o \
object/collideshipweapon.o \
object/collideweaponweapon.o \
object/objcollide.o \
object/object.o \
object/objectsort.o
OBSERVER_OBJFILES = \
Observer/observer.o
observer/observer.o
OSAPI_OBJFILES = \
OsApi/osapi_unix.o \
OsApi/osregistry_unix.o \
OsApi/outwnd_unix.o
osapi/osapi_unix.o \
osapi/osregistry_unix.o \
osapi/outwnd_unix.o
PALMAN_OBJFILES = \
Palman/palman.o
palman/palman.o
PARSE_OBJFILES = \
Parse/encrypt.o \
Parse/parselo.o \
Parse/sexp.o
parse/encrypt.o \
parse/parselo.o \
parse/sexp.o
PARTICLE_OBJFILES = \
Particle/particle.o
particle/particle.o
PCXUTILS_OBJFILES = \
PcxUtils/pcxutils.o
pcxutils/pcxutils.o
PHYSICS_OBJFILES = \
Physics/physics.o
physics/physics.o
PLAYERMAN_OBJFILES = \
Playerman/managepilot.o \
Playerman/playercontrol.o
playerman/managepilot.o \
playerman/playercontrol.o
POPUP_OBJFILES = \
Popup/popup.o \
Popup/popupdead.o
popup/popup.o \
popup/popupdead.o
RADAR_OBJFILES = \
Radar/radar.o
radar/radar.o
RENDER_OBJFILES = \
Render/3dclipper.o \
Render/3ddraw.o \
Render/3dlaser.o \
Render/3dmath.o \
Render/3dsetup.o
render/3dclipper.o \
render/3ddraw.o \
render/3dlaser.o \
render/3dmath.o \
render/3dsetup.o
SHIP_OBJFILES = \
Ship/afterburner.o \
Ship/ai.o \
Ship/aibig.o \
Ship/aicode.o \
Ship/aigoals.o \
Ship/awacs.o \
Ship/shield.o \
Ship/ship.o \
Ship/shipcontrails.o \
Ship/shipfx.o \
Ship/shiphit.o
ship/afterburner.o \
ship/ai.o \
ship/aibig.o \
ship/aicode.o \
ship/aigoals.o \
ship/awacs.o \
ship/shield.o \
ship/ship.o \
ship/shipcontrails.o \
ship/shipfx.o \
ship/shiphit.o
SOUND_OBJFILES = \
Sound/acm.o \
Sound/audiostr.o \
Sound/ds.o \
Sound/ds3d.o \
Sound/dscap.o \
Sound/midifile.o \
Sound/rbaudio.o \
Sound/rtvoice.o \
Sound/sound.o \
Sound/winmidi.o \
Sound/winmidi_base.o
sound/acm.o \
sound/audiostr.o \
sound/ds.o \
sound/ds3d.o \
sound/dscap.o \
sound/midifile.o \
sound/rbaudio.o \
sound/rtvoice.o \
sound/sound.o \
sound/winmidi.o \
sound/winmidi_base.o
STARFIELD_OBJFILES = \
Starfield/nebula.o \
Starfield/starfield.o \
Starfield/supernova.o
starfield/nebula.o \
starfield/starfield.o \
starfield/supernova.o
STATS_OBJFILES = \
Stats/medals.o \
Stats/scoring.o \
Stats/stats.o
stats/medals.o \
stats/scoring.o \
stats/stats.o
TGAUTILS_OBJFILES = \
TgaUtils/tgautils.o
tgautils/tgautils.o
UI_OBJFILES = \
UI/button.o \
UI/checkbox.o \
UI/gadget.o \
UI/icon.o \
UI/inputbox.o \
UI/keytrap.o \
UI/listbox.o \
UI/radio.o \
UI/scroll.o \
UI/slider.o \
UI/slider2.o \
UI/uidraw.o \
UI/uimouse.o \
UI/window.o
ui/button.o \
ui/checkbox.o \
ui/gadget.o \
ui/icon.o \
ui/inputbox.o \
ui/keytrap.o \
ui/listbox.o \
ui/radio.o \
ui/scroll.o \
ui/slider.o \
ui/slider2.o \
ui/uidraw.o \
ui/uimouse.o \
ui/window.o
VCODEC_OBJFILES = \
VCodec/codec1.o
vcodec/codec1.o
WEAPON_OBJFILES = \
Weapon/beam.o \
Weapon/corkscrew.o \
Weapon/emp.o \
Weapon/flak.o \
Weapon/muzzleflash.o \
Weapon/shockwave.o \
Weapon/swarm.o \
Weapon/trails.o \
Weapon/weapons.o
weapon/beam.o \
weapon/corkscrew.o \
weapon/emp.o \
weapon/flak.o \
weapon/muzzleflash.o \
weapon/shockwave.o \
weapon/swarm.o \
weapon/trails.o \
weapon/weapons.o
# SOUND_OBJFILES
# INETFILE_OBJFILES
@@ -478,11 +554,14 @@ LIB_OBJFILES = \
$(NEBULA_OBJFILES) \
$(LOCALIZATION_OBJFILES) \
$(TGAUTILS_OBJFILES) \
$(DEMO_OBJFILES)
$(DEMO_OBJFILES) \
$(SOUND_OBJS) \
$(JOYSTICK_OBJS) \
$(NETWORK_OBJS)
FREESPACE2_OBJFILES = \
FREESPACE2/freespace.o \
FREESPACE2/levelpaging.o
freespace2/freespace.o \
freespace2/levelpaging.o
STUB_OBJFILES = \
windows_stub/stubs.o
@@ -565,7 +644,7 @@ fs2: libcode.a $(FREESPACE2_OBJFILES) $(STUB_OBJFILES)
# exceptions to the rule...
FREESPACE2/freespace.o: FREESPACE2/freespace.cpp
freespace2/freespace.o: freespace2/freespace.cpp
$(CXX) $(CXXFLAGS) -fexceptions -c -o $@ $<
ANIM_OBJFILES: $(ANIM_OBJFILES)
+15 -12
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/Anim/AnimPlay.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:21 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* C module for playing back anim files
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:21 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:04 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -178,16 +181,16 @@
* $NoKeywords: $
*/
#include "animplay.h"
#include "linklist.h"
#include "timer.h"
#include "bmpman.h"
#include "2d.h"
#include "3d.h"
#include "grinternal.h"
#include "pcxutils.h"
#include "packunpack.h"
#include "cfile.h"
#include "anim/animplay.h"
#include "globalincs/linklist.h"
#include "io/timer.h"
#include "bmpman/bmpman.h"
#include "graphics/2d.h"
#include "render/3d.h"
#include "graphics/grinternal.h"
#include "pcxutils/pcxutils.h"
#include "anim/packunpack.h"
#include "cfile/cfile.h"
static color Color_xparent;
+6 -3
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/Anim/AnimPlay.h $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:21 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Header file for playing back anim files
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:21 penguin
* Warpcore CVS sync
*
* Revision 1.2 2002/05/03 22:07:07 mharris
* got some stuff to compile
*
@@ -99,7 +102,7 @@
#ifndef __ANIMPLAY_H__
#define __ANIMPLAY_H__
#include "pstypes.h"
#include "globalincs/pstypes.h"
struct anim;
struct anim_info;
+11 -8
View File
@@ -9,8 +9,8 @@
/*
* $Logfile: /Freespace2/code/Anim/PackUnpack.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:21 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Code for handling packing and unpacking in Hoffoss's RLE format, used for
@@ -18,6 +18,9 @@
* utilizing an Anim), and getting getting frames of the Anim.
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:21 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:04 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -149,12 +152,12 @@
* $NoKeywords: $
*/
#include "grinternal.h"
#include "bmpman.h"
#include "palman.h"
#include "2d.h"
#include "animplay.h"
#include "packunpack.h"
#include "graphics/grinternal.h"
#include "bmpman/bmpman.h"
#include "palman/palman.h"
#include "graphics/2d.h"
#include "anim/animplay.h"
#include "anim/packunpack.h"
int packer_code = PACKER_CODE;
int transparent_code = 254;
+6 -3
View File
@@ -9,8 +9,8 @@
/*
* $Logfile: /Freespace2/code/Anim/PackUnpack.h $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:21 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Code for handling packing and unpacking in Hoffoss's RLE format, used for
@@ -18,6 +18,9 @@
* utilizing an Anim), and getting getting frames of the Anim.
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:21 penguin
* Warpcore CVS sync
*
* Revision 1.2 2002/05/03 22:07:07 mharris
* got some stuff to compile
*
@@ -148,7 +151,7 @@
#ifndef __PACKUNPACK_H__
#define __PACKUNPACK_H__
#include "pstypes.h"
#include "globalincs/pstypes.h"
struct CFILE;
+26 -23
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/Asteroid/Asteroid.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:21 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* C module for asteroid code
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:21 penguin
* Warpcore CVS sync
*
* Revision 1.3 2002/05/10 20:42:43 mharris
* use "ifndef NO_NETWORK" all over the place
*
@@ -263,29 +266,29 @@
* $NoKeywords: $
*/
#include "asteroid.h"
#include "object.h"
#include "objcollide.h"
#include "freespace.h"
#include "timer.h"
#include "3d.h"
#include "fireballs.h"
#include "gamesnd.h"
#include "bmpman.h"
#include "particle.h"
#include "linklist.h"
#include "hudescort.h"
#include "shiphit.h"
#include "staticrand.h"
#include "systemvars.h"
#include "localize.h"
#include "scoring.h"
#include "hudtarget.h"
#include "asteroid/asteroid.h"
#include "object/object.h"
#include "object/objcollide.h"
#include "freespace2/freespace.h"
#include "io/timer.h"
#include "render/3d.h"
#include "fireball/fireballs.h"
#include "gamesnd/gamesnd.h"
#include "bmpman/bmpman.h"
#include "particle/particle.h"
#include "globalincs/linklist.h"
#include "hud/hudescort.h"
#include "ship/shiphit.h"
#include "math/staticrand.h"
#include "globalincs/systemvars.h"
#include "localization/localize.h"
#include "stats/scoring.h"
#include "hud/hudtarget.h"
#ifndef NO_NETWORK
#include "multiutil.h"
#include "multimsgs.h"
#include "multi.h"
#include "network/multiutil.h"
#include "network/multimsgs.h"
#include "network/multi.h"
#endif
#ifndef FS2_DEMO
+7 -4
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/Asteroid/Asteroid.h $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:21 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Header file for asteroids
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:21 penguin
* Warpcore CVS sync
*
* Revision 1.2 2002/05/03 22:07:08 mharris
* got some stuff to compile
*
@@ -122,8 +125,8 @@
#ifndef __ASTEROID_H__
#define __ASTEROID_H__
#include "ship.h"
#include "parselo.h" // for NAME_LENGTH
#include "ship/ship.h"
#include "parse/parselo.h" // for NAME_LENGTH
struct object;
struct polymodel;
+25 -19
View File
@@ -9,13 +9,19 @@
/*
* $Logfile: /Freespace2/code/Bmpman/BmpMan.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:21 $
* $Revision: 2.2 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Code to load and manage all bitmaps for the game
*
* $Log: not supported by cvs2svn $
* Revision 2.1 2002/07/07 19:55:58 penguin
* Back-port to MSVC
*
* Revision 2.0 2002/06/03 04:02:21 penguin
* Warpcore CVS sync
*
* Revision 1.4 2002/05/21 15:36:25 mharris
* Added ifdef WIN32
*
@@ -471,20 +477,20 @@
*/
#include <ctype.h>
#include "pstypes.h"
#include "pcxutils.h"
#include "bmpman.h"
#include "palman.h"
#include "2d.h"
#include "animplay.h"
#include "timer.h"
#include "systemvars.h"
#include "key.h"
#include "packunpack.h"
#include "cfile.h"
#include "grinternal.h"
#include "tgautils.h"
#include "ship.h"
#include "globalincs/pstypes.h"
#include "pcxutils/pcxutils.h"
#include "bmpman/bmpman.h"
#include "palman/palman.h"
#include "graphics/2d.h"
#include "anim/animplay.h"
#include "io/timer.h"
#include "globalincs/systemvars.h"
#include "io/key.h"
#include "anim/packunpack.h"
#include "cfile/cfile.h"
#include "graphics/grinternal.h"
#include "tgautils/tgautils.h"
#include "ship/ship.h"
#ifndef NDEBUG
#define BMPMAN_NDEBUG
@@ -2337,7 +2343,7 @@ void BM_SELECT_SCREEN_FORMAT()
Gr_current_alpha = &Gr_alpha;
// setup pointers
#ifdef WIN32
#ifdef _WIN32
if(gr_screen.mode == GR_GLIDE){
bm_set_components = bm_set_components_argb;
} else if(gr_screen.mode == GR_DIRECT3D){
@@ -2368,7 +2374,7 @@ void BM_SELECT_TEX_FORMAT()
Gr_current_alpha = &Gr_t_alpha;
// setup pointers
#ifdef WIN32
#ifdef _WIN32
if(gr_screen.mode == GR_GLIDE){
bm_set_components = bm_set_components_argb;
} else if(gr_screen.mode == GR_DIRECT3D){
@@ -2399,7 +2405,7 @@ void BM_SELECT_ALPHA_TEX_FORMAT()
Gr_current_alpha = &Gr_ta_alpha;
// setup pointers
#ifdef WIN32
#ifdef _WIN32
if(gr_screen.mode == GR_GLIDE){
bm_set_components = bm_set_components_argb;
} else if(gr_screen.mode == GR_DIRECT3D){
+37 -25
View File
@@ -9,13 +9,22 @@
/*
* $Logfile: /Freespace2/code/CFile/cfile.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:21 $
* $Revision: 2.3 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Utilities for operating on files
*
* $Log: not supported by cvs2svn $
* Revision 2.2 2002/07/29 19:04:48 penguin
* added #ifdef _WIN32 around windows-specific system headers
*
* Revision 2.1 2002/07/07 19:55:58 penguin
* Back-port to MSVC
*
* Revision 2.0 2002/06/03 04:02:21 penguin
* Warpcore CVS sync
*
* Revision 1.7 2002/05/21 15:37:14 mharris
* Cosmetics - reformat Pathtypes to line up again
*
@@ -182,11 +191,14 @@
#include <stdlib.h>
#include <string.h>
#include <stdio.h>
#include <errno.h>
#ifdef _WIN32
#include <io.h>
#include <direct.h>
#include <errno.h>
#include <windows.h>
#include <winbase.h> /* needed for memory mapping of file functions */
#endif
#ifdef unix
#include <sys/stat.h>
@@ -194,15 +206,15 @@
#include <sys/mman.h>
#endif
#include "pstypes.h"
#include "cfile.h"
#include "encrypt.h"
#include "globalincs/pstypes.h"
#include "cfile/cfile.h"
#include "parse/encrypt.h"
//#include "outwnd.h"
//#include "vecmat.h"
//#include "timer.h"
#include "cfilesystem.h"
#include "cfilearchive.h"
#include "osapi.h"
#include "cfile/cfilesystem.h"
#include "cfile/cfilearchive.h"
#include "osapi/osapi.h"
char Cfile_root_dir[CFILE_ROOT_DIRECTORY_LEN] = "";
@@ -273,7 +285,7 @@ int cfget_cfile_block();
CFILE *cf_open_fill_cfblock(FILE * fp, int type);
CFILE *cf_open_packed_cfblock(FILE *fp, int type, int offset, int size);
#if defined WIN32
#if defined _WIN32
CFILE *cf_open_mapped_fill_cfblock(HANDLE hFile, int type);
#elif defined unix
CFILE *cf_open_mapped_fill_cfblock(FILE *fp, int type);
@@ -343,7 +355,7 @@ int cfile_init(char *exe_dir, char *cdrom_dir)
// are we in a root directory?
if(cfile_in_root_dir(buf)){
#if defined WIN32
#if defined _WIN32
MessageBox((HWND)NULL, "Freespace2/Fred2 cannot be run from a drive root directory!", "Error", MB_OK);
#elif defined unix
fprintf(stderr, "Error: Freespace2/Fred2 cannot be run from a drive root directory!\n");
@@ -361,7 +373,7 @@ int cfile_init(char *exe_dir, char *cdrom_dir)
buf[i] = 0;
cfile_chdir(buf);
} else {
#if defined WIN32
#if defined _WIN32
MessageBox((HWND)NULL, "Error trying to determine executable root directory!", "Error", MB_OK);
#elif defined unix
fprintf(stderr, "Error trying to determine executable root directory!\n");
@@ -397,7 +409,7 @@ void cfile_refresh()
}
#ifdef WIN32
#ifdef _WIN32
// Changes to a drive if valid.. 1=A, 2=B, etc
// If flag, then changes to it.
// Returns 0 if not-valid, 1 if valid.
@@ -443,7 +455,7 @@ int cfile_push_chdir(int type)
Drive = strchr(dir, ':');
if (Drive) {
#ifdef WIN32
#ifdef _WIN32
if (!cfile_chdrive( *(Drive - 1) - 'a' + 1, 1))
return 1;
@@ -460,7 +472,7 @@ int cfile_push_chdir(int type)
// This chdir might get a critical error!
e = _chdir( Path );
if (e) {
#ifdef WIN32
#ifdef _WIN32
cfile_chdrive( OriginalDirectory[0] - 'a' + 1, 1 );
#endif
return 2;
@@ -482,7 +494,7 @@ int cfile_chdir(char *dir)
Drive = strchr(dir, ':');
if (Drive) {
#ifdef WIN32
#ifdef _WIN32
if (!cfile_chdrive( *(Drive - 1) - 'a' + 1, 1))
return 1;
@@ -499,7 +511,7 @@ int cfile_chdir(char *dir)
// This chdir might get a critical error!
e = _chdir( Path );
if (e) {
#ifdef WIN32
#ifdef _WIN32
cfile_chdrive( OriginalDirectory[0] - 'a' + 1, 1 );
#endif
return 2;
@@ -531,7 +543,7 @@ int cfile_flush_dir(int dir_type)
// proceed to delete the files
del_count = 0;
#if defined WIN32
#if defined _WIN32
_finddata_t find;
find_handle = _findfirst( "*", &find );
if (find_handle != -1) {
@@ -648,7 +660,7 @@ int cf_exist( char *filename, int dir_type )
return 0;
}
#ifdef WIN32
#ifdef _WIN32
void cf_attrib(char *filename, int set, int clear, int dir_type)
{
char longname[MAX_PATH_LEN];
@@ -819,7 +831,7 @@ CFILE *cfopen(char *file_path, char *mode, int type, int dir_type, bool localize
// Can't open memory mapped files out of pack files
if ( offset == 0 ) {
#if defined WIN32
#if defined _WIN32
HANDLE hFile;
hFile = CreateFile(longname, GENERIC_READ, FILE_SHARE_READ, NULL, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, NULL);
@@ -922,7 +934,7 @@ int cfclose( CFILE * cfile )
result = 0;
if ( cb->data ) {
// close memory mapped file
#if defined WIN32
#if defined _WIN32
result = UnmapViewOfFile((void*)cb->data);
Assert(result);
result = CloseHandle(cb->hInFile);
@@ -973,7 +985,7 @@ CFILE *cf_open_fill_cfblock(FILE *fp, int type)
cfbp->fp = fp;
cfbp->dir_type = type;
#if defined WIN32
#if defined _WIN32
cf_init_lowlevel_read_code(cfp,0,filelength(fileno(fp)) );
#elif defined unix
struct stat statbuf;
@@ -1026,7 +1038,7 @@ CFILE *cf_open_packed_cfblock(FILE *fp, int type, int offset, int size)
//
// returns: ptr CFILE structure.
//
#if defined WIN32
#if defined _WIN32
CFILE *cf_open_mapped_fill_cfblock(HANDLE hFile, int type)
#elif defined unix
CFILE *cf_open_mapped_fill_cfblock(FILE *fp, int type)
@@ -1046,13 +1058,13 @@ CFILE *cf_open_mapped_fill_cfblock(FILE *fp, int type)
cfp = &Cfile_list[cfile_block_index];
cfp->id = cfile_block_index;
cfbp->fp = NULL;
#if defined WIN32
#if defined _WIN32
cfbp->hInFile = hFile;
#endif
cfbp->dir_type = type;
cf_init_lowlevel_read_code(cfp,0 , 0 );
#if defined WIN32
#if defined _WIN32
cfbp->hMapFile = CreateFileMapping(cfbp->hInFile, NULL, PAGE_READONLY, 0, 0, NULL);
if (cfbp->hMapFile == NULL) {
nprintf(("Error", "Could not create file-mapping object.\n"));
+11 -5
View File
@@ -9,13 +9,19 @@
/*
* $Logfile: /Freespace2/code/CFile/cfile.h $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:21 $
* $Revision: 2.2 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* <insert description of file here>
*
* $Log: not supported by cvs2svn $
* Revision 2.1 2002/07/07 19:55:58 penguin
* Back-port to MSVC
*
* Revision 2.0 2002/06/03 04:02:21 penguin
* Warpcore CVS sync
*
* Revision 1.3 2002/05/16 06:03:29 mharris
* Unix port changes
*
@@ -338,9 +344,9 @@
#define __CFILE_H__
#include <time.h>
#include "pstypes.h"
#include "globalincs/pstypes.h"
#if defined WIN32
#if defined _WIN32
#define DIR_SEPARATOR_CHAR '\\'
#define DIR_SEPARATOR_STR "\\"
#elif defined unix
@@ -608,7 +614,7 @@ int cf_find_file_location( char *filespec, int pathtype, char *pack_filename, in
// Functions to change directories
int cfile_chdir(char *dir);
#ifdef WIN32
#ifdef _WIN32
int cfile_chdrive(int DriveNum, int flag);
#endif
+14 -8
View File
@@ -9,14 +9,20 @@
/*
* $Logfile: /Freespace2/code/CFile/CfileArchive.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:21 $
* $Revision: 2.2 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Low-level code for reading data out of large archive files or normal files. All
* reads/seeks come through here.
*
* $Log: not supported by cvs2svn $
* Revision 2.1 2002/07/29 19:17:21 penguin
* added #ifdef _WIN32 around windows-specific system headers
*
* Revision 2.0 2002/06/03 04:02:21 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:04 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -79,17 +85,17 @@
#include <stdlib.h>
#include <string.h>
#include <stdio.h>
#ifdef _WIN32
#include <io.h>
#include <direct.h>
#include <windows.h>
#include <winbase.h> /* needed for memory mapping of file functions */
#endif
#include "pstypes.h"
#include "cfile.h"
//#include "outwnd.h"
//#include "vecmat.h"
//#include "timer.h"
#include "cfilearchive.h"
#include "globalincs/pstypes.h"
#include "cfile/cfile.h"
#include "cfile/cfilearchive.h"
#define CHECK_POSITION
+6 -3
View File
@@ -9,14 +9,17 @@
/*
* $Logfile: /Freespace2/code/CFile/CfileArchive.h $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:21 $
* $Revision: 2.1 $
* $Date: 2002-07-07 19:55:58 $
* $Author: penguin $
*
* External def's for CfileArchive.cpp. This should only be used
* internally by cfile stuff.
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:21 penguin
* Warpcore CVS sync
*
* Revision 1.2 2002/05/17 02:56:19 mharris
* first crack at unix compatibity
*
@@ -63,7 +66,7 @@ typedef struct Cfile_block {
int dir_type; // directory location
FILE *fp; // File pointer if opening an individual file
void *data; // Pointer for memory-mapped file access. NULL if not mem-mapped.
#ifdef WIN32
#ifdef _WIN32
HANDLE hInFile; // Handle from CreateFile()
HANDLE hMapFile; // Handle from CreateFileMapping()
#else
+13 -7
View File
@@ -9,13 +9,19 @@
/*
* $Logfile: /Freespace2/code/CFile/CfileList.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:21 $
* $Revision: 2.2 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Code for doing directory lists and sorts
*
* $Log: not supported by cvs2svn $
* Revision 2.1 2002/07/29 19:37:21 penguin
* added #ifdef _WIN32 around windows-specific system headers
*
* Revision 2.0 2002/06/03 04:02:21 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:04 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -57,16 +63,16 @@
#include <stdlib.h>
#include <string.h>
#include <stdio.h>
#ifdef _WIN32
#include <io.h>
#include <direct.h>
#include <windows.h>
#include <winbase.h> /* needed for memory mapping of file functions */
#endif
#include "pstypes.h"
#include "cfile.h"
//#include "outwnd.h"
//#include "vecmat.h"
//#include "timer.h"
#include "globalincs/pstypes.h"
#include "cfile/cfile.h"
// Sorts a list of filenames using the specified sorting method (CF_SORT_*).
// n = number of filenames in list to sort
+26 -17
View File
@@ -9,8 +9,8 @@
/*
* $Logfile: /Freespace2/code/CFile/CfileSystem.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:21 $
* $Revision: 2.3 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Functions to keep track of and find files that can exist
@@ -20,6 +20,15 @@
* all those locations, inherently enforcing precedence orders.
*
* $Log: not supported by cvs2svn $
* Revision 2.2 2002/07/29 19:52:48 penguin
* added #ifdef _WIN32 around windows-specific system headers
*
* Revision 2.1 2002/07/07 19:55:58 penguin
* Back-port to MSVC
*
* Revision 2.0 2002/06/03 04:02:21 penguin
* Warpcore CVS sync
*
* Revision 1.6 2002/05/24 16:44:10 mharris
* Fix unix "find files" operations so they return relative path
*
@@ -100,24 +109,24 @@
#include <stdlib.h>
#include <string.h>
#include <stdio.h>
#include <errno.h>
#ifdef _WIN32
#include <io.h>
#include <direct.h>
#include <windows.h>
#include <winbase.h> /* needed for memory mapping of file functions */
#include <errno.h>
#endif
#ifdef unix
#include <glob.h>
#include <sys/stat.h>
#endif
#include "pstypes.h"
//#include "outwnd.h"
//#include "vecmat.h"
//#include "timer.h"
#include "cfile.h"
#include "cfilesystem.h"
#include "localize.h"
#include "globalincs/pstypes.h"
#include "cfile/cfile.h"
#include "cfile/cfilesystem.h"
#include "localization/localize.h"
#define CF_ROOTTYPE_PATH 0
#define CF_ROOTTYPE_PACK 1
@@ -245,7 +254,7 @@ int cf_get_packfile_count(cf_root *root)
strcat( filespec, DIR_SEPARATOR_STR );
}
#if defined WIN32
#if defined _WIN32
strcat( filespec, "*.vp" );
int find_handle;
@@ -334,7 +343,7 @@ void cf_build_pack_list( cf_root *root )
strcat( filespec, DIR_SEPARATOR_STR );
}
#if defined WIN32
#if defined _WIN32
strcat( filespec, "*.vp" );
int find_handle;
@@ -496,7 +505,7 @@ void cf_search_root_path(int root_index)
strcat( search_path, DIR_SEPARATOR_STR );
}
#if defined WIN32
#if defined _WIN32
strcat( search_path, "*.*" );
int find_handle;
@@ -773,7 +782,7 @@ int cf_find_file_location( char *filespec, int pathtype, char *pack_filename, in
FILE *fp = fopen(filespec, "rb" );
if (fp) {
if ( size ) {
#if defined WIN32
#if defined _WIN32
*size = filelength(fileno(fp));
#elif defined unix
struct stat statbuf;
@@ -814,7 +823,7 @@ int cf_find_file_location( char *filespec, int pathtype, char *pack_filename, in
FILE *fp = fopen(longname, "rb" );
if (fp) {
if ( size ) {
#if defined WIN32
#if defined _WIN32
*size = filelength(fileno(fp));
#elif defined unix
struct stat statbuf;
@@ -958,7 +967,7 @@ int cf_get_file_list( int max, char **list, int pathtype, char *filter, int sort
cf_create_default_path_string( filespec, pathtype, filter );
#if defined WIN32
#if defined _WIN32
_finddata_t find;
find_handle = _findfirst( filespec, &find );
if (find_handle != -1) {
@@ -1138,7 +1147,7 @@ int cf_get_file_list_preallocated( int max, char arr[][MAX_FILENAME_LEN], char *
pathtype, filter));
// Search the default directories
#if defined WIN32
#if defined _WIN32
int find_handle;
_finddata_t find;
+35 -12
View File
@@ -9,11 +9,23 @@
/*
* $Logfile: /Freespace2/code/Cmdline/cmdline.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:21 $
* $Author: penguin $
* $Revision: 2.4 $
* $Date: 2002-08-07 00:44:13 $
* $Author: DTP $
*
* $Log: not supported by cvs2svn $
* Revision 2.3 2002/08/01 01:41:04 penguin
* The big include file move
*
* Revision 2.2 2002/07/29 06:35:15 DTP
* added -almission commandline arguement, will autoload mission i.e fs2_open.exe -almission kickass will autoload kickass.fs2 which should be a multiplayer mission.
*
* Revision 2.1 2002/07/07 19:55:58 penguin
* Back-port to MSVC
*
* Revision 2.0 2002/06/03 04:02:21 penguin
* Warpcore CVS sync
*
* Revision 1.3 2002/05/08 17:29:17 mharris
* more port tweaks
*
@@ -196,12 +208,12 @@
#include <string.h>
#include <stdlib.h>
#include "pstypes.h"
#include "cmdline.h"
#include "linklist.h"
#include "systemvars.h"
#include "multi.h"
#include "cfile.h"
#include "globalincs/pstypes.h"
#include "cmdline/cmdline.h"
#include "globalincs/linklist.h"
#include "globalincs/systemvars.h"
#include "network/multi.h"
#include "cfile/cfile.h"
// variables
class cmdline_parm {
@@ -241,6 +253,8 @@ cmdline_parm d3d_32bit("-32bit", NULL);
cmdline_parm mouse_coords("-coords", NULL);
cmdline_parm timeout("-timeout", NULL);
cmdline_parm d3d_window("-window", NULL);
cmdline_parm almission_arg("-almission", NULL); //DTP for autoload Multi mission
cmdline_parm gf4fix_arg("-GF4FIX", NULL); //DTP for random tigers GF4fix
int Cmdline_multi_stream_chat_to_file = 0;
int Cmdline_freespace_no_sound = 0;
@@ -258,6 +272,7 @@ char *Cmdline_game_password = NULL;
char *Cmdline_rank_above= NULL;
char *Cmdline_rank_below = NULL;
char *Cmdline_connect_addr = NULL;
char *Cmdline_almission = NULL; //DTP for autoload multi mission.
int Cmdline_multi_log = 0;
int Cmdline_server_firing = 0;
int Cmdline_client_dodamage = 0;
@@ -267,6 +282,7 @@ int Cmdline_mouse_coords = 0;
int Cmdline_timeout = -1;
int Cmdline_window = 0;
int Cmdline_gf4fix = 0; // DTP for randomstigers GF4 fix.
static cmdline_parm Parm_list(NULL, NULL);
static int Parm_list_inited = 0;
@@ -482,13 +498,13 @@ char *cmdline_parm::str()
}
// external entry point into this modules
#ifdef WIN32
#ifdef _WIN32
int parse_cmdline(char *cmdline)
#else
int parse_cmdline(int argc, char *argv[])
#endif
{
#ifdef WIN32
#ifdef _WIN32
os_init_cmdline(cmdline);
#else
if (argc > 1) {
@@ -625,6 +641,13 @@ int parse_cmdline(int argc, char *argv[])
if(d3d_window.found()){
Cmdline_window = 1;
}
if(almission_arg.found()){//DTP for autoload mission // developer oritentated
Cmdline_almission = almission_arg.str();
Cmdline_use_last_pilot = 1;
Cmdline_start_netgame = 1;
}
if (gf4fix_arg.found() ) {
Cmdline_gf4fix = 1;
}
return 1;
}
+16 -4
View File
@@ -9,11 +9,20 @@
/*
* $Logfile: /Freespace2/code/Cmdline/cmdline.h $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:21 $
* $Author: penguin $
* $Revision: 2.3 $
* $Date: 2002-08-07 00:44:13 $
* $Author: DTP $
*
* $Log: not supported by cvs2svn $
* Revision 2.2 2002/07/29 06:35:15 DTP
* added -almission commandline arguement, will autoload mission i.e fs2_open.exe -almission kickass will autoload kickass.fs2 which should be a multiplayer mission.
*
* Revision 2.1 2002/07/07 19:55:58 penguin
* Back-port to MSVC
*
* Revision 2.0 2002/06/03 04:02:21 penguin
* Warpcore CVS sync
*
* Revision 1.2 2002/05/08 17:29:17 mharris
* more port tweaks
*
@@ -154,7 +163,7 @@
#ifndef FS_CMDLINE_HEADER_FILE
#define FS_CMDLINE_HEADER_FILE
#ifdef WIN32
#ifdef _WIN32
int parse_cmdline(char *cmdline);
#else
int parse_cmdline(int argc, char *argv[]);
@@ -191,5 +200,8 @@ extern int Cmdline_mouse_coords;
extern int Cmdline_timeout;
extern int Cmdline_window;
extern char *Cmdline_almission; //DTP for autoload mission
extern int Cmdline_gf4fix; //DTP for Random tigers GF4fix.
#endif
+25 -22
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/CMeasure/CMeasure.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:21 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Counter measures. Created by Mike Kulas, May 12, 1997.
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:21 penguin
* Warpcore CVS sync
*
* Revision 1.2 2002/05/03 22:07:08 mharris
* got some stuff to compile
*
@@ -205,26 +208,26 @@
* $NoKeywords: $
*/
#include "pstypes.h"
#include "systemvars.h"
#include "cmeasure.h"
#include "freespace.h"
#include "vecmat.h"
#include "2d.h"
#include "3d.h"
#include "model.h"
#include "physics.h"
#include "floating.h"
#include "model.h"
#include "ship.h"
#include "timer.h"
#include "fireballs.h"
#include "radar.h"
#include "missionparse.h" // For MAX_SPECIES_NAMES
#include "gamesnd.h"
#include "objectsnd.h"
#include "sound.h"
#include "staticrand.h"
#include "globalincs/pstypes.h"
#include "globalincs/systemvars.h"
#include "cmeasure/cmeasure.h"
#include "freespace2/freespace.h"
#include "math/vecmat.h"
#include "graphics/2d.h"
#include "render/3d.h"
#include "model/model.h"
#include "physics/physics.h"
#include "math/floating.h"
#include "model/model.h"
#include "ship/ship.h"
#include "io/timer.h"
#include "fireball/fireballs.h"
#include "radar/radar.h"
#include "mission/missionparse.h" // For MAX_SPECIES_NAMES
#include "gamesnd/gamesnd.h"
#include "object/objectsnd.h"
#include "sound/sound.h"
#include "math/staticrand.h"
cmeasure_info Cmeasure_info[MAX_CMEASURE_TYPES];
cmeasure Cmeasures[MAX_CMEASURES];
+7 -4
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/CMeasure/CMeasure.h $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:21 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Counter measures. Created by Mike Kulas, May 12, 1997.
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:21 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:04 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -112,8 +115,8 @@
#ifndef _CMEASURE_H
#define _CMEASURE_H
#include "parselo.h"
#include "object.h"
#include "parse/parselo.h"
#include "object/object.h"
#define MAX_CMEASURES 64
File diff suppressed because it is too large. Load diff
+29 -26
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/ControlConfig/ControlsConfig.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:21 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* C module for keyboard, joystick and mouse configuration
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:21 penguin
* Warpcore CVS sync
*
* Revision 1.4 2002/05/16 06:06:23 mharris
* ifndef NO_JOYSTICK
*
@@ -300,33 +303,33 @@
*
*/
#include "freespace.h"
#include "controlsconfig.h"
#include "gamesequence.h"
#include "player.h"
#include "2d.h"
#include "hudsquadmsg.h"
#include "key.h"
#include "timer.h"
#include "freespace2/freespace.h"
#include "controlconfig/controlsconfig.h"
#include "gamesequence/gamesequence.h"
#include "playerman/player.h"
#include "graphics/2d.h"
#include "hud/hudsquadmsg.h"
#include "io/key.h"
#include "io/timer.h"
#include "math.h"
#include "mouse.h"
#include "ui.h"
#include "joy.h"
#include "bmpman.h"
#include "sound.h"
#include "gamesnd.h"
#include "missionscreencommon.h"
#include "font.h"
#include "hud.h"
#include "managepilot.h"
#include "contexthelp.h"
#include "popup.h"
#include "uidefs.h"
#include "alphacolors.h"
#include "io/mouse.h"
#include "ui/ui.h"
#include "io/joy.h"
#include "bmpman/bmpman.h"
#include "sound/sound.h"
#include "gamesnd/gamesnd.h"
#include "missionui/missionscreencommon.h"
#include "graphics/font.h"
#include "hud/hud.h"
#include "playerman/managepilot.h"
#include "gamehelp/contexthelp.h"
#include "popup/popup.h"
#include "ui/uidefs.h"
#include "globalincs/alphacolors.h"
#ifndef NO_NETWORK
#include "multi_pmsg.h"
#include "multiutil.h"
#include "network/multi_pmsg.h"
#include "network/multiutil.h"
#endif
#define NUM_SYSTEM_KEYS 14
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/ControlConfig/ControlsConfigCommon.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:21 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* C module for keyboard, joystick and mouse configuration common stuff (between Fred and FreeSpace)
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:21 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:04 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -372,10 +375,10 @@
*
*/
#include "controlsconfig.h"
#include "key.h"
#include "joy.h"
#include "localize.h"
#include "controlconfig/controlsconfig.h"
#include "io/key.h"
#include "io/joy.h"
#include "localization/localize.h"
#define TARGET_TAB 0
#define SHIP_TAB 1
+6 -3
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/Cryptstring/cryptstring.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:21 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Applet for crypting strings.
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:21 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:04 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -28,7 +31,7 @@
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "crypt.h"
#include "globalincs/crypt.h"
int main(int argc, char **argv)
{
+22 -16
View File
@@ -9,13 +9,19 @@
/*
* $Logfile: /Freespace2/code/Cutscene/Cutscenes.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:21 $
* $Revision: 2.2 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Code for the cutscenes viewer screen
*
* $Log: not supported by cvs2svn $
* Revision 2.1 2002/07/07 19:55:58 penguin
* Back-port to MSVC
*
* Revision 2.0 2002/06/03 04:02:21 penguin
* Warpcore CVS sync
*
* Revision 1.4 2002/05/16 00:39:47 mharris
* Added ifdef WIN32 around cd stuff
*
@@ -144,19 +150,19 @@
* $NoKeywords: $
*/
#include "cutscenes.h"
#include "ui.h"
#include "cfile.h"
#include "gamesnd.h"
#include "gamesequence.h"
#include "freespace.h"
#include "key.h"
#include "bmpman.h"
#include "cutscene/cutscenes.h"
#include "ui/ui.h"
#include "cfile/cfile.h"
#include "gamesnd/gamesnd.h"
#include "gamesequence/gamesequence.h"
#include "freespace2/freespace.h"
#include "io/key.h"
#include "bmpman/bmpman.h"
// #include "movie.h"
#include "popup.h"
#include "mainhallmenu.h"
#include "alphacolors.h"
#include "localize.h"
#include "popup/popup.h"
#include "menuui/mainhallmenu.h"
#include "globalincs/alphacolors.h"
#include "localization/localize.h"
char *Cutscene_bitmap_name[GR_NUM_RESOLUTIONS] = {
"ViewFootage",
@@ -223,7 +229,7 @@ void cutscene_init()
// returns -1 on failure.
int cutscenes_get_cd_num( char *filename )
{
#ifdef WIN32
#ifdef _WIN32
#if defined(OEM_BUILD)
return 0; // only 1 cd for OEM
#else
@@ -357,7 +363,7 @@ static char *Text_lines[MAX_TEXT_LINES];
int cutscenes_validate_cd(char *mve_name, int prompt_for_cd)
{
#ifdef WIN32
#ifdef _WIN32
int cd_present = 0;
int cd_drive_num;
int cd_mve_is_on;
+6 -3
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/Cutscene/Cutscenes.h $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:21 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Code for the cutscenes viewer screen
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:21 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:04 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -50,7 +53,7 @@
#ifndef _FREESPACE_CUTSCENES_SCREEN_HEADER_FILE
#define _FREESPACE_CUTSCENES_SCREEN_HEADER_FILE
#include "parselo.h"
#include "parse/parselo.h"
#define MAX_CUTSCENES 10
+23 -20
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/Debris/Debris.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:21 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Code for the pieces of exploding object debris.
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:21 penguin
* Warpcore CVS sync
*
* Revision 1.4 2002/05/13 21:43:37 mharris
* A little more network and sound cleanup
*
@@ -217,26 +220,26 @@
* $NoKeywords: $
*/
#include "3d.h"
#include "bmpman.h"
#include "object.h"
#include "debris.h"
#include "fireballs.h"
#include "radar.h"
#include "missionparse.h" // For MAX_SPECIES_NAMES
#include "gamesnd.h"
#include "objectsnd.h"
#include "linklist.h"
#include "systemvars.h"
#include "particle.h"
#include "freespace.h"
#include "objcollide.h"
#include "timer.h"
#include "render/3d.h"
#include "bmpman/bmpman.h"
#include "object/object.h"
#include "debris/debris.h"
#include "fireball/fireballs.h"
#include "radar/radar.h"
#include "mission/missionparse.h" // For MAX_SPECIES_NAMES
#include "gamesnd/gamesnd.h"
#include "object/objectsnd.h"
#include "globalincs/linklist.h"
#include "globalincs/systemvars.h"
#include "particle/particle.h"
#include "freespace2/freespace.h"
#include "object/objcollide.h"
#include "io/timer.h"
#ifndef NO_NETWORK
#include "multi.h"
#include "multimsgs.h"
#include "multiutil.h"
#include "network/multi.h"
#include "network/multimsgs.h"
#include "network/multiutil.h"
#endif
#define MAX_LIFE 10.0f
+13 -10
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/DebugConsole/Console.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:21 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Routines for managing the debug console window.
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:21 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:04 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -101,14 +104,14 @@
#include <setjmp.h>
#include <string.h>
#include "pstypes.h"
#include "freespace.h"
#include "font.h"
#include "timer.h"
#include "2d.h"
#include "key.h"
#include "alphacolors.h"
#include "osapi.h"
#include "globalincs/pstypes.h"
#include "freespace2/freespace.h"
#include "graphics/font.h"
#include "io/timer.h"
#include "graphics/2d.h"
#include "io/key.h"
#include "globalincs/alphacolors.h"
#include "osapi/osapi.h"
#define MAX_COMMANDS 300
+23 -16
View File
@@ -9,12 +9,18 @@
/*
* $Logfile: /Freespace2/code/Demo/Demo.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:21 $
* $Revision: 2.2 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
*
* $Log: not supported by cvs2svn $
* Revision 2.1 2002/07/07 19:55:58 penguin
* Back-port to MSVC
*
* Revision 2.0 2002/06/03 04:02:21 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:04 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -41,20 +47,21 @@
* $NoKeywords: $
*/
#include "demo.h"
#include "missionload.h"
#include "ship.h"
#include "linklist.h"
#include "freespace.h"
#include "object.h"
#include "timer.h"
#include "gamesequence.h"
#include "systemvars.h"
#include "cfile.h"
#include "missionmessage.h"
#include "missionparse.h"
#include "shipfx.h"
#include "shiphit.h"
#include "globalincs/pstypes.h"
#include "demo/demo.h"
#include "mission/missionload.h"
#include "ship/ship.h"
#include "globalincs/linklist.h"
#include "freespace2/freespace.h"
#include "object/object.h"
#include "io/timer.h"
#include "gamesequence/gamesequence.h"
#include "globalincs/systemvars.h"
#include "cfile/cfile.h"
#include "mission/missionmessage.h"
#include "mission/missionparse.h"
#include "ship/shipfx.h"
#include "ship/shiphit.h"
// -----------------------------------------------------------------------------------------------------------------------------
// DEMO DEFINES/VARS
+2 -2
View File
@@ -97,8 +97,8 @@ typedef struct IDirect3DViewport2 *LPDIRECT3DVIEWPORT2;
#endif
#include "vd3dtypes.h"
#include "vd3dcaps.h"
#include "directx/vd3dtypes.h"
#include "directx/vd3dcaps.h"
#ifdef __cplusplus
extern "C" {
+1 -1
View File
@@ -13,7 +13,7 @@
/*
* Pull in DirectDraw include file automatically:
*/
#include "vddraw.h"
#include "directx/vddraw.h"
#pragma pack(4)
+5 -5
View File
@@ -6,7 +6,7 @@
* Content: Direct3D internal include file
*@@BEGIN_MSINTERNAL
*
* $Id: vd3di.h,v 2.0 2002-06-03 04:02:21 penguin Exp $
* $Id: vd3di.h,v 2.2 2002-08-01 01:41:04 penguin Exp $
*
* History:
* Date By Reason
@@ -33,11 +33,11 @@
#include "vddrawp.h"
#if 0
//@@END_MSINTERNAL
#include "vddraw.h"
#include "directx/vddraw.h"
//@@BEGIN_MSINTERNAL
#endif
//@@END_MSINTERNAL
#include "vd3d.h"
#include "directx/vd3d.h"
// @@BEGIN_MSINTERNAL
#if !defined(BUILD_RLAPI) && !defined(BUILD_DDDDK)
@@ -45,7 +45,7 @@
#include "rlreg.h"
#include "lists.h"
#include "object.h"
#include "object/object.h"
/*
@@ -383,7 +383,7 @@ typedef struct _DIRECT3DDEVICEI
D3DVALUE perspective_tolerance;
/* Library information */
#ifdef WIN32
#ifdef _WIN32
HINSTANCE hDrvDll;
char dllname[MAXPATH];
char base[256];
+2 -2
View File
@@ -10,8 +10,8 @@
#ifndef __D3DRM_H__
#define __D3DRM_H__
#include "vddraw.h"
#include "vd3drmobj.h"
#include "directx/vddraw.h"
#include "directx/vd3drmobj.h"
#ifdef __cplusplus
extern "C" {
+2 -2
View File
@@ -11,9 +11,9 @@
#define __D3DRMDEFS_H__
#include <stddef.h>
#include "vd3dtypes.h"
#include "directx/vd3dtypes.h"
#ifdef WIN32
#ifdef _WIN32
#define D3DRMAPI __stdcall
#else
#define D3DRMAPI
+2 -2
View File
@@ -13,8 +13,8 @@
#include <objbase.h> /* Use Windows header files */
#define VIRTUAL
#include "vd3drmdef.h"
#include "vd3d.h"
#include "directx/vd3drmdef.h"
#include "directx/vd3d.h"
#ifdef __cplusplus
extern "C" {
+6 -3
View File
@@ -10,13 +10,16 @@
#ifndef __D3DRMWIN_H__
#define __D3DRMWIN_H__
#ifdef _WIN32
#ifndef WIN32
#define WIN32
#endif
#endif
#include "vd3drm.h"
#include "vddraw.h"
#include "vd3d.h"
#include "directx/vd3drm.h"
#include "directx/vddraw.h"
#include "directx/vd3d.h"
/*
* GUIDS used by Direct3DRM Windows interface
+2 -2
View File
@@ -10,14 +10,14 @@
#ifndef _D3DTYPES_H_
#define _D3DTYPES_H_
#if (! defined WIN32) && (! defined WIN95)
#if (! defined _WIN32) && (! defined WIN95)
#include "subwtype.h"
#else
#include <windows.h>
#endif
#include <float.h>
#include "vddraw.h"
#include "directx/vddraw.h"
#pragma pack(4)
+1 -1
View File
@@ -8,7 +8,7 @@
#ifndef __DPLOBBY_INCLUDED__
#define __DPLOBBY_INCLUDED__
#include "vdplay.h"
#include "directx/vdplay.h"
#ifdef __cplusplus
extern "C" {
+1 -1
View File
@@ -10,7 +10,7 @@
#ifndef __DSOUND_INCLUDED__
#define __DSOUND_INCLUDED__
#include "vd3dtypes.h"
#include "directx/vd3dtypes.h"
#define COM_NO_WINDOWS_H
#include <objbase.h>
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/ExceptionHandler/ExceptionHandler.h $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-07-07 19:55:58 $
* $Author: penguin $
*
* Header file for program exception handling
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.2 2002/05/07 02:58:10 mharris
* ifdef around pragma
*
@@ -32,7 +35,7 @@
* $NoKeywords: $
*/
#ifdef MSVC
#ifdef _MSC_VER
#pragma once // Include this file only once
#endif
+23 -20
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/Fireball/FireBalls.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Code to move, render and otherwise deal with fireballs.
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.2 2002/05/03 22:07:08 mharris
* got some stuff to compile
*
@@ -321,24 +324,24 @@
#include <stdlib.h>
#include "vecmat.h"
#include "tmapper.h"
#include "2d.h"
#include "3d.h"
#include "bmpman.h"
#include "model.h"
#include "key.h"
#include "physics.h"
#include "floating.h"
#include "model.h"
#include "lighting.h"
#include "object.h"
#include "ship.h"
#include "systemvars.h"
#include "fireballs.h"
#include "linklist.h"
#include "gamesnd.h"
#include "localize.h"
#include "math/vecmat.h"
#include "graphics/tmapper.h"
#include "graphics/2d.h"
#include "render/3d.h"
#include "bmpman/bmpman.h"
#include "model/model.h"
#include "io/key.h"
#include "physics/physics.h"
#include "math/floating.h"
#include "model/model.h"
#include "lighting/lighting.h"
#include "object/object.h"
#include "ship/ship.h"
#include "globalincs/systemvars.h"
#include "fireball/fireballs.h"
#include "globalincs/linklist.h"
#include "gamesnd/gamesnd.h"
#include "localization/localize.h"
#define WARPHOLE_GROW_TIME (1.5f) // time for warphole to reach max size (also time to shrink to nothing once it begins to shrink)
+7 -4
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/Fireball/FireBalls.h $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Prototypes for fireball functions
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:07 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -157,8 +160,8 @@
#ifndef _FIREBALLS_H
#define _FIREBALLS_H
#include "object.h"
#include "cfile.h"
#include "object/object.h"
#include "cfile/cfile.h"
// these values correspond to the fireball.tbl entries
#define FIREBALL_EXPLOSION_MEDIUM 0 // Used for the 4 little explosions before a ship explodes
+23 -20
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/Fireball/WarpInEffect.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Code for rendering the warp in effects for ships
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.2 2002/05/03 22:07:08 mharris
* got some stuff to compile
*
@@ -114,24 +117,24 @@
*/
#include "vecmat.h"
#include "tmapper.h"
#include "2d.h"
#include "3d.h"
#include "bmpman.h"
#include "model.h"
#include "key.h"
#include "physics.h"
#include "floating.h"
#include "model.h"
#include "lighting.h"
#include "object.h"
#include "ship.h"
#include "systemvars.h"
#include "animplay.h"
#include "fireballs.h"
#include "linklist.h"
#include "timer.h"
#include "math/vecmat.h"
#include "graphics/tmapper.h"
#include "graphics/2d.h"
#include "render/3d.h"
#include "bmpman/bmpman.h"
#include "model/model.h"
#include "io/key.h"
#include "physics/physics.h"
#include "math/floating.h"
#include "model/model.h"
#include "lighting/lighting.h"
#include "object/object.h"
#include "ship/ship.h"
#include "globalincs/systemvars.h"
#include "anim/animplay.h"
#include "fireball/fireballs.h"
#include "globalincs/linklist.h"
#include "io/timer.h"
DCF(norm,"normalize a zero length vector")
{
+277 -206
View File
@@ -9,13 +9,31 @@
/*
* $Logfile: /Freespace2/code/Freespace2/FreeSpace.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.6 $
* $Date: 2002-08-13 03:34:00 $
* $Author: penguin $
*
* Freespace main body
*
* $Log: not supported by cvs2svn $
* Revision 2.5 2002/08/04 05:11:05 penguin
* Don't write version to registry; change way version string is formatted
*
* Revision 2.4 2002/08/01 01:41:04 penguin
* The big include file move
*
* Revision 2.3 2002/07/29 20:12:31 penguin
* added #ifdef _WIN32 around windows-specific system headers
*
* Revision 2.2 2002/07/22 01:39:24 penguin
* Added ifndef NO_STANDALONE
*
* Revision 2.1 2002/07/07 19:55:58 penguin
* Back-port to MSVC
*
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.16 2002/06/03 03:39:28 mharris
* Added pause code back in (now that fAppActive is working, and we're
* getting the correct keycode for the pause key)
@@ -467,163 +485,164 @@
*
*/
#include <windows.h>
static const char RCS_Name[] = "$Name: not supported by cvs2svn $";
#include <stdlib.h>
#include <process.h>
#include <time.h>
#include <direct.h>
#ifndef WIN32
#include <unistd.h>
#include <sys/stat.h>
#ifdef _WIN32
#include <windows.h>
#include <process.h>
#include <direct.h>
#include <io.h>
#else
#include <unistd.h>
#include <sys/stat.h>
#endif
#include "pstypes.h"
#include "systemvars.h"
#include "key.h"
#include "vecmat.h"
#include "2d.h"
#include "3d.h"
#include "starfield.h"
#include "lighting.h"
#include "weapon.h"
#include "ship.h"
#include "palman.h"
#include "osapi.h"
#include "fireballs.h"
#include "debris.h"
#include "timer.h"
#include "fix.h"
#include "floating.h"
#include "gamesequence.h"
#include "radar.h"
#include "optionsmenu.h"
#include "playermenu.h"
#include "trainingmenu.h"
#include "techmenu.h"
#include "ai.h"
#include "hud.h"
#include "hudmessage.h"
#include "psnet.h"
#include "missiongoals.h"
#include "missionparse.h"
#include "bmpman.h"
#include "joy.h"
#include "joy_ff.h"
#include "globalincs/pstypes.h"
#include "globalincs/systemvars.h"
#include "io/key.h"
#include "math/vecmat.h"
#include "graphics/2d.h"
#include "render/3d.h"
#include "starfield/starfield.h"
#include "lighting/lighting.h"
#include "weapon/weapon.h"
#include "ship/ship.h"
#include "palman/palman.h"
#include "osapi/osapi.h"
#include "fireball/fireballs.h"
#include "debris/debris.h"
#include "io/timer.h"
#include "math/fix.h"
#include "math/floating.h"
#include "gamesequence/gamesequence.h"
#include "radar/radar.h"
#include "menuui/optionsmenu.h"
#include "menuui/playermenu.h"
#include "menuui/trainingmenu.h"
#include "menuui/techmenu.h"
#include "ship/ai.h"
#include "hud/hud.h"
#include "hud/hudmessage.h"
#include "network/psnet.h"
#include "mission/missiongoals.h"
#include "mission/missionparse.h"
#include "bmpman/bmpman.h"
#include "io/joy.h"
#include "io/joy_ff.h"
#ifndef NO_NETWORK
# include "multi.h"
# include "multiutil.h"
# include "multimsgs.h"
# include "multiui.h"
# include "multi_xfer.h"
# include "multiteamselect.h"
# include "multilag.h"
# include "multi_ingame.h"
# include "multi_voice.h"
# include "multi_pmsg.h"
# include "multi_pause.h"
# include "multi_endgame.h"
# include "multi_respawn.h"
# include "multi_obj.h"
# include "multi_log.h"
# include "multi_dogfight.h"
# include "multi_rate.h"
# include "network/multi.h"
# include "network/multiutil.h"
# include "network/multimsgs.h"
# include "network/multiui.h"
# include "network/multi_xfer.h"
# include "network/multiteamselect.h"
# include "network/multilag.h"
# include "network/multi_ingame.h"
# include "network/multi_voice.h"
# include "network/multi_pmsg.h"
# include "network/multi_pause.h"
# include "network/multi_endgame.h"
# include "network/multi_respawn.h"
# include "network/multi_obj.h"
# include "network/multi_log.h"
# include "network/multi_dogfight.h"
# include "network/multi_rate.h"
#endif
#include "cfile.h"
#include "player.h"
#include "freespace.h"
#include "managepilot.h"
#include "sound.h"
#include "contexthelp.h"
#include "mouse.h"
#include "joy.h"
#include "missionbrief.h"
#include "missiondebrief.h"
#include "ui.h"
#include "missionshipchoice.h"
#include "model.h"
#include "hudconfig.h"
#include "controlsconfig.h"
#include "missionmessage.h"
#include "missiontraining.h"
#include "hudets.h"
#include "hudtarget.h"
#include "gamesnd.h"
#include "rbaudio.h"
#include "winmidi.h"
#include "eventmusic.h"
#include "animplay.h"
#include "missionweaponchoice.h"
#include "missionlog.h"
#include "audiostr.h"
#include "hudlock.h"
#include "missioncampaign.h"
#include "credits.h"
#include "missionhotkey.h"
#include "objectsnd.h"
#include "cmeasure.h"
#include "ai.h"
#include "linklist.h"
#include "shockwave.h"
#include "afterburner.h"
#include "scoring.h"
#include "stats.h"
#include "cmdline.h"
#include "timer.h"
#include "stand_gui.h"
#include "pcxutils.h"
#include "hudtargetbox.h"
#include "hudescort.h"
#include "sexp.h"
#include "medals.h"
#include "ds3d.h"
#include "shipfx.h"
#include "readyroom.h"
#include "mainhallmenu.h"
#include "trails.h"
#include "particle.h"
#include "popup.h"
#include "snazzyui.h"
#include "asteroid.h"
#include "popupdead.h"
#include "missioncmdbrief.h"
#include "redalert.h"
#include "gameplayhelp.h"
#include "staticrand.h"
#include "levelpaging.h"
#include "observer.h"
#include "cutscenes.h"
#include "cfile/cfile.h"
#include "playerman/player.h"
#include "freespace2/freespace.h"
#include "playerman/managepilot.h"
#include "sound/sound.h"
#include "gamehelp/contexthelp.h"
#include "io/mouse.h"
#include "io/joy.h"
#include "missionui/missionbrief.h"
#include "missionui/missiondebrief.h"
#include "ui/ui.h"
#include "missionui/missionshipchoice.h"
#include "model/model.h"
#include "hud/hudconfig.h"
#include "controlconfig/controlsconfig.h"
#include "mission/missionmessage.h"
#include "mission/missiontraining.h"
#include "hud/hudets.h"
#include "hud/hudtarget.h"
#include "gamesnd/gamesnd.h"
#include "sound/rbaudio.h"
#include "sound/winmidi.h"
#include "gamesnd/eventmusic.h"
#include "anim/animplay.h"
#include "missionui/missionweaponchoice.h"
#include "mission/missionlog.h"
#include "sound/audiostr.h"
#include "hud/hudlock.h"
#include "mission/missioncampaign.h"
#include "menuui/credits.h"
#include "mission/missionhotkey.h"
#include "object/objectsnd.h"
#include "cmeasure/cmeasure.h"
#include "ship/ai.h"
#include "globalincs/linklist.h"
#include "weapon/shockwave.h"
#include "ship/afterburner.h"
#include "stats/scoring.h"
#include "stats/stats.h"
#include "cmdline/cmdline.h"
#include "io/timer.h"
#include "network/stand_gui.h"
#include "pcxutils/pcxutils.h"
#include "hud/hudtargetbox.h"
#include "hud/hudescort.h"
#include "parse/sexp.h"
#include "stats/medals.h"
#include "sound/ds3d.h"
#include "ship/shipfx.h"
#include "menuui/readyroom.h"
#include "menuui/mainhallmenu.h"
#include "weapon/trails.h"
#include "particle/particle.h"
#include "popup/popup.h"
#include "menuui/snazzyui.h"
#include "asteroid/asteroid.h"
#include "popup/popupdead.h"
#include "missionui/missioncmdbrief.h"
#include "missionui/redalert.h"
#include "gamehelp/gameplayhelp.h"
#include "math/staticrand.h"
#include "freespace2/levelpaging.h"
#include "observer/observer.h"
#include "cutscene/cutscenes.h"
// #include "movie.h"
#include "emp.h"
#include "localize.h"
#include "osregistry.h"
#include "barracks.h"
#include "missionpause.h"
#include "font.h"
#include "alphacolors.h"
#include "objcollide.h"
#include "flak.h"
#include "neb.h"
#include "neblightning.h"
#include "shipcontrails.h"
#include "awacs.h"
#include "beam.h"
#include "muzzleflash.h"
#include "encrypt.h"
#include "demo.h"
#include "version.h"
#include "mainhalltemp.h"
#include "exceptionhandler.h"
#include "glide.h"
#include "supernova.h"
#include "hudshield.h"
#include <io.h>
// #include "names.h"
#include "shiphit.h"
#include "missionloopbrief.h"
#include "weapon/emp.h"
#include "localization/localize.h"
#include "osapi/osregistry.h"
#include "menuui/barracks.h"
#include "missionui/missionpause.h"
#include "graphics/font.h"
#include "globalincs/alphacolors.h"
#include "object/objcollide.h"
#include "weapon/flak.h"
#include "nebula/neb.h"
#include "nebula/neblightning.h"
#include "ship/shipcontrails.h"
#include "ship/awacs.h"
#include "weapon/beam.h"
#include "weapon/muzzleflash.h"
#include "parse/encrypt.h"
#include "demo/demo.h"
#include "globalincs/version.h"
#include "menuui/mainhalltemp.h"
#include "exceptionhandler/exceptionhandler.h"
#include "glide/glide.h"
#include "starfield/supernova.h"
#include "hud/hudshield.h"
#include "ship/shiphit.h"
#include "missionui/missionloopbrief.h"
#ifdef NDEBUG
#ifdef FRED
@@ -648,6 +667,21 @@
// OEM version:
// 1.00 5/28/98 AL. First release to Interplay QA.
#ifdef NO_SOUND
// defined here to avoid link errors
game_snd Snds[MAX_GAME_SOUNDS];
game_snd Snds_iface[MAX_INTERFACE_SOUNDS];
int Snds_iface_handle[MAX_INTERFACE_SOUNDS];
game_snd Snds_flyby[MAX_SPECIES_NAMES][2];
// dummy callback -- real one is in gamesnd.cpp
void common_play_highlight_sound()
{
}
#endif
void game_level_init(int seed = -1);
void game_post_level_init();
void game_do_frame();
@@ -675,7 +709,11 @@ int Game_skill_level = DEFAULT_SKILL_LEVEL;
float Viewer_zoom = VIEWER_ZOOM_DEFAULT;
#define EXE_FNAME ("fs2.exe")
#if 0 // no launcher for fs2_open
#define LAUNCHER_FNAME ("freespace2.exe")
#endif
// JAS: Code for warphole camera.
// Needs to be cleaned up.
@@ -1002,7 +1040,7 @@ static char *Game_demo_title_screen_fname[GR_NUM_RESOLUTIONS] = {
#endif
#ifdef WIN32
#ifdef _WIN32
// cdrom stuff
char Game_CDROM_dir[MAX_PATH_LEN];
int init_cdrom();
@@ -1078,7 +1116,7 @@ void game_framerate_check_init()
// nebula missions
if(The_mission.flags & MISSION_FLAG_FULLNEB){
#if defined WIN32
#if defined _WIN32
// if this is a glide card
if(gr_screen.mode == GR_GLIDE){
extern GrHwConfiguration hwconfig;
@@ -1102,7 +1140,7 @@ void game_framerate_check_init()
} else {
#ifdef WIN32
#ifdef _WIN32
// if this is a glide card
if(gr_screen.mode == GR_GLIDE){
extern GrHwConfiguration hwconfig;
@@ -2114,7 +2152,7 @@ void game_init()
//Initialize the libraries
s1 = timer_get_milliseconds();
#ifdef WIN32
#ifdef _WIN32
if(cfile_init(whee, Game_CDROM_dir)){ // initialize before calling any cfopen stuff!!!
#else
if(cfile_init(whee, NULL)){ // initialize before calling any cfopen stuff!!!
@@ -2123,7 +2161,7 @@ void game_init()
}
e1 = timer_get_milliseconds();
#ifndef NO_NETWORK
#if !defined(NO_NETWORK) && !defined(NO_STANDALONE)
if (Is_standalone) {
std_init_standalone();
}
@@ -2146,10 +2184,14 @@ void game_init()
// verify that he has a valid weapons.tbl
verify_weapons_tbl();
// Output version numbers to registry for auto patching purposes
os_config_write_uint(NOX("Version"), NOX("Major"), FS_VERSION_MAJOR);
os_config_write_uint(NOX("Version"), NOX("Minor"), FS_VERSION_MINOR);
os_config_write_uint(NOX("Version"), NOX("Build"), FS_VERSION_BUILD);
// commented out by penguin --
// we don't want to cause problems w/ retail version...
// we probably need our own registry key (and a launcher to write them)
// // Output version numbers to registry for auto patching purposes
// os_config_write_uint(NOX("Version"), NOX("Major"), FS_VERSION_MAJOR);
// os_config_write_uint(NOX("Version"), NOX("Minor"), FS_VERSION_MINOR);
// os_config_write_uint(NOX("Version"), NOX("Build"), FS_VERSION_BUILD);
Use_joy_mouse = 0; //os_config_read_uint( NULL, NOX("JoystickMovesCursor"), 1 );
//Use_palette_flash = os_config_read_uint( NULL, NOX("PaletteFlash"), 0 );
@@ -2192,8 +2234,10 @@ void game_init()
ptr = os_config_read_string(NULL, NOX("Videocard"), NULL);
if (ptr == NULL) {
#ifdef WIN32
MessageBox((HWND)os_get_window(), XSTR("Please configure your system in the Launcher before running FS2.\n\n The Launcher will now be started!", 1446), XSTR("Attention!", 1447), MB_OK);
#ifdef _WIN32
MessageBox((HWND)os_get_window(), XSTR("Please configure your system in the Launcher before running FS2.", 1446), XSTR("Attention!", 1447), MB_OK);
#if 0 // no launcher in fs2_open
// fire up the UpdateLauncher executable
STARTUPINFO si;
@@ -2218,9 +2262,12 @@ void game_init()
if (!ret) {
MessageBox((HWND)os_get_window(), XSTR("The Launcher could not be restarted.", 1450), XSTR("Error", 1451), MB_OK);
}
#endif
exit(1);
#else
mprintf(("No video card defined... exiting\n"));
#else // !Win32
mprintf(("No video card defined...\n"));
// TEMP mharris FIXME
ptr = "dummy";
// exit(1);
@@ -2228,7 +2275,7 @@ void game_init()
}
#ifdef WIN32
#ifdef _WIN32
// Only check for 3d-accel in Win32
if(!Is_standalone){
if(!stricmp(ptr, "Aucune accélération 3D") || !stricmp(ptr, "Keine 3D-Beschleunigerkarte") || !stricmp(ptr, "No 3D acceleration")){
@@ -2242,7 +2289,7 @@ void game_init()
int has_sparky_hi = 0;
// check if sparky_hi exists -- access mode 0 means does file exist
#ifdef WIN32
#ifdef _WIN32
{
char dir[128];
_getcwd(dir, 128);
@@ -2268,7 +2315,7 @@ void game_init()
depth = 32;
}
#ifdef WIN32
#ifdef _WIN32
// initialize the graphics system (win32)
int trying_d3d = 0;
@@ -2477,7 +2524,7 @@ void game_init()
// Game_music_paused = 0;
Game_paused = 0;
#ifdef WIN32
#ifdef _WIN32
timeBeginPeriod(1);
#endif
@@ -2698,7 +2745,7 @@ void game_show_framerate()
#endif
}
#ifndef NO_NETWORK
#if !defined(NO_NETWORK) && !defined(NO_STANDALONE)
void game_show_standalone_framerate()
{
float frame_rate=30.0f;
@@ -4403,7 +4450,7 @@ void game_frame()
#endif
} else {
#ifndef NO_NETWORK
#ifndef NO_STANDALONE
game_show_standalone_framerate();
#endif
}
@@ -4575,7 +4622,7 @@ void game_set_frametime(int state)
}
}
#ifndef NO_NETWORK
#if !defined(NO_NETWORK) && !defined(NO_STANDALONE)
if((Game_mode & GM_STANDALONE_SERVER) &&
(f2fl(Frametime) < ((float)1.0/(float)Multi_options_g.std_framecap))){
@@ -4628,7 +4675,7 @@ void game_do_frame()
game_set_frametime(GS_STATE_GAME_PLAY);
game_update_missiontime();
#ifndef NO_NETWORK
#if !defined(NO_NETWORK) && !defined(NO_STANDALONE)
if (Game_mode & GM_STANDALONE_SERVER) {
std_multi_set_standalone_missiontime(f2fl(Missiontime));
}
@@ -5831,7 +5878,7 @@ void game_leave_state( int old_state, int new_state )
cutscenes_screen_close();
break;
#ifndef NO_NETWORK
#ifndef NO_STANDALONE
case GS_STATE_MULTI_STD_WAIT:
multi_standalone_wait_close();
break;
@@ -5843,6 +5890,12 @@ void game_leave_state( int old_state, int new_state )
}
break;
case GS_STATE_STANDALONE_POSTGAME:
multi_standalone_postgame_close();
break;
#endif
#ifndef NO_NETWORK
case GS_STATE_MULTI_PAUSED:
// if ( end_mission ){
pause_close(1);
@@ -5852,10 +5905,6 @@ void game_leave_state( int old_state, int new_state )
case GS_STATE_INGAME_PRE_JOIN:
multi_ingame_select_close();
break;
case GS_STATE_STANDALONE_POSTGAME:
multi_standalone_postgame_close();
break;
#endif // ifndef NO_NETWORK
case GS_STATE_INITIAL_PLAYER_SELECT:
@@ -6294,7 +6343,7 @@ void mouse_force_pos(int x, int y);
cutscenes_screen_init();
break;
#ifndef NO_NETWORK
#ifndef NO_STANDALONE
case GS_STATE_MULTI_STD_WAIT:
multi_standalone_wait_init();
break;
@@ -6307,6 +6356,12 @@ void mouse_force_pos(int x, int y);
}
break;
case GS_STATE_STANDALONE_POSTGAME:
multi_standalone_postgame_init();
break;
#endif // ifndef NO_STANDALONE
#ifndef NO_NETWORK
case GS_STATE_MULTI_PAUSED:
pause_init(1);
break;
@@ -6314,10 +6369,6 @@ void mouse_force_pos(int x, int y);
case GS_STATE_INGAME_PRE_JOIN:
multi_ingame_select_init();
break;
case GS_STATE_STANDALONE_POSTGAME:
multi_standalone_postgame_init();
break;
#endif // ifndef NO_NETWORK
case GS_STATE_INITIAL_PLAYER_SELECT:
@@ -6568,7 +6619,7 @@ void game_do_state(int state)
cutscenes_screen_do_frame();
break;
#ifndef NO_NETWORK
#ifndef NO_STANDALONE
case GS_STATE_MULTI_STD_WAIT:
game_set_frametime(GS_STATE_STANDALONE_MAIN);
multi_standalone_wait_do();
@@ -6578,7 +6629,9 @@ void game_do_state(int state)
game_set_frametime(GS_STATE_STANDALONE_MAIN);
standalone_main_do();
break;
#endif // ifndef NO_STANDALONE
#ifndef NO_NETWORK
case GS_STATE_MULTI_PAUSED:
game_set_frametime(GS_STATE_MULTI_PAUSED);
pause_do(1);
@@ -6602,12 +6655,12 @@ void game_do_state(int state)
#endif
break;
#ifndef NO_NETWORK
#ifndef NO_STANDALONE
case GS_STATE_STANDALONE_POSTGAME:
game_set_frametime(GS_STATE_STANDALONE_POSTGAME);
multi_standalone_postgame_do();
break;
#endif // ifndef NO_NETWORK
#endif // ifndef NO_STANDALONE
case GS_STATE_INITIAL_PLAYER_SELECT:
game_set_frametime(GS_STATE_INITIAL_PLAYER_SELECT);
@@ -6649,7 +6702,7 @@ void game_do_state(int state)
}
#ifdef WIN32
#ifdef _WIN32
// return 0 if there is enough RAM to run FreeSpace, otherwise return -1
int game_do_ram_check(int ram_in_bytes)
{
@@ -6684,6 +6737,7 @@ int game_do_ram_check(int ram_in_bytes)
}
#if 0 // no updater for fs2
// Check if there is a freespace.exe in the /update directory (relative to where fs.exe is installed).
// If so, copy it over and remove the update directory.
void game_maybe_update_launcher(char *exe_dir)
@@ -6722,6 +6776,8 @@ void game_maybe_update_launcher(char *exe_dir)
strcat(update_dir, NOX("\\update"));
RemoveDirectory(update_dir);
}
#endif // no launcher
#endif // ifdef WIN32
void game_spew_pof_info_sub(int model_num, polymodel *pm, int sm, CFILE *out, int *out_total, int *out_destroyed_total)
@@ -6845,7 +6901,7 @@ DCF(pofspew, "")
game_spew_pof_info();
}
#ifdef WIN32
#ifdef _WIN32
int PASCAL WinMainSub(HINSTANCE hInst, HINSTANCE hPrev, LPSTR szCmdLine, int nCmdShow)
#else
int WinMainSub(int argc, char *argv[])
@@ -6853,7 +6909,7 @@ int WinMainSub(int argc, char *argv[])
{
int state;
#ifdef WIN32
#ifdef _WIN32
// Don't let more than one instance of Freespace run.
HWND hwnd = FindWindow( NOX( "FreeSpaceClass" ), NULL );
if ( hwnd ) {
@@ -6908,8 +6964,11 @@ int WinMainSub(int argc, char *argv[])
SetCurrentDirectory(exe_dir);
}
#if 0 // no launcher for fs2_open
// check for updated freespace.exe
game_maybe_update_launcher(exe_dir);
#endif
}
#else
// mharris TODO: how should we determine what the "right" directory is?
@@ -6924,7 +6983,7 @@ int WinMainSub(int argc, char *argv[])
#endif
#ifdef WIN32
#ifdef _WIN32
parse_cmdline(szCmdLine);
#else
parse_cmdline(argc, argv);
@@ -6943,7 +7002,7 @@ int WinMainSub(int argc, char *argv[])
#endif // ifndef NO_NETWORK
#ifdef WIN32
#ifdef _WIN32
init_cdrom();
#endif
@@ -6964,7 +7023,7 @@ int WinMainSub(int argc, char *argv[])
char *plist[5];
if( (cf_get_file_list(2, plist, CF_TYPE_MULTI_PLAYERS, NOX("*.plr")) <= 0) && (cf_get_file_list(2, plist, CF_TYPE_SINGLE_PLAYERS, NOX("*.plr")) <= 0) ){
// prompt for cd 2
#ifdef WIN32
#ifdef _WIN32
#if defined(OEM_BUILD)
game_do_cd_check_specific(FS_CDROM_VOLUME_1, 1);
#else
@@ -7026,14 +7085,14 @@ int WinMainSub(int argc, char *argv[])
#endif
game_shutdown();
#ifdef WIN32
#ifdef _WIN32
return 1;
#else
return 0;
#endif
}
#ifdef WIN32
#ifdef _WIN32
int PASCAL WinMain(HINSTANCE hInst, HINSTANCE hPrev, LPSTR szCmdLine, int nCmdShow)
#else
int main(int argc, char *argv[])
@@ -7041,7 +7100,7 @@ int main(int argc, char *argv[])
{
int result = -1;
#ifdef WIN32
#ifdef _WIN32
__try {
result = WinMainSub(hInst, hPrev, szCmdLine, nCmdShow);
} __except(RecordExceptionInfo(GetExceptionInformation(), "Freespace 2 Main Thread")) {
@@ -7063,8 +7122,8 @@ int main(int argc, char *argv[])
return result;
}
#ifdef WIN32
// launcher the fslauncher program on exit
#if 0 // don't have an updater for fs2_open
// launch the fslauncher program on exit
void game_launch_launcher_on_exit()
{
STARTUPINFO si;
@@ -7107,7 +7166,7 @@ void game_launch_launcher_on_exit()
//
void game_shutdown(void)
{
#ifdef WIN32
#ifdef _WIN32
timeEndPeriod(1);
#endif
@@ -7161,8 +7220,7 @@ void game_shutdown(void)
#endif
os_cleanup();
#ifdef WIN32
#ifndef NO_NETWORK
#if 0 // don't have an updater for fs2_open
// HACKITY HACK HACK
// if this flag is set, we should be firing up the launcher when exiting freespace
extern int Multi_update_fireup_launcher_on_exit;
@@ -7170,7 +7228,6 @@ void game_shutdown(void)
game_launch_launcher_on_exit();
}
#endif
#endif
}
// game_stop_looped_sounds()
@@ -7774,16 +7831,29 @@ void get_version_string(char *str)
{
//XSTR:OFF
if ( FS_VERSION_BUILD == 0 ) {
sprintf(str,"v%d.%02d",FS_VERSION_MAJOR, FS_VERSION_MINOR);
sprintf(str,"V%d.%d", FS_VERSION_MAJOR, FS_VERSION_MINOR);
} else {
sprintf(str,"v%d.%02d.%02d",FS_VERSION_MAJOR, FS_VERSION_MINOR, FS_VERSION_BUILD );
sprintf(str,"V%d.%d.%d", FS_VERSION_MAJOR, FS_VERSION_MINOR, FS_VERSION_BUILD );
}
#if defined (FS2_DEMO)
strcat(str, " D");
#elif defined (OEM_BUILD)
strcat(str, " (OEM)");
#ifdef _DEBUG
strcat(str, " Dbg");
#endif
// append the CVS "release" version in the $Name variable, but
// only do this if it's been tagged
int rcs_name_len = strlen(RCS_Name);
if (rcs_name_len > 11) {
char buffer[100];
strcpy(buffer, RCS_Name + 7);
buffer[rcs_name_len-9] = 0;
strcat(str, " Build: ");
strcat(str, buffer);
} else {
strcat(str, " (fs2_open)");
}
//XSTR:ON
/*
HMODULE hMod;
@@ -7817,7 +7887,7 @@ if ( FS_VERSION_BUILD == 0 ) {
void get_version_string_short(char *str)
{
sprintf(str,"v%d.%02d",FS_VERSION_MAJOR, FS_VERSION_MINOR);
sprintf(str,"v%d.%d", FS_VERSION_MAJOR, FS_VERSION_MINOR);
}
// ----------------------------------------------------------------
@@ -8197,7 +8267,7 @@ void game_stop_subspace_ambient_sound()
// ----------------------------------------------------------------
#ifdef WIN32
#ifdef _WIN32
// ----------------------------------------------------------------
//
// CDROM detection code START
@@ -8557,7 +8627,8 @@ int game_do_cd_check_specific(char *volume_name, int cdnum)
// only need to do this in RELEASE_REAL
int game_do_cd_mission_check(char *filename)
{
#ifdef RELEASE_REAL
//#ifdef RELEASE_REAL
#if 0
int cd_num;
int cd_present = 0;
int cd_drive_num;
+8 -5
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/FREESPACE2/FreeSpace.h $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* FreeSpace, the game, not the project, header information.
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:07 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -147,9 +150,9 @@
#define _FREESPACE_H
#ifndef STAMPER_PROGRAM // because of all the dependancies, I have to do this...yuck!!! MWA 7/21/97
#include "pstypes.h"
#include "systemvars.h"
#include "2d.h"
#include "globalincs/pstypes.h"
#include "globalincs/systemvars.h"
#include "graphics/2d.h"
// --------------------------------------------------------------------------------------------------------
// FREESPACE DEFINES/VARS
+8 -5
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/Freespace2/LevelPaging.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Code to page in all the bitmaps at the beginning of a level.
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:07 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -53,9 +56,9 @@
* $NoKeywords: $
*/
#include "freespace.h"
#include "bmpman.h"
#include "levelpaging.h"
#include "freespace2/freespace.h"
#include "bmpman/bmpman.h"
#include "freespace2/levelpaging.h"
// All the page in functions
extern void ship_page_in();
+19 -16
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/GameHelp/ContextHelp.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Functions to drive the context-sensitive help
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.2 2002/05/03 22:07:08 mharris
* got some stuff to compile
*
@@ -107,21 +110,21 @@
#include <string.h>
#include <setjmp.h>
#include "contexthelp.h"
#include "gamesequence.h"
#include "freespace.h"
#include "mainhallmenu.h"
#include "key.h"
#include "bmpman.h"
#include "2d.h"
#include "timer.h"
#include "gamehelp/contexthelp.h"
#include "gamesequence/gamesequence.h"
#include "freespace2/freespace.h"
#include "menuui/mainhallmenu.h"
#include "io/key.h"
#include "bmpman/bmpman.h"
#include "graphics/2d.h"
#include "io/timer.h"
#include "math.h"
#include "mouse.h"
#include "controlsconfig.h"
#include "techmenu.h"
#include "parselo.h"
#include "localize.h"
#include "alphacolors.h"
#include "io/mouse.h"
#include "controlconfig/controlsconfig.h"
#include "menuui/techmenu.h"
#include "parse/parselo.h"
#include "localization/localize.h"
#include "globalincs/alphacolors.h"
////////////////////////////////////////////////////////////////////
+20 -17
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/GameHelp/GameplayHelp.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Module for displaying in-game help
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:07 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -115,22 +118,22 @@
* $NoKeywords: $
*/
#include "contexthelp.h"
#include "gamesequence.h"
#include "freespace.h"
#include "key.h"
#include "bmpman.h"
#include "2d.h"
#include "timer.h"
#include "gamehelp/contexthelp.h"
#include "gamesequence/gamesequence.h"
#include "freespace2/freespace.h"
#include "io/key.h"
#include "bmpman/bmpman.h"
#include "graphics/2d.h"
#include "io/timer.h"
#include "math.h"
#include "mouse.h"
#include "controlsconfig.h"
#include "ui.h"
#include "gamesnd.h"
#include "missionscreencommon.h"
#include "alphacolors.h"
#include "beam.h"
#include "audiostr.h"
#include "io/mouse.h"
#include "controlconfig/controlsconfig.h"
#include "ui/ui.h"
#include "gamesnd/gamesnd.h"
#include "missionui/missionscreencommon.h"
#include "globalincs/alphacolors.h"
#include "weapon/beam.h"
#include "sound/audiostr.h"
// text positioning constats
#define TITLE_Y 35
+7 -4
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/GameSequence/GameSequence.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* File to control Game Sequencing
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:07 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -240,8 +243,8 @@
* States should always be referred to using the macros.
*/
#include "freespace.h"
#include "gamesequence.h"
#include "freespace2/freespace.h"
#include "gamesequence/gamesequence.h"
// local defines
#define MAX_GAMESEQ_EVENTS 20 // maximum number of events on the game sequencing queue
+6 -3
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/GameSequence/GameSequence.h $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Header file for Game Sequencing items
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:07 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -331,7 +334,7 @@
#ifndef __GAMESEQUENCE_H__
#define __GAMESEQUENCE_H__
#include "pstypes.h"
#include "globalincs/pstypes.h"
// defines for game sequencing events
//
+20 -17
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/Gamesnd/EventMusic.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* C module for high-level control of event driven music
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:07 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -111,22 +114,22 @@
*/
#include "pstypes.h"
#include "eventmusic.h"
#include "object.h"
#include "ship.h"
#include "linklist.h"
#include "missionload.h" /* for Builtin_mission_names[] */
#include "missionparse.h"
#include "timer.h"
#include "freespace.h"
#include "audiostr.h"
#include "missioncampaign.h"
#include "sound.h"
#include "globalincs/pstypes.h"
#include "gamesnd/eventmusic.h"
#include "object/object.h"
#include "ship/ship.h"
#include "globalincs/linklist.h"
#include "mission/missionload.h" /* for Builtin_mission_names[] */
#include "mission/missionparse.h"
#include "io/timer.h"
#include "freespace2/freespace.h"
#include "sound/audiostr.h"
#include "mission/missioncampaign.h"
#include "sound/sound.h"
#include "time.h"
#include "cmdline.h"
#include "missiongoals.h"
#include "localize.h"
#include "cmdline/cmdline.h"
#include "mission/missiongoals.h"
#include "localization/localize.h"
#pragma optimize("", off)
+6 -3
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/Gamesnd/EventMusic.h $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Header file for high-level control of event driven music
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.2 2002/05/10 06:08:08 mharris
* Porting... added ifndef NO_SOUND
*
@@ -124,7 +127,7 @@
#ifndef __EVENT_MUSIC_H__
#define __EVENT_MUSIC_H__
#include "parselo.h"
#include "parse/parselo.h"
// Identifies songs in the Soundtrack_filenames[] structure. The order matches up with
// what is in music.tbl. Do not modify without synching music.tbl.
+10 -7
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/Gamesnd/GameSnd.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Routines to keep track of which sound files go where
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:07 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -167,11 +170,11 @@
* $NoKeywords: $
*/
#include "pstypes.h"
#include "gamesnd.h"
#include "sound.h"
#include "parselo.h"
#include "localize.h"
#include "globalincs/pstypes.h"
#include "gamesnd/gamesnd.h"
#include "sound/sound.h"
#include "parse/parselo.h"
#include "localization/localize.h"
// Global array that holds data about the gameplay sound effects.
game_snd Snds[MAX_GAME_SOUNDS];
+7 -4
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/Gamesnd/GameSnd.h $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Routines to keep track of which sound files go where
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.2 2002/05/10 06:08:08 mharris
* Porting... added ifndef NO_SOUND
*
@@ -320,8 +323,8 @@
#ifndef __GAMESND_H__
#define __GAMESND_H__
#include "sound.h"
#include "missionparse.h"
#include "sound/sound.h"
#include "mission/missionparse.h"
#ifndef NO_SOUND
+1 -1
View File
@@ -41,7 +41,7 @@ typedef struct { float r, g, b, a; } FxColor4;
** export macros
*/
#if defined(__MSC__)
#if defined(_MSC_VER)
#if defined (MSVC16)
#define FX_ENTRY
#define FX_CALL
+1 -1
View File
@@ -42,7 +42,7 @@
#if defined(FX_DLL_DEFINITION)
#if defined(FX_DLL_ENABLE)
#if defined(__MSC__)
#if defined(_MSC_VER)
#ifndef KERNEL
#define FX_ENTRY __declspec( dllexport )
#define FX_EXPORT __declspec( dllexport )
+1 -1
View File
@@ -17,7 +17,7 @@
extern "C" {
# endif
# ifdef WIN32
# ifdef _WIN32
void sleep(int secs);
#define gethostname fxGethostname
+10 -5
View File
@@ -1,12 +1,18 @@
/*
* $Logfile: /Freespace2/code/glide/Glide.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.2 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Code for dynamically loading glide libraries
*
* $Log: not supported by cvs2svn $
* Revision 2.1 2002/07/07 19:55:59 penguin
* Back-port to MSVC
*
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:07 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -33,12 +39,11 @@
* $NoKeywords: $
*/
#define __MSC__
#include <windows.h>
#include <windowsx.h>
#include "glide.h"
#include "pstypes.h"
#include "glide/glide.h"
#include "globalincs/pstypes.h"
static HMODULE Glide_lib_handle;
+4 -5
View File
@@ -22,12 +22,11 @@
#ifndef __GLIDE_H__
#define __GLIDE_H__
#define __MSC__
#define FX_GLIDE_NO_FUNC_PROTO
#include "3dfx.h"
#include "sst1vid.h"
#include "glidesys.h"
#include "glide/3dfx.h"
#include "glide/sst1vid.h"
#include "glide/glidesys.h"
#ifdef __cplusplus
extern "C" {
@@ -1089,7 +1088,7 @@ grHints(GrHint_t hintType, FxU32 hintMask);
}
#endif
#include "glideutl.h"
#include "glide/glideutl.h"
#endif /* __GLIDE_H__ */
+2 -2
View File
@@ -7,8 +7,8 @@
*
*/
#include "2d.h"
#include "alphacolors.h"
#include "graphics/2d.h"
#include "globalincs/alphacolors.h"
// -----------------------------------------------------------------------------------
// ALPHA DEFINES/VARS
+6 -3
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/GlobalIncs/crypt.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Files for cypting stuff
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:07 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -32,7 +35,7 @@
*/
#include <string.h>
#include "crypt.h"
#include "globalincs/crypt.h"
char *jcrypt (char *plainstring)
{
+29 -15
View File
@@ -9,13 +9,25 @@
/*
* $Logfile: /Freespace2/code/GlobalIncs/PsTypes.h $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.4 $
* $Date: 2002-08-06 01:49:08 $
* $Author: penguin $
*
* Header file containg global typedefs, constants and macros
*
* $Log: not supported by cvs2svn $
* Revision 2.3 2002/08/01 01:41:04 penguin
* The big include file move
*
* Revision 2.2 2002/07/22 01:04:37 penguin
* took out GAME_CD_CHECK define
*
* Revision 2.1 2002/07/07 19:55:59 penguin
* Back-port to MSVC
*
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.4 2002/05/09 13:50:20 mharris
* define AsmInt3() to abort()
*
@@ -197,9 +209,9 @@
// #define DVD_MESSAGE_HACK
#if defined(MULTIPLAYER_BETA_BUILD) || defined(E3_BUILD) || defined(RELEASE_REAL)
#define GAME_CD_CHECK
#endif
// #if defined(MULTIPLAYER_BETA_BUILD) || defined(E3_BUILD) || defined(RELEASE_REAL)
// #define GAME_CD_CHECK
// #endif
// 4127 is constant conditional (assert)
// 4100 is unreferenced formal parameters,
@@ -222,7 +234,8 @@
#include <memory.h>
#include <malloc.h>
#include <string.h>
#include "config.h"
#include "windows_stub/config.h"
// value to represent an uninitialized state in any int or uint
#define UNINITIALIZED 0x7f8e6d9c
@@ -240,7 +253,7 @@
#define LOCAL static // make module local varilable static.
#if defined( WINDOWS ) && defined( MSVC )
#if defined( _WIN32 ) && defined( _MSC_VER )
typedef __int64 longlong;
typedef unsigned __int64 ulonglong;
#elif defined ( __GNUC__ )
@@ -259,7 +272,7 @@ typedef unsigned int uint;
//Stucture to store clipping codes in a word
typedef struct ccodes {
ubyte or,and; //or is low byte, and is high byte
ubyte cc_or, cc_and; //or is low byte, and is high byte
} ccodes;
typedef struct vector {
@@ -351,7 +364,7 @@ extern void _cdecl WinAssert(char * text,char *filename, int line);
extern void _cdecl Error( char * filename, int line, char * format, ... );
extern void _cdecl Warning( char * filename, int line, char * format, ... );
#include "outwnd.h"
#include "osapi/outwnd.h"
// To debug printf do this:
// mprintf(( "Error opening %s\n", filename ));
@@ -385,7 +398,7 @@ void gr_activate(int);
// define to call from Warning function above since it calls Int3, so without this, we
// get put into infinite dialog boxes
#ifdef WIN32
#ifdef _WIN32
#define AsmInt3() _asm { int 3 }
#else
#define AsmInt3() abort()
@@ -526,13 +539,14 @@ void dc_printf( char *format, ... );
//======================================================================================
#include "config.h"
#include "fix.h"
#include "floating.h"
#include "math/fix.h"
#include "math/floating.h"
// Some constants for stuff
// #define MAX_FILENAME_LEN 32 // Length for filenames, ie "title.pcx"
// #define MAX_PATH_LEN 128 // Length for pathnames, ie "c:\bitmaps\title.pcx"
#ifdef _WIN32
#define MAX_FILENAME_LEN 32 // Length for filenames, ie "title.pcx"
#define MAX_PATH_LEN 128 // Length for pathnames, ie "c:\bitmaps\title.pcx"
#endif
// contants and defined for byteswapping routines (useful for mac)
+9 -6
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/GlobalIncs/SystemVars.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Variables and constants common to FreeSpace and Fred.
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:07 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -191,10 +194,10 @@
* $NoKeywords: $
*/
#include "pstypes.h"
#include "systemvars.h"
#include "timer.h"
#include "neb.h"
#include "globalincs/pstypes.h"
#include "globalincs/systemvars.h"
#include "io/timer.h"
#include "nebula/neb.h"
fix Missiontime;
fix Frametime;
+7 -4
View File
@@ -9,12 +9,15 @@
/*
* $Logfile: /Freespace2/code/GlobalIncs/version.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:07 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -36,8 +39,8 @@
#include <stdio.h>
#include <string.h>
#include "version.h"
#include "osregistry.h"
#include "globalincs/version.h"
#include "osapi/osregistry.h"
// ----------------------------------------------------------------------------------------------------------------
// VERSION DEFINES/VARS
+16 -15
View File
@@ -9,12 +9,18 @@
/*
* $Logfile: /Freespace2/code/GlobalIncs/version.h $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.2 $
* $Date: 2002-08-13 03:32:25 $
* $Author: penguin $
*
*
* $Log: not supported by cvs2svn $
* Revision 2.1 2002/08/04 05:11:36 penguin
* Update version number to 3.1
*
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:07 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -114,19 +120,14 @@
// 1.01 Patch for Win95 volume label bug
// 1.20 German release version
#if defined (FS2_DEMO)
#define FS_VERSION_MAJOR 01 // Major is 0 for pre-release and 1 for 1.0 release
#define FS_VERSION_MINOR 10 // Increase by 1 for minor revs, 10 for major.
#define FS_VERSION_BUILD 00 // Build version
#elif defined(OEM_BUILD)
#define FS_VERSION_MAJOR 01 // Major is 0 for pre-release and 1 for 1.0 release
#define FS_VERSION_MINOR 00 // Increase by 1 for minor revs, 10 for major.
#define FS_VERSION_BUILD 00 // Build version
#else
#define FS_VERSION_MAJOR 01 // Major is 0 for pre-release and 1 for 1.0 release
#define FS_VERSION_MINOR 20 // Increase by 1 for minor revs, 10 for major.
#define FS_VERSION_BUILD 00 // Build version
#endif
// fs2_open version numbers:
// the first version is 3.0 :-)
// Major.Minor.Bugfix
#define FS_VERSION_MAJOR 3 // major version
#define FS_VERSION_MINOR 2 // increase by 1 for minor revs
#define FS_VERSION_BUILD 0 // bugfix release
#define VERSION_LOC_FNAME "version.nfo"
#define MOTD_LOC_FNAME "motd.txt"
+6 -3
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/GlobalIncs/WinDebug.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Debug stuff
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:07 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -115,7 +118,7 @@
#include <stdio.h>
#include <crtdbg.h>
#include "pstypes.h"
#include "globalincs/pstypes.h"
//Uncomment SHOW_CALL_STACK to show the call stack in Asserts, Warnings, and Errors
#define SHOW_CALL_STACK
+82 -32
View File
@@ -9,13 +9,25 @@
/*
* $Logfile: /Freespace2/code/Graphics/2d.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.3 $
* $Date: 2002-08-01 01:41:04 $
* $Author: penguin $
*
* Main file for 2d primitives.
*
* $Log: not supported by cvs2svn $
* Revision 2.2 2002/07/30 14:29:15 unknownplayer
*
* Started work on DX8.1 implementation. Updated the project files to encompass
* the new files. Disable the compiler tag to use old DX code (THERE IS NO
* NEW CODE YET!)
*
* Revision 2.1 2002/07/07 19:55:59 penguin
* Back-port to MSVC
*
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.5 2002/05/26 14:10:29 mharris
* More testing
*
@@ -437,29 +449,31 @@
* $NoKeywords: $
*/
#ifdef _WIN32
#include <windows.h>
#include <windowsx.h>
#endif
#include "pstypes.h"
#include "osapi.h"
#include "2d.h"
#include "3d.h"
#include "bmpman.h"
#include "palman.h"
#include "font.h"
#include "grinternal.h"
#include "systemvars.h"
#include "cmdline.h"
#include "globalincs/pstypes.h"
#include "osapi/osapi.h"
#include "graphics/2d.h"
#include "render/3d.h"
#include "bmpman/bmpman.h"
#include "palman/palman.h"
#include "graphics/font.h"
#include "graphics/grinternal.h"
#include "globalincs/systemvars.h"
#include "cmdline/cmdline.h"
// 3dnow stuff
// #include "amd3d.h"
// Includes for different rendering systems
#include "grsoft.h"
#include "grd3d.h"
#include "grglide.h"
#include "gropengl.h"
#include "grdirectdraw.h"
#include "graphics/grsoft.h"
#include "graphics/grd3d.h"
#include "graphics/grglide.h"
#include "graphics/gropengl.h"
#include "graphics/grdirectdraw.h"
screen gr_screen;
@@ -498,7 +512,7 @@ void gr_close()
palette_flush();
switch( gr_screen.mode ) {
#ifdef WIN32
#ifdef _WIN32
case GR_SOFTWARE:
gr_soft_cleanup();
break;
@@ -513,9 +527,13 @@ void gr_close()
gr_glide_cleanup();
break;
#endif
#ifdef USE_OPENGL
case GR_OPENGL:
gr_opengl_cleanup();
break;
#endif // ifdef USE_OPENGL
default:
Int3(); // Invalid graphics mode
}
@@ -569,7 +587,7 @@ DCF(gr,"Changes graphics mode")
dc_printf( " B=software directdraw fullscreen (obsolete)\n" );
dc_printf( " D=Direct3d\n" );
dc_printf( " G=Glide\n" );
dc_printf( " O=OpenGl (obsolete)\n" );
dc_printf( " O=OpenGL\n" );
Dc_status = 0; // don't print status if help is printed. Too messy.
}
@@ -675,7 +693,7 @@ void gr_set_palette( char *name, ubyte * palette, int restrict_font_to_128 )
//void gr_test();
#if defined( WINDOWS ) && defined( MSVC )
#if defined( _WIN32 ) && defined( _MSC_VER )
#define CPUID _asm _emit 0fh _asm _emit 0a2h
@@ -845,7 +863,7 @@ void gr_detect_cpu(int *cpu, int *mmx, int *amd3d, int *katmai )
if (katmai)
*katmai = 0;
}
#endif // if defined( WINDOWS ) && defined( MSVC )
#endif // if defined( _WIN32 ) && defined( _MSC_VER )
@@ -868,7 +886,7 @@ int gr_init(int res, int mode, int depth, int fred_x, int fred_y)
// If already inited, shutdown the previous graphics
if ( Gr_inited ) {
switch( gr_screen.mode ) {
#ifdef WIN32
#ifdef _WIN32
case GR_SOFTWARE:
gr_soft_cleanup();
break;
@@ -876,16 +894,24 @@ int gr_init(int res, int mode, int depth, int fred_x, int fred_y)
Int3();
gr_directdraw_cleanup();
break;
case GR_DIRECT3D:
case GR_DIRECT3D:
#ifdef USE_DX81
// TODO: Add Dx8.1 clean up call here - unknownplayer
#else
gr_d3d_cleanup();
#endif // USE_DX81 //
break;
case GR_GLIDE:
gr_glide_cleanup();
break;
#endif
#ifdef USE_OPENGL
case GR_OPENGL:
gr_opengl_cleanup();
break;
#endif // USE_OPENGL
default:
Int3(); // Invalid graphics mode
}
@@ -893,7 +919,7 @@ int gr_init(int res, int mode, int depth, int fred_x, int fred_y)
first_time = 1;
}
#if defined(HARDWARE_ONLY) && defined(WIN32)
#if defined(HARDWARE_ONLY) && defined(_WIN32)
if(!Fred_running && !Pofview_running && !Nebedit_running && !Is_standalone){
if((mode != GR_GLIDE) && (mode != GR_DIRECT3D)){
mprintf(("Forcing glide startup!\n"));
@@ -951,7 +977,7 @@ int gr_init(int res, int mode, int depth, int fred_x, int fred_y)
gr_screen.clip_height = gr_screen.max_h;
switch( gr_screen.mode ) {
#ifdef WIN32
#ifdef _WIN32
case GR_SOFTWARE:
Assert(Fred_running || Pofview_running || Is_standalone || Nebedit_running);
gr_soft_init();
@@ -962,9 +988,15 @@ int gr_init(int res, int mode, int depth, int fred_x, int fred_y)
gr_directdraw_init();
break;
case GR_DIRECT3D:
// Check if we want to use the DX8.1 routines - unknownplayer
// This is here so we can revert to the old ones if necessary
#ifdef USE_DX81
// TODO: Insert new initialization for DX8.1 here - unknownplayer
#else
// we only care about possible 32 bit stuff here
Cmdline_force_32bit = 0;
if(depth == 32){
if(depth == 32)
{
Cmdline_force_32bit = 1;
}
@@ -972,11 +1004,12 @@ int gr_init(int res, int mode, int depth, int fred_x, int fred_y)
// bad startup - stupid D3D
extern int D3D_inited;
if(!D3D_inited){
if(!D3D_inited)
{
Gr_inited = 0;
return 1;
}
#endif // USE_DX81 //
break;
case GR_GLIDE:
// if we're in high-res. force polygon interface
@@ -986,9 +1019,13 @@ int gr_init(int res, int mode, int depth, int fred_x, int fred_y)
gr_glide_init();
break;
#endif // ifdef WIN32
#ifdef USE_OPENGL
case GR_OPENGL:
gr_opengl_init();
break;
#endif // ifdef USE_OPENGL
default:
Int3(); // Invalid graphics mode
}
@@ -1025,7 +1062,7 @@ void gr_force_windowed()
if ( !Gr_inited ) return;
switch( gr_screen.mode ) {
#ifdef WIN32
#ifdef _WIN32
case GR_SOFTWARE:
{
extern void gr_soft_force_windowed();
@@ -1048,9 +1085,13 @@ void gr_force_windowed()
}
break;
#endif // ifdef WIN32
#ifdef USE_OPENGL
case GR_OPENGL:
break;
#endif // ifdef USE_OPENGL
default:
Int3(); // Invalid graphics mode
}
@@ -1065,7 +1106,7 @@ void gr_activate(int active)
if ( !Gr_inited ) return;
switch( gr_screen.mode ) {
#ifdef WIN32
#ifdef _WIN32
case GR_SOFTWARE:
{
extern void gr_soft_activate(int active);
@@ -1096,8 +1137,12 @@ void gr_activate(int active)
}
break;
#endif // ifdef WIN32
#ifdef USE_OPENGL
case GR_OPENGL:
break;
#endif // ifdef USE_OPENGL
default:
Int3(); // Invalid graphics mode
}
@@ -1190,7 +1235,7 @@ void gr_bitmap(int x, int y)
// old school bitmaps
switch(gr_screen.mode){
#ifdef WIN32
#ifdef _WIN32
case GR_SOFTWARE:
grx_bitmap(x, y);
break;
@@ -1209,16 +1254,19 @@ void gr_bitmap(int x, int y)
#endif // ifdef WIN32
#ifdef USE_OPENGL
case GR_OPENGL:
gr_opengl_bitmap(x, y);
break;
#endif // ifdef USE_OPENGL
}
}
void gr_bitmap_ex(int x, int y, int w, int h, int sx, int sy)
{
switch(gr_screen.mode){
#ifdef WIN32
#ifdef _WIN32
case GR_SOFTWARE:
grx_bitmap_ex(x, y, w, h, sx, sy);
break;
@@ -1236,8 +1284,10 @@ void gr_bitmap_ex(int x, int y, int w, int h, int sx, int sy)
break;
#endif // ifdef WIN32
#ifdef USE_OPENGL
case GR_OPENGL:
gr_opengl_bitmap_ex(x, y, w, h, sx, sy);
#endif // ifdef USE_OPENGL
}
}
+7 -4
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/Graphics/2d.h $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:05 $
* $Author: penguin $
*
* Header file for 2d primitives.
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:07 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -322,8 +325,8 @@ gr_line(x1,y1,x2,y2)
*/
#include "pstypes.h"
#include "tmapper.h"
#include "globalincs/pstypes.h"
#include "graphics/tmapper.h"
// This is a structure used by the shader to keep track
// of the values you want to use in the shade primitive.
+15 -9
View File
@@ -9,13 +9,19 @@
/*
* $Logfile: /Freespace2/code/Graphics/aaline.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.2 $
* $Date: 2002-08-01 01:41:05 $
* $Author: penguin $
*
* Code to draw antialiased lines
*
* $Log: not supported by cvs2svn $
* Revision 2.1 2002/07/07 19:55:59 penguin
* Back-port to MSVC
*
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.2 2002/05/03 22:07:08 mharris
* got some stuff to compile
*
@@ -106,11 +112,11 @@
#include <stdio.h>
#include <stdlib.h>
#include "pstypes.h"
#include "2d.h"
#include "line.h"
#include "grinternal.h"
#include "palman.h"
#include "globalincs/pstypes.h"
#include "graphics/2d.h"
#include "graphics/line.h"
#include "graphics/grinternal.h"
#include "palman/palman.h"
// Convert from floating-point to internal fixed-point formats
#define ONE_XY (long int) 0x00100000
@@ -240,7 +246,7 @@ void aaline_init_tables()
// less than 1.0 and less total bits are sufficient.
// Some of the steps here are not needed. This was originally
// written to simulate exact hardware behavior.
#if defined( WINDOWS ) && defined( MSVC )
#if defined( _WIN32 ) && defined( _MSC_VER )
long int fix_xy_mult(long int oa, fix_xy ob)
{
int retval;
@@ -256,7 +262,7 @@ long int fix_xy_mult(long int oa, fix_xy ob)
}
#else
long int fix_xy_mult(long int oa, fix_xy ob);
#endif // if defined( WINDOWS ) && defined( MSVC )
#endif // if defined( _WIN32 ) && defined( _MSC_VER )
+15 -12
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/Graphics/Bitblt.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:05 $
* $Author: penguin $
*
* Code to do software bitblt type stuff
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.2 2002/05/03 22:07:08 mharris
* got some stuff to compile
*
@@ -40,18 +43,18 @@
* $NoKeywords: $
*/
#include "pstypes.h"
#include "osapi.h"
#include "2d.h"
#include "bmpman.h"
#include "key.h"
#include "floating.h"
#include "palman.h"
#include "grsoft.h"
#include "grinternal.h"
#include "globalincs/pstypes.h"
#include "osapi/osapi.h"
#include "graphics/2d.h"
#include "bmpman/bmpman.h"
#include "io/key.h"
#include "math/floating.h"
#include "palman/palman.h"
#include "graphics/grsoft.h"
#include "graphics/grinternal.h"
// Headers for 2d functions
#include "bitblt.h"
#include "graphics/bitblt.h"
MONITOR( Num2dBitmaps );
+8 -5
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/Graphics/Circle.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:05 $
* $Author: penguin $
*
* Code to draw circles.
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:07 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -53,9 +56,9 @@
* $NoKeywords: $
*/
#include "2d.h"
#include "pixel.h"
#include "circle.h"
#include "graphics/2d.h"
#include "graphics/pixel.h"
#include "graphics/circle.h"
// THIS COULD BE OPTIMIZED BY MOVING THE GR_RECT CODE INTO HERE!!!!!!!!
+12 -9
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/Graphics/Colors.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:05 $
* $Author: penguin $
*
* Functions to deal with colors & alphacolors
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.4 2002/05/26 14:10:29 mharris
* More testing
*
@@ -175,13 +178,13 @@
* $NoKeywords: $
*/
#include "pstypes.h"
#include "2d.h"
#include "grinternal.h"
#include "colors.h"
#include "palman.h"
#include "cfile.h"
#include "systemvars.h"
#include "globalincs/pstypes.h"
#include "graphics/2d.h"
#include "graphics/grinternal.h"
#include "graphics/colors.h"
#include "palman/palman.h"
#include "cfile/cfile.h"
#include "globalincs/systemvars.h"
//#define MAX_ALPHACOLORS 36
#define MAX_ALPHACOLORS 256
+146
View File
@@ -0,0 +1,146 @@
/*
Main code file for the new DirectX 8.1 and up graphics routines.
Doing things this way makes sure that we don't break any of the existing code.
Notes about coding the update:
*Copy what you need from [V]'s code - it's faster
*When you rewrite a function from the original, append an 8 after the 'd3d' so we and the compiler
can differentiate the functions - this is going to be completely separate so no overloading
*This is by no means the only file, just a starter one, it will essentially be identical to
[V]'s original structurally.
*By no means have I completely stripped all the files for their functions yet, this was just
added late at night. There will be problems initially.
Post all updates to the developer mailing list or the forum, preferably in the DX8.1 thread
##UnknownPlayer##
*/
// Commented out includes are those awaiting rewriting
#include <math.h>
#include "graphics/directx8/grd3d81internal.h" // Updated to point to the correct include file
#include "osapi/osapi.h"
#include "graphics/2d.h"
#include "bmpman/bmpman.h"
#include "io/key.h"
#include "math/floating.h"
#include "palman/palman.h"
#include "osapi/osregistry.h"
#include "grd3d81.h" // Updated to point to the include for this file
#include "graphics/line.h"
#include "graphics/font.h"
#include "graphics/grinternal.h"
#include "io/mouse.h"
#include "globalincs/alphacolors.h"
#include "globalincs/systemvars.h"
#include "cfile/cfile.h"
#include "cmdline/cmdline.h"
void gr_d3d8_init()
{
}
void gr_d3d8_cleanup()
{
}
void gr_d3d8_get_tex_format(int alpha)
{
}
void gr_d3d8_bitmap(int x, int y)
{
}
void gr_d3d8_bitmap_ex(int x, int y, int w, int h, int sx, int sy)
{
}
int gr_d3d8_create_rendering_objects(int clear)
{
}
void gr_d3d8_release_rendering_objects()
{
}
void gr_d3d8_set_initial_render_state()
{
}
char* d3d8_error_string(HRESULT error)
{
switch(error)
{
case D3DERR_BADMAJORVERSION:
return "D3DERR_BADMAJORVERSION\0";
case D3DERR_BADMINORVERSION:
return "D3DERR_BADMINORVERSION\0";
case D3DERR_EXECUTE_LOCKED:
return "D3DERR_EXECUTE_LOCKED\0";
case D3DERR_EXECUTE_NOT_LOCKED:
return "D3DERR_EXECUTE_NOT_LOCKED\0";
case D3DERR_EXECUTE_CREATE_FAILED:
return "D3DERR_EXECUTE_CREATE_FAILED\0";
case D3DERR_EXECUTE_DESTROY_FAILED:
return "D3DERR_EXECUTE_DESTROY_FAILED\0";
case D3DERR_EXECUTE_LOCK_FAILED:
return "D3DERR_EXECUTE_LOCK_FAILED\0";
case D3DERR_EXECUTE_UNLOCK_FAILED:
return "D3DERR_EXECUTE_UNLOCK_FAILED\0";
case D3DERR_EXECUTE_FAILED:
return "D3DERR_EXECUTE_FAILED\0";
case D3DERR_EXECUTE_CLIPPED_FAILED:
return "D3DERR_EXECUTE_CLIPPED_FAILED\0";
case D3DERR_TEXTURE_NO_SUPPORT:
return "D3DERR_TEXTURE_NO_SUPPORT\0";
case D3DERR_TEXTURE_NOT_LOCKED:
return "D3DERR_TEXTURE_NOT_LOCKED\0";
case D3DERR_TEXTURE_LOCKED:
return "D3DERR_TEXTURELOCKED\0";
case D3DERR_TEXTURE_CREATE_FAILED:
return "D3DERR_TEXTURE_CREATE_FAILED\0";
case D3DERR_TEXTURE_DESTROY_FAILED:
return "D3DERR_TEXTURE_DESTROY_FAILED\0";
case D3DERR_TEXTURE_LOCK_FAILED:
return "D3DERR_TEXTURE_LOCK_FAILED\0";
case D3DERR_TEXTURE_UNLOCK_FAILED:
return "D3DERR_TEXTURE_UNLOCK_FAILED\0";
case D3DERR_TEXTURE_LOAD_FAILED:
return "D3DERR_TEXTURE_LOAD_FAILED\0";
case D3DERR_MATRIX_CREATE_FAILED:
return "D3DERR_MATRIX_CREATE_FAILED\0";
case D3DERR_MATRIX_DESTROY_FAILED:
return "D3DERR_MATRIX_DESTROY_FAILED\0";
case D3DERR_MATRIX_SETDATA_FAILED:
return "D3DERR_MATRIX_SETDATA_FAILED\0";
case D3DERR_SETVIEWPORTDATA_FAILED:
return "D3DERR_SETVIEWPORTDATA_FAILED\0";
case D3DERR_MATERIAL_CREATE_FAILED:
return "D3DERR_MATERIAL_CREATE_FAILED\0";
case D3DERR_MATERIAL_DESTROY_FAILED:
return "D3DERR_MATERIAL_DESTROY_FAILED\0";
case D3DERR_MATERIAL_SETDATA_FAILED:
return "D3DERR_MATERIAL_SETDATA_FAILED\0";
case D3DERR_LIGHT_SET_FAILED:
return "D3DERR_LIGHT_SET_FAILED\0";
default:
return "Unrecognized error value.\0";
}
}
+27
View File
@@ -0,0 +1,27 @@
/*
Main header file for the DX8.1 graphics routines.
See the .cpp for more info.
This is going to essentially resemble the original [V] one.
*/
#ifndef _GRD3D81_H
#define _GRD3D81_H
void gr_d3d8_init();
void gr_d3d8_cleanup();
// call this to safely fill in the texture shift and scale values for the specified texture type (Gr_t_*)
void gr_d3d8_get_tex_format(int alpha);
// bitmap functions
void gr_d3d8_bitmap(int x, int y);
void gr_d3d8_bitmap_ex(int x, int y, int w, int h, int sx, int sy);
// create all rendering objects (surfaces, d3d device, viewport, etc)
int gr_d3d8_create_rendering_objects(int clear);
void gr_d3d8_release_rendering_objects();
void gr_d3d8_set_initial_render_state();
#endif // _GRD3D81_H
@@ -0,0 +1,99 @@
/*
Prototypes for variables used by the D3D 8.1 renderer.
Note, because there are gonna be some changes to the way things are done, in this header
particularly we will not be mirroring the [V] headers.
*/
#ifndef _GRD3D81INTERNAL_H
#define _GRD3D81INTERNAL_H
#include <windows.h>
#include <windowsx.h>
#include <d3d8.h>
#include <d3dx8.h> // This is the Dx8.1 utility library. Automates some functions and
// provides the D3D_OVERLOADS functionality
#include "graphics/2d.h"
#include "graphics/grinternal.h"
/* !!! All of these need to be replaced with up to date versions
extern LPDIRECTDRAW lpDD1;
extern LPDIRECTDRAW2 lpDD;
extern LPDIRECT3D2 lpD3D;
extern LPDIRECT3DDEVICE lpD3DDeviceEB;
extern LPDIRECT3DDEVICE2 lpD3DDevice;
extern LPDIRECTDRAWSURFACE lpBackBuffer;
extern LPDIRECTDRAWSURFACE lpFrontBuffer;
extern LPDIRECTDRAWSURFACE lpZBuffer;
extern LPDIRECT3DVIEWPORT2 lpViewport;
extern LPDIRECTDRAWPALETTE lpPalette;
extern DDPIXELFORMAT AlphaTextureFormat;
extern DDPIXELFORMAT NonAlphaTextureFormat;
extern DDPIXELFORMAT ScreenFormat;
extern D3DDEVICEDESC D3DHWDevDesc, D3DHELDevDesc;
extern LPD3DDEVICEDESC lpDevDesc;
extern DDCAPS DD_driver_caps;
extern DDCAPS DD_hel_caps;
*/
extern int D3D8_texture_divider;
extern int D3D8_32bit;
extern char* d3d8_error_string(HRESULT error);
void d3d8_tcache_init(int use_sections);
void d3d8_tcache_cleanup();
void d3d8_tcache_flush();
void d3d8_tcache_frame();
// Flushes any pending operations
void d3d8_flush();
int d3d8_tcache_set(int bitmap_id, int bitmap_type, float *u_ratio, float *v_ratio, int fail_on_full=0, int sx = -1, int sy = -1, int force = 0);
// Functions in GrD3DRender.cpp stuffed into gr_screen structure
void gr_d3d8_flash(int r, int g, int b);
void gr_d3d8_zbuffer_clear(int mode);
int gr_d3d8_zbuffer_get();
int gr_d3d8_zbuffer_set(int mode);
void gr_d3d8_tmapper( int nverts, vertex **verts, uint flags );
void gr_d3d8_scaler(vertex *va, vertex *vb );
void gr_d3d8_aascaler(vertex *va, vertex *vb );
void gr_d3d8_pixel(int x, int y);
void gr_d3d8_clear();
void gr_d3d8_set_clip(int x,int y,int w,int h);
void gr_d3d8_reset_clip();
void gr_d3d8_init_color(color *c, int r, int g, int b);
void gr_d3d8_init_alphacolor( color *clr, int r, int g, int b, int alpha, int type );
void gr_d3d8_set_color( int r, int g, int b );
void gr_d3d8_get_color( int * r, int * g, int * b );
void gr_d3d8_set_color_fast(color *dst);
void gr_d3d8_set_bitmap( int bitmap_num, int alphablend_mode, int bitblt_mode, float alpha, int sx=-1, int sy=-1 );
void gr_d3d8_bitmap_ex(int x,int y,int w,int h,int sx,int sy);
void gr_d3d8_bitmap(int x, int y);
void gr_d3d8_aabitmap_ex(int x,int y,int w,int h,int sx,int sy);
void gr_d3d8_aabitmap(int x, int y);
void gr_d3d8_rect(int x,int y,int w,int h);
void gr_d3d8_create_shader(shader * shade, float r, float g, float b, float c );
void gr_d3d8_set_shader( shader * shade );
void gr_d3d8_shade(int x,int y,int w,int h);
void gr_d3d8_create_font_bitmap();
void gr_d3d8_char(int x,int y,int letter);
void gr_d3d8_string( int sx, int sy, char *s );
void gr_d3d8_circle( int xc, int yc, int d );
void gr_d3d8_line(int x1,int y1,int x2,int y2);
void gr_d3d8_aaline(vertex *v1, vertex *v2);
void gr_d3d8_gradient(int x1,int y1,int x2,int y2);
void gr_d3d8_set_palette(ubyte *new_palette, int restrict_alphacolor);
void gr_d3d8_diamond(int x, int y, int width, int height);
void gr_d3d8_print_screen(char *filename);
// Functions used to render. Calls either DrawPrim or Execute buffer code
HRESULT d3d8_SetRenderState( D3DRENDERSTATETYPE dwRenderStateType, DWORD dwRenderState );
HRESULT d3d8_DrawPrimitive( D3DPRIMITIVETYPE dptPrimitiveType, D3DVERTEXTYPE dvtVertexType, LPVOID lpvVertices, DWORD dwVertexCount, DWORD dwFlags );
#endif // _GRD3D81INTERNAL_H
+23 -11
View File
@@ -9,13 +9,22 @@
/*
* $Logfile: /Freespace2/code/Graphics/Font.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.3 $
* $Date: 2002-08-01 01:41:05 $
* $Author: penguin $
*
* source file for font stuff
*
* $Log: not supported by cvs2svn $
* Revision 2.2 2002/07/29 20:12:31 penguin
* added #ifdef _WIN32 around windows-specific system headers
*
* Revision 2.1 2002/07/07 19:55:59 penguin
* Back-port to MSVC
*
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.2 2002/05/16 13:43:25 mharris
* ifdef WIN32 around (unused?) win-specific code
*
@@ -223,18 +232,21 @@
* $NoKeywords: $
*/
#ifdef _WIN32
#include <windows.h>
#include <windowsx.h>
#endif
#include <stdio.h>
#include <stdarg.h>
#include "grinternal.h"
#include "2d.h"
#include "cfile.h"
#include "font.h"
#include "palman.h"
#include "key.h"
#include "bmpman.h"
#include "localize.h"
#include "graphics/grinternal.h"
#include "graphics/2d.h"
#include "cfile/cfile.h"
#include "graphics/font.h"
#include "palman/palman.h"
#include "io/key.h"
#include "bmpman/bmpman.h"
#include "localization/localize.h"
int Num_fonts = 0;
font Fonts[MAX_FONTS];
@@ -632,7 +644,7 @@ void gr8_string(int sx, int sy, char *s )
gr_unlock();
}
#ifdef WIN32
#ifdef _WIN32
HFONT MyhFont = NULL;
extern HDC hDibDC;
+9 -3
View File
@@ -9,13 +9,19 @@
/*
* $Logfile: /Freespace2/code/Graphics/Font.h $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.2 $
* $Date: 2002-08-01 01:41:05 $
* $Author: penguin $
*
* header file for font stuff
*
* $Log: not supported by cvs2svn $
* Revision 2.1 2002/07/07 19:55:59 penguin
* Back-port to MSVC
*
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.2 2002/05/03 22:07:08 mharris
* got some stuff to compile
*
@@ -89,7 +95,7 @@
#ifndef _FONT_H
#define _FONT_H
#include "config.h"
#include "globalincs/pstypes.h"
#define MAX_FONTS 3
+16 -8
View File
@@ -9,13 +9,19 @@
/*
* $Logfile: /Freespace2/code/Graphics/Gradient.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.2 $
* $Date: 2002-08-01 01:41:05 $
* $Author: penguin $
*
* Routines to draw rectangular gradients.
*
* $Log: not supported by cvs2svn $
* Revision 2.1 2002/07/29 20:12:31 penguin
* added #ifdef _WIN32 around windows-specific system headers
*
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:07 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -88,15 +94,17 @@
* $NoKeywords: $
*/
#ifdef _WIN32
#include <windows.h>
#include <windowsx.h>
#endif
#include "2d.h"
#include "grinternal.h"
#include "gradient.h"
#include "floating.h"
#include "line.h"
#include "palman.h"
#include "graphics/2d.h"
#include "graphics/grinternal.h"
#include "graphics/gradient.h"
#include "math/floating.h"
#include "graphics/line.h"
#include "palman/palman.h"
void gr8_gradient(int x1,int y1,int x2,int y2)
{
+30 -19
View File
@@ -9,13 +9,22 @@
/*
* $Logfile: /Freespace2/code/Graphics/GrD3D.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.2 $
* $Date: 2002-08-01 01:41:05 $
* $Author: penguin $
*
* Code for our Direct3D renderer
*
* $Log: not supported by cvs2svn $
* Revision 2.1 2002/07/30 14:29:15 unknownplayer
*
* Started work on DX8.1 implementation. Updated the project files to encompass
* the new files. Disable the compiler tag to use old DX code (THERE IS NO
* NEW CODE YET!)
*
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:07 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -182,24 +191,24 @@
#include <math.h>
#include "grd3dinternal.h"
#include "graphics/grd3dinternal.h"
#include "osapi.h"
#include "2d.h"
#include "bmpman.h"
#include "key.h"
#include "floating.h"
#include "palman.h"
#include "osregistry.h"
#include "grd3d.h"
#include "line.h"
#include "font.h"
#include "grinternal.h"
#include "mouse.h"
#include "alphacolors.h"
#include "systemvars.h"
#include "cfile.h"
#include "cmdline.h"
#include "osapi/osapi.h"
#include "graphics/2d.h"
#include "bmpman/bmpman.h"
#include "io/key.h"
#include "math/floating.h"
#include "palman/palman.h"
#include "osapi/osregistry.h"
#include "graphics/grd3d.h"
#include "graphics/line.h"
#include "graphics/font.h"
#include "graphics/grinternal.h"
#include "io/mouse.h"
#include "globalincs/alphacolors.h"
#include "globalincs/systemvars.h"
#include "cfile/cfile.h"
#include "cmdline/cmdline.h"
LPDIRECTDRAW lpDD1 = NULL;
@@ -2674,6 +2683,8 @@ void gr_d3d_init()
if(os_config_read_uint(NULL, "DisableZbias", 0)){
D3D_zbias = 0;
}
// perform a check for bump mapping capabilities - unknownplayer
d3d_start_frame();
+9 -6
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/Graphics/GrD3DInternal.h $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:05 $
* $Author: penguin $
*
* Prototypes for the variables used internally by the Direct3D renderer
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:07 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -128,15 +131,15 @@
#include <windowsx.h>
#define D3D_OVERLOADS
#include "vddraw.h"
#include "directx/vddraw.h"
// To remove an otherwise well-lodged compiler error
// 4201 nonstandard extension used : nameless struct/union (happens a lot in Windows include headers)
#pragma warning(disable: 4201)
#include "vd3d.h"
#include "2d.h"
#include "grinternal.h"
#include "directx/vd3d.h"
#include "graphics/2d.h"
#include "graphics/grinternal.h"
extern LPDIRECTDRAW lpDD1;
+49 -15
View File
@@ -9,13 +9,35 @@
/*
* $Logfile: /Freespace2/code/Graphics/GrD3DRender.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Author: penguin $
* $Revision: 2.3 $
* $Date: 2002-08-07 00:45:25 $
* $Author: DTP $
*
* Code to actually render stuff using Direct3D
*
* $Log: not supported by cvs2svn $
* Revision 2.2 2002/08/03 19:42:17 randomtiger
* Fixed Geforce 4 bug that caused font and hall video distortion.
* Very small change in 'gr_d3d_aabitmap_ex_internal'
*
* Tested and works on the following systems
*
* OUTSIDER Voodoo 3 win98
* OUTSIDER Geforce 2 win2000
* Me Geforce 4 PNY 4600 XP
* JBX-Phoenix Geforce 4 PNY XP
* Mehrunes GeForce 3 XP
* WMCoolmon nVidia TNT2 M64 win2000
* Orange GeForce 4 4200 XP
* ShadowWolf_IH Monster2 win98
* ShadowWolf_IH voodoo 2 win98
*
* Revision 2.1 2002/08/01 01:41:05 penguin
* The big include file move
*
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:07 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -311,15 +333,16 @@
* $NoKeywords: $
*/
#include "grd3dinternal.h"
#include "2d.h"
#include "pstypes.h"
#include "bmpman.h"
#include "palman.h"
#include "line.h"
#include "cfile.h"
#include "neb.h"
#include "3d.h"
#include "graphics/grd3dinternal.h"
#include "graphics/2d.h"
#include "globalincs/pstypes.h"
#include "bmpman/bmpman.h"
#include "palman/palman.h"
#include "graphics/line.h"
#include "cfile/cfile.h"
#include "nebula/neb.h"
#include "render/3d.h"
#include "cmdline/cmdline.h" //DTP for random tigers GF4fix, and the commandline switch.
typedef enum gr_texture_source {
TEXTURE_SOURCE_NONE,
@@ -1483,19 +1506,30 @@ void gr_d3d_aabitmap_ex_internal(int x,int y,int w,int h,int sx,int sy)
bm_get_info( gr_screen.current_bitmap, &bw, &bh );
// Rendition
// Rendition
if ( D3d_rendition_uvs ) {
u0 = u_scale*(i2fl(sx)+0.5f)/i2fl(bw);
v0 = v_scale*(i2fl(sy)+0.5f)/i2fl(bh);
u1 = u_scale*(i2fl(sx+w)+0.5f)/i2fl(bw);
v1 = v_scale*(i2fl(sy+h)+0.5f)/i2fl(bh);
} else {
//} else { //DTP; commented out, for easy re-editing
// u0 = u_scale*i2fl((sx)-0.5f)/i2fl(bw);
// v0 = v_scale*i2fl((sy)-0.5f)/i2fl(bh);
// u1 = u_scale*i2fl((sx+w)-0.5f)/i2fl(bw);
// v1 = v_scale*i2fl((sy+h)-0.5f)/i2fl(bh);
//}
} else if (!Cmdline_gf4fix) { //DTP if not set at commandline do the original code
u0 = u_scale*i2fl(sx)/i2fl(bw);
v0 = v_scale*i2fl(sy)/i2fl(bh);
u1 = u_scale*i2fl(sx+w)/i2fl(bw);
v1 = v_scale*i2fl(sy+h)/i2fl(bh);
} else { //DTP; these next 4 lines is random tigers Fix. activated by setting -GF4FIX in the commandline.
u0 = u_scale*(i2fl(sx)-0.5f)/i2fl(bw);
v0 = v_scale*(i2fl(sy)-0.5f)/i2fl(bh);
u1 = u_scale*(i2fl(sx+w)-0.5f)/i2fl(bw);
v1 = v_scale*(i2fl(sy+h)-0.5f)/i2fl(bh);
}
x1 = i2fl(x+gr_screen.offset_x);
+14 -11
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/Graphics/GrD3DTexture.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:05 $
* $Author: penguin $
*
* Code to manage loading textures into VRAM for Direct3D
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:07 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -226,16 +229,16 @@
* $NoKeywords: $
*/
#include "grd3d.h"
#include "grd3dinternal.h"
#include "2d.h"
#include "pstypes.h"
#include "bmpman.h"
#include "key.h"
#include "systemvars.h"
#include "osregistry.h"
#include "graphics/grd3d.h"
#include "graphics/grd3dinternal.h"
#include "graphics/2d.h"
#include "globalincs/pstypes.h"
#include "bmpman/bmpman.h"
#include "io/key.h"
#include "globalincs/systemvars.h"
#include "osapi/osregistry.h"
#include "multi_log.h"
#include "network/multi_log.h"
typedef struct tcache_slot_d3d {
LPDIRECTDRAWSURFACE vram_texture_surface;
+30 -27
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/Graphics/GrDirectDraw.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:05 $
* $Author: penguin $
*
* Code for software 8-bpp rendering using DirectDraw
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:07 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -122,34 +125,34 @@
#include <windows.h>
#include <windowsx.h>
#include "vddraw.h"
#include "directx/vddraw.h"
#include "osapi.h"
#include "2d.h"
#include "bmpman.h"
#include "key.h"
#include "floating.h"
#include "palman.h"
#include "grsoft.h"
#include "grinternal.h"
#include "osapi/osapi.h"
#include "graphics/2d.h"
#include "bmpman/bmpman.h"
#include "io/key.h"
#include "math/floating.h"
#include "palman/palman.h"
#include "graphics/grsoft.h"
#include "graphics/grinternal.h"
// Headers for 2d functions
#include "pixel.h"
#include "line.h"
#include "scaler.h"
#include "tmapper.h"
#include "circle.h"
#include "shade.h"
#include "rect.h"
#include "gradient.h"
#include "pcxutils.h"
#include "osapi.h"
#include "mouse.h"
#include "font.h"
#include "timer.h"
#include "colors.h"
#include "bitblt.h"
#include "grzbuffer.h"
#include "graphics/pixel.h"
#include "graphics/line.h"
#include "graphics/scaler.h"
#include "graphics/tmapper.h"
#include "graphics/circle.h"
#include "graphics/shade.h"
#include "graphics/rect.h"
#include "graphics/gradient.h"
#include "pcxutils/pcxutils.h"
#include "osapi/osapi.h"
#include "io/mouse.h"
#include "graphics/font.h"
#include "io/timer.h"
#include "graphics/colors.h"
#include "graphics/bitblt.h"
#include "graphics/grzbuffer.h"
static LPDIRECTDRAW lpDD = NULL;
static LPDIRECTDRAWSURFACE lpBackBuffer = NULL;
+23 -20
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/Graphics/GrGlide.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:05 $
* $Author: penguin $
*
* Code that uses 3DFX's Glide graphics library
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:07 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -213,26 +216,26 @@
#include <windows.h>
#include <windowsx.h>
#include "glide.h"
#include "glideutl.h"
#include "glide/glide.h"
#include "glide/glideutl.h"
#include "osapi.h"
#include "2d.h"
#include "bmpman.h"
#include "floating.h"
#include "palman.h"
#include "grinternal.h"
#include "grglide.h"
#include "line.h"
#include "font.h"
#include "mouse.h"
#include "key.h"
#include "systemvars.h"
#include "grglideinternal.h"
#include "cfile.h"
#include "timer.h"
#include "osapi/osapi.h"
#include "graphics/2d.h"
#include "bmpman/bmpman.h"
#include "math/floating.h"
#include "palman/palman.h"
#include "graphics/grinternal.h"
#include "graphics/grglide.h"
#include "graphics/line.h"
#include "graphics/font.h"
#include "io/mouse.h"
#include "io/key.h"
#include "globalincs/systemvars.h"
#include "graphics/grglideinternal.h"
#include "cfile/cfile.h"
#include "io/timer.h"
// #include "movie.h"
#include "neb.h"
#include "nebula/neb.h"
#define NEBULA_COLORS 20
+6 -3
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/Graphics/GrGlideInternal.h $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:05 $
* $Author: penguin $
*
* Common include file for Glide modules
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:07 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -51,7 +54,7 @@
#ifndef _GRGLIDEINTERNAL_H
#define _GRGLIDEINTERNAL_H
#include "grinternal.h"
#include "graphics/grinternal.h"
void glide_tcache_init();
void glide_tcache_cleanup();
+20 -17
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/Graphics/GrGlideTexture.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:05 $
* $Author: penguin $
*
* Code to manage Glide texture RAM
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:07 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -130,22 +133,22 @@
#include <windows.h>
#include <windowsx.h>
#include "glide.h"
#include "glideutl.h"
#include "glide/glide.h"
#include "glide/glideutl.h"
#include "osapi.h"
#include "2d.h"
#include "bmpman.h"
#include "floating.h"
#include "palman.h"
#include "grinternal.h"
#include "grglide.h"
#include "line.h"
#include "font.h"
#include "mouse.h"
#include "key.h"
#include "systemvars.h"
#include "grglideinternal.h"
#include "osapi/osapi.h"
#include "graphics/2d.h"
#include "bmpman/bmpman.h"
#include "math/floating.h"
#include "palman/palman.h"
#include "graphics/grinternal.h"
#include "graphics/grglide.h"
#include "graphics/line.h"
#include "graphics/font.h"
#include "io/mouse.h"
#include "io/key.h"
#include "globalincs/systemvars.h"
#include "graphics/grglideinternal.h"
#define TEXMEM_2MB_EDGE (2*1024*1024)
+8 -5
View File
@@ -9,13 +9,16 @@
/*
* $Logfile: /Freespace2/code/Graphics/GrInternal.h $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:22 $
* $Revision: 2.1 $
* $Date: 2002-08-01 01:41:05 $
* $Author: penguin $
*
* Include file for our Graphics directory
*
* $Log: not supported by cvs2svn $
* Revision 2.0 2002/06/03 04:02:22 penguin
* Warpcore CVS sync
*
* Revision 1.1 2002/05/02 18:03:07 mharris
* Initial checkin - converted filenames and includes to lower case
*
@@ -134,9 +137,9 @@
#ifndef _GRINTERNAL_H
#define _GRINTERNAL_H
#include "font.h"
#include "2d.h"
#include "grzbuffer.h"
#include "graphics/font.h"
#include "graphics/2d.h"
#include "graphics/grzbuffer.h"
extern int Gr_cursor;
+28 -14
View File
@@ -9,13 +9,23 @@
/*
* $Logfile: /Freespace2/code/Graphics/GrOpenGL.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 03:55:40 $
* $Revision: 2.3 $
* $Date: 2002-08-01 01:41:05 $
* $Author: penguin $
*
* Code that uses the OpenGL graphics library
*
* $Log: not supported by cvs2svn $
* Revision 2.2 2002/07/16 14:39:16 unknownplayer
* Updated to enable compilation under MSVC++ - all changes are marked
* with my name ##UnknownPlayer##
*
* Revision 2.1 2002/07/07 19:55:59 penguin
* Back-port to MSVC
*
* Revision 2.0 2002/06/03 03:55:40 penguin
* Warpcore CVS sync
*
* Revision 1.12 2002/06/03 03:40:34 mharris
* Only set projection matrix once (at init); aabitmap now uses
* the current_alpha setting
@@ -151,24 +161,26 @@
* $NoKeywords: $
*/
#if defined WIN32
#include <windows.h>
#ifndef WIN32 // ##UnknownPlayer##
#if defined _WIN32 // ##UnknownPlayer## - What's the point of this here?
#include <windows.h> // These should actually be the Win32 files for it I'd imagine
#include <windowsx.h>
#else
#include <SDL.h>
#include <SDL_opengl.h>
#endif
#include "pstypes.h"
#include "osapi.h"
#include "2d.h"
#include "bmpman.h"
#include "floating.h"
#include "palman.h"
#include "grinternal.h"
#include "gropengl.h"
#include "line.h"
#include "colors.h"
#include "globalincs/pstypes.h"
#include "osapi/osapi.h"
#include "graphics/2d.h"
#include "bmpman/bmpman.h"
#include "math/floating.h"
#include "palman/palman.h"
#include "graphics/grinternal.h"
#include "graphics/gropengl.h"
#include "graphics/line.h"
#include "graphics/colors.h"
SDL_Surface *opengl_screen = NULL;
ubyte *opengl_bmp_buffer = NULL;
@@ -1490,3 +1502,5 @@ int RunGLTest( int argc, char* argv[],
opengl_bmp_buffer = (ubyte *)malloc(w * h * 4); // 4 bytes for RGBA
return 0;
}
#endif // WIN32 //
+32 -26
View File
@@ -9,13 +9,19 @@
/*
* $Logfile: /Freespace2/code/Graphics/GrSoft.cpp $
* $Revision: 2.0 $
* $Date: 2002-06-03 04:02:23 $
* $Revision: 2.2 $
* $Date: 2002-08-01 01:41:05 $
* $Author: penguin $
*
* Code for our software renderer using standard Win32 functions. (Dibsections, etc)
*
* $Log: not supported by cvs2svn $
* Revision 2.1 2002/07/07 19:55:59 penguin
* Back-port to MSVC
*
* Revision 2.0 2002/06/03 04:02:23 penguin
* Warpcore CVS sync
*
* Revision 1.2 2002/05/17 02:52:38 mharris
* More porting hacks
*
@@ -361,33 +367,33 @@
#include <windows.h>
#include <windowsx.h>
#include "osapi.h"
#include "2d.h"
#include "bmpman.h"
#include "key.h"
#include "floating.h"
#include "palman.h"
#include "grsoft.h"
#include "grinternal.h"
#include "osapi/osapi.h"
#include "graphics/2d.h"
#include "bmpman/bmpman.h"
#include "io/key.h"
#include "math/floating.h"
#include "palman/palman.h"
#include "graphics/grsoft.h"
#include "graphics/grinternal.h"
// Headers for 2d functions
#include "pixel.h"
#include "line.h"
#include "scaler.h"
#include "tmapper.h"
#include "circle.h"
#include "shade.h"
#include "rect.h"
#include "gradient.h"
#include "pcxutils.h"
#include "osapi.h"
#include "mouse.h"
#include "font.h"
#include "timer.h"
#include "colors.h"
#include "bitblt.h"
#include "graphics/pixel.h"
#include "graphics/line.h"
#include "graphics/scaler.h"
#include "graphics/tmapper.h"
#include "graphics/circle.h"
#include "graphics/shade.h"
#include "graphics/rect.h"
#include "graphics/gradient.h"
#include "pcxutils/pcxutils.h"
#include "osapi/osapi.h"
#include "io/mouse.h"
#include "graphics/font.h"
#include "io/timer.h"
#include "graphics/colors.h"
#include "graphics/bitblt.h"
#ifdef WIN32
#ifdef _WIN32
// Windows specific
// This structure is the same as LOGPALETTE except that LOGPALETTE
Loaded 100 of 407 files, more files were not shown because too many files have changed in this diff. Show more