View Single Post
Old 01-29-2008, 11:28 PM   #1 (permalink)
shivan
Forum Novice
 
Join Date: Jul 2003
Posts: 105
Default Castle Assault converted to RunUO 2.0

This is the Castle Assault scritp created by x-ray, is not really a conversion, i removed the region generator to make it work in 2.0, i try to fix the region, but i dnt have the enoght C# knowlodge. but anyway this is best than nothing

If someone wish to do it are welcome.

Anyway, the original post can be found here: Castle Assault

Quote:
Usage:
Unzip to custom folder.

In game:

Find flat location and put a castle somewhere:

[add EvilCastleSpawn

This will produce castle and some decoration on it. If you stick in the wall or floor use [tele to move to another location. In the middle of the castle you can see the sign - click it twice and the properties will shown. Here you can edit/look the properties:

active - this will activate entire system. Every internal tick the castle check the number of monsters in every defender group and respawn one monster in every incomplete group of defenders.

The one internal tick time is calculated by following formula -

time = rate + rate * (kills/rateValue)

Check the description of rate, kills and rateValue below.
For example if you kill 10 monsters, rateValue = 67 and rate = fast the castle will 'tick' every

time = 50 + 50*(10/67) =~ 57 second.

autorepair - If this is 'true' very internal tick time the castle will repair every breaked door with 1 unit.

complete / CompletionTime - show is the boss is killed and when this happends.

kills - number of killed monster-defenders. Decreased by one every internal tick.

maxArchersInGroup - number of archers in group

maxMagesInGroup - number of mages in group

maxWarriorsInGroup - number of warriors in group

rate - respawn rate

Slow means about 190 seconds
Normal means about 120 seconds
Fast means about 50 seconds

rateValue - total rate divider. See the formula of internal ticks above.
restartHours - restart captured spawner after this number of hours

Waypoint1,Waypoint2,Waypoint3 - add waypoints ([add Waypoint) and link with this props. If any of this waypoint not null the castle will spawn patrol groups (if kills at tick time equals 0, means castle not under attack)
The region is not really needed, the region the only thing that do is prevent players from using mark/gate/recall inside the castle. You can use the "Custom regions in a Box" scritp to do the same.

All credits go to the original creator. oh, i also modified the scritp to allow player to loot the NPC corpses, it can be easily modified in castleattackspawn.cs
around line 1124 you will found this:
Code:
				if ( c != null && !(c.Owner is PlayerMobile) && !(c.Owner is ECOrcishLeader) )
				{
				//	c.Delete();
				}
just remove those // and all monsters corpses(except boss monster) will deleted imideatly.
Attached Files
File Type: zip castleassault.zip (19.9 KB, 129 views)
shivan is offline   Reply With Quote