Creates random element extension (#196)
This commit is contained in:
parent
0926b5abaa
commit
4403d6c1c7
84 changed files with 226 additions and 330 deletions
|
|
@ -153,7 +153,7 @@ namespace Server.Items
|
|||
{
|
||||
Map map = Map;
|
||||
BaseCreature bc =
|
||||
(BaseCreature)ActivatorUtil.CreateInstance(Creatures[Utility.Random(Creatures.Length)]);
|
||||
(BaseCreature)ActivatorUtil.CreateInstance(Creatures.RandomElement());
|
||||
|
||||
Point3D spawnLoc = GetSpawnPosition();
|
||||
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@ namespace Server.Items
|
|||
{
|
||||
if (m_TurnedOn && IsLockedDown && (!m.Hidden || m.AccessLevel == AccessLevel.Player) &&
|
||||
Utility.InRange(m.Location, Location, 2) && !Utility.InRange(oldLocation, Location, 2))
|
||||
Effects.PlaySound(Location, Map, Sounds[Utility.Random(Sounds.Length)]);
|
||||
Effects.PlaySound(Location, Map, Sounds.RandomElement());
|
||||
|
||||
base.OnMovement(m, oldLocation);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue