74     C4Effect *pCheck, *pPrev = *ppEffectList;
 
   77         while ((pCheck = pPrev->
pNext))
 
   78                 if (
Abs(pCheck->
iPriority) >= iPrio) 
break; 
else pPrev = pCheck;
 
   86         pNext = *ppEffectList;
 
   93     C4Effect * pEffect = 
new C4Effect(ppEffectList, szName, iPrio, iTimerInterval, pCmdTarget);
 
   94     return pEffect->
Init(pForObj, iPrio, rVal1, rVal2, rVal3, rVal4);
 
   99     C4Effect * pEffect = 
new C4Effect(ppEffectList, prototype, iPrio, iTimerInterval);
 
  100     return pEffect->
Init(pForObj, iPrio, rVal1, rVal2, rVal3, rVal4);
 
  107     bool fRemoveUpper = (iPrio != 1);
 
  112     if (fRemoveUpper && 
pNext)
 
  129     C4Effect *pLastRemovedEffect=
nullptr;
 
  134         if (pForObj && !pForObj->
Status) 
return nullptr;
 
  139     if (fRemoveUpper && 
pNext && pFn)
 
  142     if (pForObj && !pForObj->
Status) 
return nullptr; 
 
  147     if (fRemoveUpper && 
pNext && pFn)
 
  149     if (pForObj && !pForObj->
Status) 
return nullptr; 
 
  168     while ((pEffect = 
pNext))
 
  171         pEffect->
pNext = 
nullptr;
 
  186         pEff->C4PropList::Denumerate(numbers);
 
  188     while ((pEff=pEff->
pNext));
 
  202     while ((pEff=pEff->
pNext));
 
  213     if (!szName) 
return nullptr;
 
  219         if (pEff->
IsDead()) 
continue;
 
  221         if (iMaxPriority && pEff->
iPriority > iMaxPriority) 
continue;
 
  223         const char *szEffectName = pEff->
GetName();
 
  227         if (iIndex--) 
continue;
 
  231     while ((pEff=pEff->
pNext));
 
  242                 if (!iMaxPriority || pEff->
iPriority <= iMaxPriority)
 
  244     while ((pEff = pEff->
pNext));
 
  252     if (iPrio == 1) 
return nullptr;
 
  254     C4Effect *pAddToEffect = 
nullptr; 
bool fDoTempCallsForAdd = 
false;
 
  255     C4Effect *pLastRemovedEffect=
nullptr;
 
  256     for (
C4Effect *pCheck = 
this; pCheck; pCheck = pCheck->
pNext)
 
  258         if (!pCheck->IsDead() && pCheck->iPriority >= iPrio)
 
  260             int32_t 
iResult = pCheck->CallEffect(szCheckEffect, rVal1, rVal2, rVal3, rVal4);
 
  267                 pAddToEffect = pCheck;
 
  276         if (pAddToEffect->
pNext && fDoTempCallsForAdd)
 
  281         if (pAddToEffect->
pNext && fDoTempCallsForAdd)
 
  286             pAddToEffect->
Kill();
 
  301     for (
C4Effect *pEffect = *ppEffectList; pEffect; pEffect = pEffect->
pNext)
 
  308     C4Effect *pEffect = *ppEffectList, **ppPrevEffect=ppEffectList;
 
  316             pEffect->
pNext = 
nullptr;
 
  319             *ppPrevEffect = pEffect = pNextEffect;
 
  337             ppPrevEffect = &pEffect->
pNext;
 
  338             pEffect = pEffect->
pNext;
 
  346     C4Effect *pLastRemovedEffect=
nullptr;
 
  401             pEff->
CallDamage(riDamage, iDamageType, iCausePlr);
 
  404     while ((pEff = pEff->
pNext) && riDamage);
 
  415         if (fn) 
return fn->
Exec(
this, &
C4AulParSet(rVal1, rVal2, rVal3, rVal4, rVal5, rVal6, rVal7));
 
  422         if (fn) 
return fn->
Exec(p, &
C4AulParSet(Obj(pObj), 
this, rVal1, rVal2, rVal3, rVal4, rVal5, rVal6, rVal7));
 
  492         pCheck = pCheck->
pNext;
 
  504         while (pEff) 
if (pEff->
IsActive()) 
break; 
else pEff = pEff->
pNext;
 
  517         if (!*ppLastRemovedEffect) *ppLastRemovedEffect = 
this;
 
  524     if (!pLastReaddEffect) 
return;
 
  529         if (pEff->IsInactiveAndNotDead())
 
  537         if (pEff == pLastReaddEffect) 
break;
 
  584     bool fNext = !! 
pNext;
 
#define C4AUL_MAX_Identifier
#define C4Fx_Execute_Kill
#define C4Fx_Effect_Annul
#define C4Fx_Effect_AnnulCalls
#define C4FxCall_TempAddForRemoval
C4AulScriptEngine ScriptEngine
bool DebugLogF(const char *strMessage ...)
C4Value C4VInt(int32_t i)
C4Value C4VString(C4String *pStr)
bool SWildcardMatchEx(const char *szString, const char *szWildcard)
StdPtrAdapt< T > mkPtrAdaptNoNull(T *&rpObj)
StdParameterAdapt< T, P > mkParAdapt(T &&rObj, P &&rPar)
StdStrBuf FormatString(const char *szFmt,...)
bool WildcardMatch(const char *szWildcard, const char *szString)
virtual void OnError(const char *msg)=0
const char * what() const noexcept override
C4Value Exec(C4PropList *p=nullptr, C4AulParSet *pPars=nullptr, bool fPassErrors=false)
bool GetGlobalConstant(const char *szName, C4Value *pTargetValue)
C4AulErrorHandler * GetErrorHandler() const
void AssignCallbackFunctions()
int CallStop(int reason, bool temporary)
C4Value DoCall(C4PropList *pObj, const char *szFn, const C4Value &rVal1, const C4Value &rVal2, const C4Value &rVal3, const C4Value &rVal4, const C4Value &rVal5, const C4Value &rVal6, const C4Value &rVal7)
static C4Effect * New(C4PropList *pForObj, C4Effect **ppEffectList, C4String *szName, int32_t iPrio, int32_t iTimerInterval, C4PropList *pCmdTarget, const C4Value &rVal1, const C4Value &rVal2, const C4Value &rVal3, const C4Value &rVal4)
void DoDamage(int32_t &riDamage, int32_t iDamageType, int32_t iCausePlr)
C4PropList * GetCallbackScript()
C4ValueArray * GetProperties() const override
C4Effect * Check(const char *szCheckEffect, int32_t iPrio, int32_t iTimer, const C4Value &rVal1, const C4Value &rVal2, const C4Value &rVal3, const C4Value &rVal4)
void TempRemoveUpperEffects(bool fTempRemoveThis, C4Effect **ppLastRemovedEffect)
void Denumerate(C4ValueNumbers *) override
void Register(C4Effect **ppEffectList, int32_t iPrio)
void CallDamage(int32_t &damage, int damagetype, int plr)
void ResetProperty(C4String *k) override
bool GetPropertyByS(const C4String *k, C4Value *pResult) const override
void SetPropertyByS(C4String *k, const C4Value &to) override
void ClearPointers(C4PropList *pObj)
void ReAssignCallbackFunctions()
void OnObjectChangedDef(C4PropList *pObj)
C4Effect * Get(const char *szName, int32_t iIndex=0, int32_t iMaxPriority=0)
int CallEffect(const char *effect, const C4Value &var1, const C4Value &var2, const C4Value &var3, const C4Value &var4)
int CallStart(int temporary, const C4Value &var1, const C4Value &var2, const C4Value &var3, const C4Value &var4)
int32_t GetCount(const char *szMask, int32_t iMaxPriority=0)
C4Effect * Init(C4PropList *pForObj, int32_t iPrio, const C4Value &rVal1, const C4Value &rVal2, const C4Value &rVal3, const C4Value &rVal4)
static void Execute(C4Effect **ppEffectList)
void ClearAll(int32_t iClearFlag)
void TempReaddUpperEffects(C4Effect *pLastReaddEffect)
void CompileFunc(StdCompiler *pComp, C4PropList *Owner, C4ValueNumbers *)
virtual C4Object * GetObject()
C4AulFunc * GetFunc(C4PropertyName k) const
virtual const char * GetName() const
virtual C4ValueArray * GetProperties() const
virtual class C4PropListStatic * IsStatic()
virtual bool GetPropertyByS(const C4String *k, C4Value *pResult) const
virtual void SetOnFire(bool OnFire)
virtual void ResetProperty(C4String *k)
virtual C4PropListNumbered * GetPropListNumbered()
C4Value Call(C4PropertyName k, C4AulParSet *pPars=nullptr, bool fPassErrors=false)
virtual void SetPropertyByS(C4String *k, const C4Value &to)
void SetProperty(C4PropertyName k, const C4Value &to)
void CompileFunc(StdCompiler *pComp, C4ValueNumbers *numbers)
void RefCompileFunc(StdCompiler *pComp, C4ValueNumbers *numbers) const
const char * GetCStr() const
void SetPropList(C4PropList *PropList)
C4PropList * _getPropList() const
C4String * getStr() const
void SetObjectEnum(int i)
C4PropList * getPropList() const
void Denumerate(C4ValueNumbers *)
virtual bool Separator(Sep eSep=SEP_SEP)
void Value(const T &rStruct)
virtual void String(char *szString, size_t iMaxLength, RawCompileType eType=RCT_Escaped)=0
virtual bool isDeserializer()