The silence effect I think there might be something for, as I think there is a silence illusion spell.
Here's what I've got so far with the swarm spell:
Scriptname DnDSwarmCurseScript extends activemagiceffect import Critterimport Utilityint property iMaxCritterCount autoint property iCurrentCritterCount autoFormList Property CritterTypes autoActivator Property DnDSwarmBug autoint property fMaxPLayerDistance autoevent OnEffectStart(Actor akTarget, Actor akCaster); How many do we need to spawn?int icrittersToSpawn = iMaxCritterCount; Create that many crittersint i = 0;while (i < icrittersToSpawn); Create one critter at a time;SpawnCritteratRef(akCaster as ObjectReference)ObjectReference critterRef = akCaster.PlaceAtMe(Game.GetForm(0x020048AD), 1, false, false); Wait a bit before the next spawn;Wait(fFastSpawnInterval); Nexti = i + 1endWhileDebug.MessageBox("generation complete")endEvent; Spawns one Critter at a specific locationFunction SpawnCritterAtRef(ObjectReference arSpawnRef); Pick a random critter typeActivator critterType = CritterTypes.GetAt(RandomInt(0, CritterTypes.GetSize() - 1)) as Activator; Create the critter and cast it to the critter base classObjectReference critterRef = arSpawnRef.PlaceAtMe(critterType, 1, true, false);Critter thecritter = critterRef as Critter; Set initial variables on the critter; ; Debug.TraceConditional("Spawner " + self + " is creating Critter " + thecritter, bPrintDebug);endFunctionIts some manipulated gamesas code. Unfortunately, I it doesn't seem to actually do anything in game. I've no idea why...
Maybe one of you can spot my error?
