@name FileWriteFunction
@inputs
@outputs
@persist 
@trigger 
interval(100)

if (changed(owner():keyUse()) & owner():keyUse() & fileCanWrite()) {
    if (owner():aimEntity():type() == "prop_physics") {
        PosString = entity():toLocal(owner():aimEntity():pos()):toString():replace("[",""):replace("]","")
        AngString = round(owner():aimEntity():toLocal(entity():angles())):toString():replace("[",""):replace("]","")
        HoloModel = owner():aimEntity():model()
        owner():aimEntity():propDelete()
        
Text = "@name Holo Test 1
@inputs 
@outputs 
@persist 
@trigger 
interval(500)

if (first() | dupefinished()) {M = 30}

if (I < M & holoCanCreate()) {
    I++
    holoCreate(1)
    holoModel(1,\""+HoloModel+"\")
    holoPos(1,entity():toWorld(vec("+PosString+")))
    holoAng(1,entity():toWorld(ang("+AngString+")))
    holoParent(1,entity())
}
"
    }
    fileWrite("AAAA.txt",Text)
    entity():propDelete()
}

#[
Prop = table()
Prop[ "model", string ] = "aaweawewa.mdl"
Prop[ "pos", vector ] = vec
PropList[ PropList:count()  + 1, table ] = Prop
