Code: |
#include "NW_I0_GENERIC"
void VoidCreateObject(string sTemplate, location lLoc) { CreateObject(OBJECT_TYPE_CREATURE, sTemplate,lLoc); } void main() { if(GetSpawnInCondition(NW_FLAG_DEATH_EVENT)) { SignalEvent(OBJECT_SELF, EventUserDefined(1007)); } object oSelf = OBJECT_SELF; location lLoca = GetLocalLocation( oSelf, "lSpawn"); float fSeconds = 600; //temps en secondes pour le respawn string sTemplate = GetResRef( oSelf ); AssignCommand( GetArea( oSelf ) , DelayCommand( fSeconds, VoidCreateObject( sTemplate, lLoca ) ) ); } |
Sûrement parceque 600 n'est pas un float. Essaie de mettre "600.", "600.0", "600f", "600.f" ou encore "600.0f" .
Code: |
#include "NW_I0_GENERIC"
void VoidCreateObject(string sTemplate, location lLoc) { CreateObject(OBJECT_TYPE_CREATURE, sTemplate,lLoc); } void main() { if(GetSpawnInCondition(NW_FLAG_DEATH_EVENT)) { SignalEvent(OBJECT_SELF, EventUserDefined(1007)); } object oSelf = OBJECT_SELF; location lLoca = GetLocalLocation( oSelf, "lSpawn"); float fSeconds = 600.0; //temps en secondes pour le respawn string sTemplate = GetResRef( oSelf ); AssignCommand( GetArea( oSelf ) , DelayCommand( fSeconds, VoidCreateObject( sTemplate, lLoca ) ) ); } |
Code: |
#include "NW_O2_CONINCLUDE"
#include "NW_I0_GENERIC" void main() { SetListeningPatterns(); WalkWayPoints(); GenerateNPCTreasure(); object oSelf = OBJECT_SELF; SetLocalLocation( oSelf, "lSpawn", GetLocation( oSelf ) ); } |