Full Version : Spawning Multis
xmlspawner >>Q&A >>Spawning Multis
<< Prev | Next >>
gizmo- 05-30-2006
Just curious. I noticed you have the static,xxx command for the xmlspanwer. Is there a way to spawn a Multi? ive tried multi,xxx multis,xxx I dont see any documentation on help option or in any txt file. Any info would be great. thanks.
godfood- 05-31-2006
As of the release of Version 3.07, you can spawn multi files.

QUOTE
- added the new MULTIADDON keyword that allows you to directly import multi-component structure definitions from text files into an addon that can be spawned just like any other object. (thanks to godfood for the idea) The syntax is MULTIADDON,filename
You can use it like any other spawnable keyword (e.g. ARMOR, LOOT, etc.) except you cant spawn it inside of containers or on mobs.
You can generate these multi files by hand, they can be exported from Orbsydia's UO Architect, or they can be created using the new [WriteMulti command.
The files will be automatically found if they are placed either in the main RunUO installation directory, or in the Spawns folder in the main RunUO installation directory. Otherwise you must include the pathname.
Multi files are text files made up of a series of individual component entries.
Each entry must be on its own separate line with the following format:
itemid x y z visible [hue]
where 'x,y, and z' are the relative coordinate offsets of the component, 'visible' is 1 for visible components and 0 for invisible, and 'hue' values can be optionally specified for individual components.
To test it, just add a spawn entry like
MULTIADDON,execution.txt
where execution.txt is an existing multi file
The image below shows the results of spawning the multis contained in the files wall.txt and execution.txt. Both of those files can be found in the xmlextras package.
- added the new WriteMulti command that will allow you to create multi text files that can be imported in UO Architect or spawned with the MULTIADDON keyword.
WriteMulti <MultiFile> [zmin zmax][-noitems][-nostatics][-nomultis][-noaddons][-invisible]
The optional arguments are available to restrict the extraction to certain types of objects.
The -noitems flag will ignore all items
The -nostatics flag will ignore all static (frozen) tiles.
The -noaddons flag will ignore all addons and their components
The -nomultis flag will ignore all multis and their components
The -invisible flag will include invisible items (by default they are ignored)
You will be asked to target an area, and all items and statics within that area will be exported to the multi text file.
You can easily grab things like existing buildings, sections of existing buildings, addons, multis (like camps), or just bunches of objects that you would like to turn into an addon.
By specifying the min and max z, you can limit the exported items/statics to those within that z range.
The 'handle' (the 0,0,0 point) for the addon will be the location of the character when the area selection is completed.
The multi files will be written out into the Spawns folder by default.
If you try to overwrite a non-multi.txt file or a multi.txt file that you did not write, you will be blocked.
This is accomplished by looking for the first header line of the form
1 version staffname
where 'staffname' is the name of the character that wrote the file. You can overwrite files that you have written, but you cannot overwrite others.
If the staffname is missing, then no one can overwrite it.
The image below is the healer in britain that was extracted using WriteMulti with the roof cut off and spawned using the MULTIADDON keyword. It is included as healer.txt in xmlextras

ArteGordon- 05-31-2006

QUOTE (gizmo @ May 30, 2006 11:30 pm)
Just curious. I noticed you have the static,xxx command for the xmlspanwer. Is there a way to spawn a Multi? ive tried multi,xxx multis,xxx I dont see any documentation on help option or in any txt file. Any info would be great. thanks.

static,xxx is just the standard format for spawning an object by passing arguments to its constructor. 'Static' is a constructable item type that accepts an itemid as an arg. Because of that, you could do this on the command line as well
[add static xxx
For multis, there is no equivalent constructable type. You can either spawn a scripted multi such as a smallboat or ratcamp, or you can create your own multicomponent addon and spawn it as godfood described.
It is also possible to spawn a static using the multi artwork (just refer to the multi itemid which is going to be up past 16383).
To get the corresponding itemid, look in insideuo at the multis section, get the multi number in the details for the art you are interested in, and add 16384 to it.
But note, this is not the same as spawning an actual multi, it is just the partial artwork and will behave strangely if you try to interact with it.
gizmo- 05-31-2006
Freakin Awsome, what more can i say. UBER!! thanks man
Lara- 06-27-2006
Im in agreement, having now just had this pointed out to me and played with it, it is really stellar. I have a ton of ideas perculating ... doesnt satisfy my original goal, but wow, very nifty!