@name FUS RO DAH chip by malar163
@inputs 
@outputs TargX TargY TargZ Target:entity
@persist Blast BlastFinish
@trigger 
#credit to TeamKill4 for helping me with this e2
runOnChat(1)
if(first()) {
owner():soundPlay(5,100,"/hl1/fvox/activated.wav")
hint("Made by malar163",5)
}
if(owner():lastSaid() == "FUS RO DAH" & !first()) {Blast = 1} else {Blast = 0}

findInCone(owner():shootPos(),owner():eye(),1000,60)
    
Target=findResult(1)

Targetfirstpos = Target:pos()
TargX = Targetfirstpos:x()
TargY = Targetfirstpos:y()
TargZ = Targetfirstpos:z()


if(Blast&$Blast) {
    Target:applyForce((Target:pos()-(owner():shootPos()-vec(0,0,200)))*Target:mass()*100)
#    printColor(vec(255,0,0),"Level",vec(255,255,255),": DRAGONBORN!")
#    concmd("say DRAGONBORN")
    owner():soundPlay(5,100,"/hl1/ambience/steamburst1.wav")
    BlastFinish = 1
}
if(BlastFinish == 1) {Blast = 0} else {BlastFinish = 0}

if(owner():lastSaid() == "PROPPUS CREATUS CRATEUS") {
    propSpawn("models/props_junk/wood_crate002a.mdl",owner():aimPos(),0)
    owner():soundPlay(5,200,"/common/bass.wav")
}
