03-02-2007, 09:59 AM
All scripts can be obtained from the following link
My Scripts
Well i said i was practicing scripting and that i would help anyone that needs it so here are some scripts i wrote or modifeid from the CS. All work as they should, well i tested them and the CS excepts them. I will post them up and if i get enough interest i will upload them all and post a link. Enjoy.
scn zzScript01
;it adds and item to the player with whatever number you stated once.
Short DoOnce
Begin Gamemode
If (DoOnce == 0)
player.additem [Add Item ID]
set DoOnce to 1
endif
end
___________________________________________
scn zzScript02
short talked
begin gamemode
if talked == 0 && getdistance player < 1000
startconversation (Enter You NPC Reference] [Enter You Topic]
set talked to 1
endif
end
___________________________________________
scn zzScript06
; This script adds a special visual effect to the creature when this script is attached
begin ScriptEffectStart
PlayMagicShaderVisuals [Enter The effect ID Here]
end
begin ScriptEffectFinish
StopMagicShaderVisuals [Enter The effect ID Here]
end
___________________________________________
ScriptName zzScript08
; This script will automatically close and lock a door
float doorTimer
short closeDoor
Begin GameMode
if closeDoor == 1
if doorTimer > 0
set doorTimer to doorTimer - getSecondsPassed
else
;close the door
Activate
Lock
set closeDoor to 0
endif
endif
End
Begin OnActivate
Activate
if IsActionRef Player == 0
set doorTimer to 5
set closeDoor to 1
endif
End
My Scripts
Well i said i was practicing scripting and that i would help anyone that needs it so here are some scripts i wrote or modifeid from the CS. All work as they should, well i tested them and the CS excepts them. I will post them up and if i get enough interest i will upload them all and post a link. Enjoy.
scn zzScript01
;it adds and item to the player with whatever number you stated once.
Short DoOnce
Begin Gamemode
If (DoOnce == 0)
player.additem [Add Item ID]
set DoOnce to 1
endif
end
___________________________________________
scn zzScript02
short talked
begin gamemode
if talked == 0 && getdistance player < 1000
startconversation (Enter You NPC Reference] [Enter You Topic]
set talked to 1
endif
end
___________________________________________
scn zzScript06
; This script adds a special visual effect to the creature when this script is attached
begin ScriptEffectStart
PlayMagicShaderVisuals [Enter The effect ID Here]
end
begin ScriptEffectFinish
StopMagicShaderVisuals [Enter The effect ID Here]
end
___________________________________________
ScriptName zzScript08
; This script will automatically close and lock a door
float doorTimer
short closeDoor
Begin GameMode
if closeDoor == 1
if doorTimer > 0
set doorTimer to doorTimer - getSecondsPassed
else
;close the door
Activate
Lock
set closeDoor to 0
endif
endif
End
Begin OnActivate
Activate
if IsActionRef Player == 0
set doorTimer to 5
set closeDoor to 1
endif
End