Nick Vader Posted June 17, 2011 Share Posted June 17, 2011 Why do I get errors when I compile this:confused: void main() { effect EffectDeath(int nSpectacularDeath=TRUE, int nDisplayFeedback=TRUE, int nNoFadeAway=TRUE); } This script was supposed to create a Death effect... Link to comment Share on other sites More sharing options...
VarsityPuppet Posted June 17, 2011 Share Posted June 17, 2011 You can't declare integer variables inside a function like that. effect eDeath = EffectDeath(TRUE, TRUE, TRUE); ApplyEffectToObject(DURATION_TYPE_INSTANT, eDeath, OBJECT_SELF); You'd want something like that. Link to comment Share on other sites More sharing options...
Istorian Posted June 17, 2011 Share Posted June 17, 2011 The correct script should look something like this: void main() { object oNPC = GetObjectByTag("[color="Red"]YOUR_TAG_HERE[/color]"); effect eDeath = EffectDeath(TRUE, TRUE, TRUE); ApplyEffectToObject(DURATION_TYPE_INSTANT, eDeath, oNPC, 0.0); } Just change the Red text to whatever you want in the mod! This should work! EDIT: Varsity, one step ahead of me! Link to comment Share on other sites More sharing options...
VarsityPuppet Posted June 17, 2011 Share Posted June 17, 2011 Er yeah, Istorian's is better, more health conscious. Link to comment Share on other sites More sharing options...
Nick Vader Posted June 18, 2011 Author Share Posted June 18, 2011 Er yeah, Istorian's is better, more health conscious. Haha! Thanks to both of you guys. And istorian: Show spoiler (hidden content - requires Javascript to show) euxaristw re... Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.