aboutsummaryrefslogtreecommitdiffstats
path: root/code/botlib
diff options
context:
space:
mode:
authoricculus <icculus@edf5b092-35ff-0310-97b2-ce42778d08ea>2005-11-26 07:46:21 +0000
committericculus <icculus@edf5b092-35ff-0310-97b2-ce42778d08ea>2005-11-26 07:46:21 +0000
commit441c7633e0aa67faa91dc5896ee83e6c29de0ba6 (patch)
treeed6f97f0be5940123e9e3f244ae91a475787ff64 /code/botlib
parentb0c6a473e2a34000db73c75bc0ff43bba45fddb2 (diff)
downloadioquake3-aero-441c7633e0aa67faa91dc5896ee83e6c29de0ba6.tar.gz
ioquake3-aero-441c7633e0aa67faa91dc5896ee83e6c29de0ba6.zip
Mac OS X work...lots of little changes that touch a lot of random places.
Still work to be done, but this at least matches the PowerPC Linux status now. MacOS-specific directory (and XCode project) is gone...this now uses SDL, OpenAL, and the Unix Makefiles. --ryan. git-svn-id: svn://svn.icculus.org/quake3/trunk@373 edf5b092-35ff-0310-97b2-ce42778d08ea
Diffstat (limited to 'code/botlib')
-rw-r--r--code/botlib/l_script.c16
-rw-r--r--code/botlib/l_script.h4
2 files changed, 10 insertions, 10 deletions
diff --git a/code/botlib/l_script.c b/code/botlib/l_script.c
index 7880330..e721891 100644
--- a/code/botlib/l_script.c
+++ b/code/botlib/l_script.c
@@ -554,7 +554,7 @@ int PS_ReadName(script_t *script, token_t *token)
// Changes Globals: -
//============================================================================
void NumberValue(char *string, int subtype, unsigned long int *intvalue,
- long double *floatvalue)
+ double *floatvalue)
{
unsigned long int dotfound = 0;
@@ -573,13 +573,13 @@ void NumberValue(char *string, int subtype, unsigned long int *intvalue,
} //end if
if (dotfound)
{
- *floatvalue = *floatvalue + (long double) (*string - '0') /
- (long double) dotfound;
+ *floatvalue = *floatvalue + (double) (*string - '0') /
+ (double) dotfound;
dotfound *= 10;
} //end if
else
{
- *floatvalue = *floatvalue * 10.0 + (long double) (*string - '0');
+ *floatvalue = *floatvalue * 10.0 + (double) (*string - '0');
} //end else
string++;
} //end while
@@ -631,7 +631,7 @@ int PS_ReadNumber(script_t *script, token_t *token)
int octal, dot;
char c;
// unsigned long int intvalue = 0;
-// long double floatvalue = 0;
+// double floatvalue = 0;
token->type = TT_NUMBER;
//check for a hexadecimal number
@@ -1148,15 +1148,15 @@ void StripSingleQuotes(char *string)
// Returns: -
// Changes Globals: -
//============================================================================
-long double ReadSignedFloat(script_t *script)
+double ReadSignedFloat(script_t *script)
{
token_t token;
- long double sign = 1;
+ double sign = 1.0;
PS_ExpectAnyToken(script, &token);
if (!strcmp(token.string, "-"))
{
- sign = -1;
+ sign = -1.0;
PS_ExpectTokenType(script, TT_NUMBER, 0, &token);
} //end if
else if (token.type != TT_NUMBER)
diff --git a/code/botlib/l_script.h b/code/botlib/l_script.h
index 01cc35c..7fe4ac9 100644
--- a/code/botlib/l_script.h
+++ b/code/botlib/l_script.h
@@ -161,7 +161,7 @@ typedef struct token_s
int subtype; //last read token sub type
#ifdef NUMBERVALUE
unsigned long int intvalue; //integer value
- long double floatvalue; //floating point value
+ double floatvalue; //floating point value
#endif //NUMBERVALUE
char *whitespace_p; //start of white space before token
char *endwhitespace_p; //start of white space before token
@@ -218,7 +218,7 @@ void StripSingleQuotes(char *string);
//read a possible signed integer
signed long int ReadSignedInt(script_t *script);
//read a possible signed floating point number
-long double ReadSignedFloat(script_t *script);
+double ReadSignedFloat(script_t *script);
//set an array with punctuations, NULL restores default C/C++ set
void SetScriptPunctuations(script_t *script, punctuation_t *p);
//set script flags