def __init__(self, size, shaderName, shaderInputs, inputTextureName, randomVal1, randomVal2):
    self.explosionCard = Explosion.getCard()
    self.explosionCard.setScale(size)
    self.explosionCard.setBin('unsorted', 1)
    self.explosionCard.setDepthWrite(False)
    self.explosionCard.setAttrib(ColorBlendAttrib.make(ColorBlendAttrib.MAdd, ColorBlendAttrib.OIncomingAlpha, ColorBlendAttrib.OOne))
    self.explosionCard.setBillboardPointEye()
    shader = Shader.load(Shader.SL_GLSL, '../Section2SpaceflightDocking/Shaders/{0}Vertex.glsl'.format(shaderName), '../Section2SpaceflightDocking/Shaders/{0}Fragment.glsl'.format(shaderName))
    self.explosionCard.setShader(shader)
    for (inputName, inputValue) in shaderInputs.items():
        self.explosionCard.setShaderInput(inputName, inputValue)
    self.explosionCard.setShaderInput('sourceTex1', Common.framework.showBase.loader.loadTexture('../Section2SpaceflightDocking/Shaders/{0}1.png'.format(inputTextureName)))
    self.explosionCard.setShaderInput('sourceTex2', Common.framework.showBase.loader.loadTexture('../Section2SpaceflightDocking/Shaders/{0}2.png'.format(inputTextureName)))
    self.explosionCard.setShaderInput('randomisation1', randomVal1)
    self.explosionCard.setShaderInput('randomisation2', randomVal2)
    self.calcFullDuration(shaderInputs)
    self.startTime = (- 1000)
    self.explosionCard.setShaderInput('startTime', self.startTime)
    self.velocity = Vec3(0, 0, 0)
def __init__(self, size, shaderName, shaderInputs, inputTextureName, randomVal1, randomVal2):
    self.explosionCard = Explosion.getCard()
    self.explosionCard.setScale(size)
    self.explosionCard.setBin('unsorted', 1)
    self.explosionCard.setDepthWrite(False)
    self.explosionCard.setAttrib(ColorBlendAttrib.make(ColorBlendAttrib.MAdd, ColorBlendAttrib.OIncomingAlpha, ColorBlendAttrib.OOne))
    self.explosionCard.setBillboardPointEye()
    shader = Shader.load(Shader.SL_GLSL, '../Section2SpaceflightDocking/Shaders/{0}Vertex.glsl'.format(shaderName), '../Section2SpaceflightDocking/Shaders/{0}Fragment.glsl'.format(shaderName))
    self.explosionCard.setShader(shader)
    for (inputName, inputValue) in shaderInputs.items():
        self.explosionCard.setShaderInput(inputName, inputValue)
    self.explosionCard.setShaderInput('sourceTex1', Common.framework.showBase.loader.loadTexture('../Section2SpaceflightDocking/Shaders/{0}1.png'.format(inputTextureName)))
    self.explosionCard.setShaderInput('sourceTex2', Common.framework.showBase.loader.loadTexture('../Section2SpaceflightDocking/Shaders/{0}2.png'.format(inputTextureName)))
    self.explosionCard.setShaderInput('randomisation1', randomVal1)
    self.explosionCard.setShaderInput('randomisation2', randomVal2)
    self.calcFullDuration(shaderInputs)
    self.startTime = (- 1000)
    self.explosionCard.setShaderInput('startTime', self.startTime)
    self.velocity = Vec3(0, 0, 0)