Forged Alliance Forever Forged Alliance Forever Forums 2016-08-26T14:30:19+02:00 /feed.php?f=41&t=13004 2016-08-26T14:30:19+02:00 2016-08-26T14:30:19+02:00 /viewtopic.php?t=13004&p=133562#p133562 <![CDATA[Re: Avoiding Function Overflow Crash]]> Statistics: Posted by RocketRooster — 26 Aug 2016, 14:30


]]>
2016-08-26T14:13:21+02:00 2016-08-26T14:13:21+02:00 /viewtopic.php?t=13004&p=133559#p133559 <![CDATA[Re: Avoiding Function Overflow Crash]]> Statistics: Posted by RavenCurow — 26 Aug 2016, 14:13


]]>
2016-08-26T13:35:12+02:00 2016-08-26T13:35:12+02:00 /viewtopic.php?t=13004&p=133558#p133558 <![CDATA[Re: Avoiding Function Overflow Crash]]> for example in this mml missile script:

Code:
SIFLaanseTacticalMissile01EQ = Class(SLaanseTacticalMissile) {
   
    OnCreate = function(self)
        SLaanseTacticalMissile.OnCreate(self)
        self:SetCollisionShape('Sphere', 0, 0, 0, 2)
        self.MoveThread = self:ForkThread(self.MovementThread)
    end,
}
*rest of code snipped*

we have the OnCreate and in there we have some extra stuff we want to do but first we call the original OnCreate by referring to the class of the projectile SLaanseTacticalMissile
Code:
        SLaanseTacticalMissile.OnCreate(self)


is the line. you want to think about where you put that. sometimes you want the original code to run before, sometimes after.


hope that this is what you wanted to know

Statistics: Posted by Exotic_Retard — 26 Aug 2016, 13:35


]]>
2016-08-26T13:29:04+02:00 2016-08-26T13:29:04+02:00 /viewtopic.php?t=13004&p=133557#p133557 <![CDATA[Avoiding Function Overflow Crash]]>
This time around I'm looking at functions. I'm trying to call an OnImpact function in a projectile script, but the base faction projectiles lua already has the OnImpact script. Is there a way I can add on to that function in my script without having to do a round about hook? The effect I want to add to the projectile is not one I want every unit who uses the base projectile to have.

Statistics: Posted by RavenCurow — 26 Aug 2016, 13:29


]]>