|
||
|
|||||||
| Subsystems This forum is for modifications to the various subystem code of RunUO |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 (permalink) |
|
Forum Novice
|
When the world is loaded at server startup (the call to World.Load in ScriptsCompiler.cs), the regions are not loaded from the XML file. Region.Load is called in the MainLoop directly after the ScriptCompiler, but at this time the deserialization of the Regions is already finished.
But since there are no regions known by the server before Region.Load is called, FindRegionByUId, which is called while reading saves/regions/regions.idx always returns null, which prevents any further loading. so to fix this problem the order of the actions has to be changed a little bit. Regions.Load should be called after the deserialisation of mobiles, items and guilds, and when the xml file is read regions can be deserialized. but since no region in the standard distro uses region serilization, this bug is not really critical |
|
|
|
|
|
#2 (permalink) |
|
Forum Novice
|
I#m sorry, i overlooked one little thing: before Region.Load is called, the Initialize()-Methods of all the Scripts ar called, and there (in all the Subtypes of Region) are some Region-registration calls.
Just wanted to let you know that this was a mistake of me, not a RunUO-bug - even though it seems that no one cared anyway ![]() |
|
|
|
|
|
#5 (permalink) |
|
Join Date: Jan 2003
Posts: 134
|
Anyway the region system has been completely rewritten for the next version.
The region serialization is no longer supported while the regions.xml capabilities have been greatly improved. The order in which regions are loaded has been changed too ![]() |
|
|
|
|
|
#6 (permalink) |
|
Join Date: Oct 2002
Age: 23
Posts: 4,689
|
Thats not to say that you couldn't still have a single item in the world which has a custom region on it, and serialize its properties with it on world save, and then on world load, create the region back again, and deserialize its properties, and then just add it back with all the rest. I would assume that would work with the new system
Or you could go the XML route as well. |
|
|
|
|
|
#7 (permalink) | |
|
Account Terminated
|
Quote:
|
|
|
|
|
|
|
#8 (permalink) | |
|
Join Date: Jan 2003
Posts: 134
|
Quote:
|
|
|
|
|
|
|
#9 (permalink) | |
|
Forum Expert
|
Quote:
|
|
|
|
|
|
|
#10 (permalink) | |
|
Account Terminated
|
Quote:
![]() |
|
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|