JANITORIAL: AGS: Fix typos

This commit is contained in:
Hubert Maier authored and GitHub committed 2024-12-25 17:08:44 +02:00
1 parent f54fd81b4f
commit 76210767fa
4 files changed
+5 -5

No files matched your search

@@ -29,7 +29,7 @@
// byte buffer.
//
// AGSCCDynamicObject, extends CCBasicObject: parent for built-in dynamic
// object managers; provides simplier serialization methods working with
// object managers; provides simpler serialization methods working with
// streams instead of a raw memory buffer.
//
// AGSCCStaticObject, extends CCBasicObject: a formal stub, intended as
+2 -2
View File
@@ -76,11 +76,11 @@ void run_function_on_non_blocking_thread(NonBlockingScriptFunction *funcToRun
// Runs the ObjectEvent using an old interaction callback type of 'evnt' index,
// or alternatively of 'chkAny' index, if previous does not exist;
// 'isInv' tells if this is a inventory event (it has a slightly different handling for that)
// Returns 0 normally, or -1 telling of a game state change (eg. a room change occured).
// Returns 0 normally, or -1 telling of a game state change (eg. a room change occurred).
int run_interaction_event(const ObjectEvent &obj_evt, Interaction *nint, int evnt, int chkAny = -1, bool isInv = false);
// Runs the ObjectEvent using a script callback of 'evnt' index,
// or alternatively of 'chkAny' index, if previous does not exist
// Returns 0 normally, or -1 telling of a game state change (eg. a room change occured).
// Returns 0 normally, or -1 telling of a game state change (eg. a room change occurred).
int run_interaction_script(const ObjectEvent &obj_evt, InteractionScripts *nint, int evnt, int chkAny = -1);
int run_interaction_commandlist(const ObjectEvent &obj_evt, InteractionCommandList *nicl, int *timesrun, int *cmdsrun);
void run_unhandled_event(const ObjectEvent &obj_evt, int evnt);
+1 -1
View File
@@ -128,7 +128,7 @@ public:
// StreamSection does NOT own the base stream, and closing
// a "stream section" does NOT close the base stream.
// Base stream must stay in memory for as long as there are
// "stream sections" refering it.
// "stream sections" referring it.
class DataStreamSection : public DataStream {
public:
// Constructs a StreamSection over a base stream,
+1 -1
View File
@@ -73,7 +73,7 @@ int ags_strncpy_s(char *dest, size_t dest_sz, const char *src, size_t count) {
for (; *psrc && (psrc != src_end); ++psrc, ++pdst)
*pdst = *psrc;
*pdst = 0; // ensure null terminator
assert((*psrc == 0) || ((psrc - src) == (int)count)); // assert that no *unintended* truncation occured
assert((*psrc == 0) || ((psrc - src) == (int)count)); // assert that no *unintended* truncation occurred
if ((*psrc != 0) && ((psrc - src) < (int)count))
return AL_ERANGE; // not enough dest buffer - error
return 0; // success