Initial commit
This commit is contained in:
commit
74162a93be
1366 files changed
+81395
No files matched your search
@@ -0,0 +1,43 @@
|
||||
#****************************************************************************
|
||||
#**
|
||||
#** File : /cdimage/units/UEB1201/UEB1201_script.lua
|
||||
#** Author(s): John Comes, Dave Tomandl, Jessica St. Croix, Fuegotigre, Kami, Squall
|
||||
#**
|
||||
#** Summary : Federated Suns T2 Power Generator Script
|
||||
#**
|
||||
#** Copyright © 2005 Gas Powered Games, Inc. All rights reserved.
|
||||
#****************************************************************************
|
||||
|
||||
local TEnergyCreationUnit = import('/lua/terranunits.lua').TEnergyCreationUnit
|
||||
|
||||
LAGENT2 = Class(TEnergyCreationUnit) {
|
||||
OnStopBeingBuilt = function(self,builder,layer)
|
||||
TEnergyCreationUnit.OnStopBeingBuilt(self,builder,layer)
|
||||
ChangeState(self, self.ActiveState)
|
||||
end,
|
||||
|
||||
ActiveState = State {
|
||||
Main = function(self)
|
||||
# Play the "Activate" sound
|
||||
local myBlueprint = self:GetBlueprint()
|
||||
if myBlueprint.Audio.Activate then
|
||||
self:PlaySound(myBlueprint.Audio.Activate)
|
||||
end
|
||||
end,
|
||||
|
||||
OnInActive = function(self)
|
||||
ChangeState(self, self.InActiveState)
|
||||
end,
|
||||
},
|
||||
|
||||
InActiveState = State {
|
||||
Main = function(self)
|
||||
end,
|
||||
|
||||
OnActive = function(self)
|
||||
ChangeState(self, self.ActiveState)
|
||||
end,
|
||||
},
|
||||
}
|
||||
|
||||
TypeClass = LAGENT2
|
||||
Reference in new issue
Block a user