Fixed x64 script/class connections and added material flags that are needed.

This commit is contained in:
Justin Marshall
2026-05-05 16:20:05 -07:00
parent 8d5f678b25
commit d06356e042
12 changed files with 2437 additions and 2202 deletions
+16 -5
View File
@@ -5,7 +5,7 @@
#define __SCRIPT_INTERPRETER_H__
#define MAX_STACK_DEPTH 64
#define LOCALSTACK_SIZE 6144
#define LOCALSTACK_SIZE (6144 * 2)
typedef struct prstack_s {
int s;
@@ -33,10 +33,11 @@ private:
idThread *thread;
void PushVector(const idVec3& vector);
void PopParms( int numParms );
void PushString( const char *string );
public://HUMANHEAD: aob - so we can pass parms in manually
void Push( int value );
void Push( intptr_t value );
private://HUMANHEAD: aob - undo the public declaration
const char *FloatToString( float value );
void AppendString( idVarDef *def, const char *from );
@@ -115,12 +116,12 @@ ID_INLINE void idInterpreter::PopParms( int numParms ) {
idInterpreter::Push
====================
*/
ID_INLINE void idInterpreter::Push( int value ) {
ID_INLINE void idInterpreter::Push(intptr_t value ) {
if ( localstackUsed + sizeof( int ) > LOCALSTACK_SIZE ) {
Error( "Push: locals stack overflow\n" );
}
*( int * )&localstack[ localstackUsed ] = value;
localstackUsed += sizeof( int );
*(intptr_t*)&localstack[localstackUsed] = value;
localstackUsed += sizeof(intptr_t);
}
/*
@@ -248,4 +249,14 @@ ID_INLINE void idInterpreter::NextInstruction( int position ) {
instructionPointer = position - 1;
}
ID_INLINE void idInterpreter::PushVector(const idVec3& vector)
{
if (localstackUsed + E_EVENT_SIZEOF_VEC > LOCALSTACK_SIZE)
{
Error("Push: locals stack overflow\n");
}
*(idVec3*)&localstack[localstackUsed] = vector;
localstackUsed += E_EVENT_SIZEOF_VEC;
}
#endif /* !__SCRIPT_INTERPRETER_H__ */