- Make the autosegs read-only.
- Derive PClass from dobject.cpp. This has one major ramification: Since the PClass is not allocated until runtime, you cannot initialize any static/global data structures with pointers to PClasses using RUNTIME_CLASS. Attempting to do so will just initialize with a NULL pointer. Instead, you can initialize using the address of the pointer returned by RUNTIME_CLASS and dereference that. By the time you have an opportunity to dereference it, it will no longer be NULL. - Sync CmakeLists.txt. - Random fixes for problems GCC spotted. SVN r1852 (scripting)
This commit is contained in:
parent
92766165f5
commit
1eb7912bd8
35 changed files with 258 additions and 207 deletions
18
src/info.cpp
18
src/info.cpp
|
|
@ -39,9 +39,8 @@
|
|||
#include "m_fixed.h"
|
||||
#include "c_dispatch.h"
|
||||
#include "d_net.h"
|
||||
|
||||
#include "gi.h"
|
||||
|
||||
#include "vm.h"
|
||||
#include "actor.h"
|
||||
#include "r_state.h"
|
||||
#include "i_system.h"
|
||||
|
|
@ -52,6 +51,21 @@
|
|||
|
||||
extern void LoadActors ();
|
||||
|
||||
bool FState::CallAction(AActor *self, AActor *stateowner, StateCallData *statecall)
|
||||
{
|
||||
if (ActionFunc != NULL)
|
||||
{
|
||||
//ActionFunc(self, stateowner, this, ParameterIndex-1, statecall);
|
||||
VMFrameStack stack;
|
||||
VMValue params[5] = { self, stateowner, this, ParameterIndex - 1, VMValue(statecall, ATAG_STATE) };
|
||||
stack.Call(ActionFunc, params, countof(params), NULL, 0, NULL);
|
||||
return true;
|
||||
}
|
||||
else
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
//==========================================================================
|
||||
//
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue