strings.h
author matthijs
Wed, 22 Mar 2006 22:26:16 +0000
branch0.4.5
changeset 9958 bed516c67d61
parent 2436 177cb6a8339f
child 4386 04c0a9fe59c9
permissions -rw-r--r--
(svn r4041) [Debian] Change next version number to 0.4.6 instead of 0.4.5.1.
2186
461a2aff3486 (svn r2701) Insert Id tags into all source files
tron
parents: 2087
diff changeset
     1
/* $Id$ */
461a2aff3486 (svn r2701) Insert Id tags into all source files
tron
parents: 2087
diff changeset
     2
1309
dab90d4cbf2d (svn r1813) Declare functions implemented in strings.c in their own shiny new header (though i think some of these function don't belong into strings.c)
tron
parents:
diff changeset
     3
#ifndef STRINGS_H
dab90d4cbf2d (svn r1813) Declare functions implemented in strings.c in their own shiny new header (though i think some of these function don't belong into strings.c)
tron
parents:
diff changeset
     4
#define STRINGS_H
dab90d4cbf2d (svn r1813) Declare functions implemented in strings.c in their own shiny new header (though i think some of these function don't belong into strings.c)
tron
parents:
diff changeset
     5
1553
4976359e2bf9 (svn r2057) Add InlineString() to make _userstring construction a bit cleaner.
tron
parents: 1312
diff changeset
     6
static inline char* InlineString(char* buf, uint16 string)
4976359e2bf9 (svn r2057) Add InlineString() to make _userstring construction a bit cleaner.
tron
parents: 1312
diff changeset
     7
{
4976359e2bf9 (svn r2057) Add InlineString() to make _userstring construction a bit cleaner.
tron
parents: 1312
diff changeset
     8
	*buf++ = '\x81';
4976359e2bf9 (svn r2057) Add InlineString() to make _userstring construction a bit cleaner.
tron
parents: 1312
diff changeset
     9
	*buf++ = string & 0xFF;
4976359e2bf9 (svn r2057) Add InlineString() to make _userstring construction a bit cleaner.
tron
parents: 1312
diff changeset
    10
	*buf++ = string >> 8;
4976359e2bf9 (svn r2057) Add InlineString() to make _userstring construction a bit cleaner.
tron
parents: 1312
diff changeset
    11
	return buf;
4976359e2bf9 (svn r2057) Add InlineString() to make _userstring construction a bit cleaner.
tron
parents: 1312
diff changeset
    12
}
4976359e2bf9 (svn r2057) Add InlineString() to make _userstring construction a bit cleaner.
tron
parents: 1312
diff changeset
    13
1312
8defbb525d09 (svn r1816) Use char instead of byte for string formatting
tron
parents: 1309
diff changeset
    14
char *GetString(char *buffr, uint16 string);
2087
bedb167de57b (svn r2597) Feature: [string system] Support cases.
ludde
parents: 2063
diff changeset
    15
char *GetStringWithArgs(char *buffr, uint string, const int32 *argv);
2063
95259a31ceb5 (svn r2572) - Codechange: [string] Changed string system so it's not as dependent on decode_parameters
ludde
parents: 2056
diff changeset
    16
2202
2d6c235d53cc (svn r2718) Forgot one file
tron
parents: 2186
diff changeset
    17
extern char _userstring[128];
2d6c235d53cc (svn r2718) Forgot one file
tron
parents: 2186
diff changeset
    18
1309
dab90d4cbf2d (svn r1813) Declare functions implemented in strings.c in their own shiny new header (though i think some of these function don't belong into strings.c)
tron
parents:
diff changeset
    19
void InjectDParam(int amount);
dab90d4cbf2d (svn r1813) Declare functions implemented in strings.c in their own shiny new header (though i think some of these function don't belong into strings.c)
tron
parents:
diff changeset
    20
int32 GetParamInt32(void);
dab90d4cbf2d (svn r1813) Declare functions implemented in strings.c in their own shiny new header (though i think some of these function don't belong into strings.c)
tron
parents:
diff changeset
    21
2436
177cb6a8339f (svn r2962) - const correctness for all Get* functions and most Draw* functions that don't change their pointer parameters
Darkvater
parents: 2291
diff changeset
    22
#endif /* STRINGS_H */