Staff Assistant reborn

This is where you can post about tools related specifically to the POL Server itself

Moderator: POL Developer

Post Reply
Yukiko
Distro Developer
Posts: 2825
Joined: Thu Feb 02, 2006 1:41 pm
Location: San Antonio, Texas
Contact:

Staff Assistant reborn

Post by Yukiko »

[01-24-2016 Updated]

Okay, maybe the topic name is a tad hyperbolic but I wanted to get your attention. :)

This is an update of the original Nightscape Staff Assistant tool originally posted on these forums by Danielle. She was kind enough to post the source code as well. I haven't made too many changes to the tool itself (see below for a list of many of the changes). What I have done though is create a package which contains the companion eScript programs (POL commands) needed to work with the Assistant. Many of the commands already exist as "standard" commands such as .info or .kill. Some did not exist and so I wrote them. Some still don't exist because either I don't know the original way they were supposed to work. Others require more time to write than I have right now.


Before using the Assistant you need to do a few things. First you might need to add the location of your Ultima Online installation info to the Windows registry. This depends on whether the setup program for your version of Ultima added this info to the Windows registry. If the Staff Assistant kicks out an exception error when you try to view NPCs in the NPCs preview area of the Assistant then you will need to add the info to your registry. To do this you must copy the following to a text file. Enter the path to your UO install folder where it is appropriate. Save it as UOInfo.reg double-click it to import it into the registry. This must be done in order for the item and NPC previews to work. If you fail to set this then you cannot use the Staff Assistant to create items. It will throw an exception error.

Code: Select all

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\Origin Worlds Online\Ultima Online]

[HKEY_LOCAL_MACHINE\SOFTWARE\Origin Worlds Online\Ultima Online\1.0]
"ExePath"="c:\\Program Files (x86)\\Ultima Online\\UOCH_n0p3_Client00.exe"
"InstCDPath"="c:\\Program Files (x86)\\Ultima Online"
"PatchExePath"="c:\\Program Files (x86)\\Ultima Online\\uopatch.exe"
"StartExePath"="c:\\Program Files (x86)\\Ultima Online\\uo.exe"
"Upgraded"="Yes"
Next open the "Staff_Assistant_programs" ZIP file and copy the folder inside to your hard drive.

Then open the Staff_Assistant folder you just copied to your hard drive and run the Assistant and click on the "settings" tab and at the "UO Client Location:" box browse to your UO installation directory.

You can also check the Advanced Settings to set additional options such as the option to have Staff Assistant automatically launch your UO client when you open the Staff Assistant.

Finally, you need to open the StaffAssistant.zip file and copy the folder inside to your \pkg directory. On my server I have a Tools subdirectory and that's where I put the StaffAssistant folder. Be sure to compile the scripts.


The Staff Assistant injects text commands into the UO client to accomplish tasks in-game. These text commands are heirarchical based on the command level of the user. This means that you can give every member of your staff a copy of the Assistant and it will only let the user execute commands that she or he has permission to use. So a Seer cannot execute a GM level command etc.

This brings up a point I want to mention. The commands contained within the StaffAssistant package are placed in different command level folders. The program has no control over what command level is authorized to use a command. That is handled by the server just as with any <dot> text command. Feel free to rearrange them as you see fit for your shard. For example you might want to give Seers access to some commands that I have in the GM folder. If so just move those commands from the GM folder to the Seer folder.


Included with the Staff Assistant is a list editor for editing the various lists that the Assistant uses. You can select the list you wish to edit. There are four lists that are used by the Assistant: Building Creator List, Items List, NPC List and Travel Locations List. I don't need to offer instructions on how to use the editor. Fortunately for us the creators provided a native help dialog box rather than sending us to a website because the Nightscape website does not exist any longer. Once again this reinforces my argument that help pages should be included in a program rather than being web linkls to external (read here Internet) websites.

I haven't done anything to the original source code for the List Editor.

Here are some of the changes that I made to the Staff Assistant:

I removed most of the Nightscape branding from both programs. However I left the original copyright info in place. Even though Danielle made the source code available I don't know if her intent was to release it to the public domain or as Open Source. There is no license information that I can find. So I don't feel at liberty to remove the copyright. I did however feel that since there is no Nightscape shard or website in existence that removing the branding was permissable. Danielle if you are around and wish to PM me or post a reply to clarify these issues please do. It's not hard to replace the Nightscape branding if my removing it is a violation of the copyright.

The account ban button I changed to "Disable Account". I also created a companion POL command to perform the function. It sets the "disabled" property on the account rather than banning it.

I disabled the "Wipe Account" button because many shards have custom items that are associated with a user's account that would need cleaned-up if an account was wiped; ie. houses owned by that account etc. Because of this I felt it was better to leave that alone. This is also the reason I changed the "Ban Account" button to "Disable Account".

The "Set Skill" and "Set Stat" buttons are disabled because they both throw an exception error when used. I looked at the source code and wasn't able to see why this was happening.

Under the Building Creator tab:
The "Foundation" button is disabled.
I added the roof creator back in after Danielle pointed me to the postings of those commands. I updated the eScript program to be compliant with the current POL Core, ie. realm support. I did not test it to see how they work.

Under the Items Tweak tab:
The "List Rects." button is removed because there is no accompanying eScript command and there is no info as to what it did.
I added "Mass Move", "Copy & Paste", and "Paste Items" back in after Danielle pointed me to the postings of those commands. I updated the eScript programs to be compliant with the current POL Core, ie. realm support. I did not test them to see how they work.

"Create Group" under the NPCs tab is disabled. I think this would work with the World of Dreams shard scripts because I think there's a command for it. However, I am trying to make this as generic as possible I disabled the button. WoD breaks the NPCs into groups which makes this easier to do on WoD based servers.

Under the NPC Tweak tab:
"Barber" button is disabled because there is no accompanying eScript command for it.
"Run To" is disabled for now.
"Set Skill" and "Set Stat" buttons are disable due to exception errors.

On the GM tab the six buttons under the "Prop Edit" button were disabled. So I left them that way. "Add GoLoc" is disabled because that command is already available in the .go gump.

I added the "Open Pack" button. It seemed odd to me that it was missing especially since there is an Open Bank button.

Under the Tools tab I added a button to launch UO Fiddler.
Under the Settings tab I added the UO Fiddler location Browse button and Text box so the program knows where you have UO Fiddler installed.

If you have some favourite staff level text commands you want added in to the program, PM me with your suggestion. I am just beginning to learn Visual Basic. So be patient if you do want something added.

Please feel free to post any general feedback here.

[12-26-2015 - Updated POL scripts: case mismatch issues in Linux.]
[01-19-2016 - Added UO Fiddler to the Tools tab and added Mass Move and the various Copy and Paste commands.]
[01-24-2016 - Fixed a bad "include" reference in the sa_counpage" program.]
Attachments
StaffAssistant_pkg.zip
Server side files required by Staff Assistant.
(83.44 KiB) Downloaded 318 times
Staff_Assistant_programs.zip
The Staff Assistant program and the Staff Assistant List Editor program
(629.67 KiB) Downloaded 334 times
Last edited by Yukiko on Sat Jan 23, 2016 10:12 pm, edited 4 times in total.
boberski
Grandmaster Poster
Posts: 275
Joined: Tue Oct 15, 2013 12:00 pm

Re: Staff Assistant reborn

Post by boberski »

As always great job. :)
boberski
Grandmaster Poster
Posts: 275
Joined: Tue Oct 15, 2013 12:00 pm

Re: Staff Assistant reborn

Post by boberski »

You do not bind all of cmds.. bad Yukiko, bad, bad, bad! :P
Yukiko
Distro Developer
Posts: 2825
Joined: Thu Feb 02, 2006 1:41 pm
Location: San Antonio, Texas
Contact:

Re: Staff Assistant reborn

Post by Yukiko »

You do not bind all of cmds.. bad Yukiko, bad, bad, bad! :P
Hahaha!

I never said I was good. :P

I assume you mean I didn't include all the commands that Staff Assistant uses in the StaffAssistant pkg? There are a couple of reasons for that. I have had this done for maybe a week or so and I wanted to post it as soon as possible. Adding the other more involved commands would have delayed getting it uploaded. Plus, I am pretty sure the ones I didn't recreate in the package are standard for most shards. I think all shards have the .info command for example. If you look at the info.src program (script if you prefer) it uses quite a number of include files because it has to access attributes and NPC functions, etc. On some shards there might be customizations to those commands that wouldn't be available if I provided my own version with the Assistant. Most of the commands I have placed in the package are pretty simple stuff that most likely would have much in the way of customized code. For example the .createnpc command is a basic command. That one does have a bit more functionality on World of Dreams based scripts because if you don't specify an NPC template it opens a gump but with the Assistant you have a visual representation of the NPC so you don't need the extra WoD gump.

I might go ahead and add the rest of the commands at a later date.

Let me know if any of the commands don't work. I'm pretty sure I have all of them in the package but I might have missed one or two.
Danielle
Grandmaster Poster
Posts: 104
Joined: Tue Feb 07, 2006 3:32 pm
Location: Pittsburgh, Pennsylvania

Re: Staff Assistant reborn

Post by Danielle »

Having to add the registry keys is a issue with the ultima.dll included with the program- which I did not write. If the source code for that could be found, updated and recompiled that would fix that issue.

Some of the missing commands I have previously released here.
I don't recall what the "Create/List Rect" commands did sadly. If I recall correctly, the barber script wasn't something I created. Maybe it is even available on the site here. Some of the buttons were bold simply because they were more commonly used and helped to draw attention to them.. least I think that was my thinking. I am unsure why the two "Set .." commands are throwing exceptions. I don't think a "Foundation" command was ever created as it was deemed unnecessary since foundations were pretty easy to make.

As stated in my original post, I released the source under the Open Software License. I was also the only developer for the program.

The wizard for the List Editor was never even started, let alone completed.
Yukiko
Distro Developer
Posts: 2825
Joined: Thu Feb 02, 2006 1:41 pm
Location: San Antonio, Texas
Contact:

Re: Staff Assistant reborn

Post by Yukiko »

Thank you Danielle.

I certainly appreciate the help.
Having to add the registry keys is a issue with the ultima.dll included with the program- which I did not write. If the source code for that could be found, updated and recompiled that would fix that issue.
Yes. I forgot to mention I determined that was a ultima.dll issue. It's not as serious a problem once I discovered the registry patch solution.
I don't recall what the "Create/List Rect" commands did sadly. If I recall correctly, the barber script wasn't something I created. Maybe it is even available on the site here. Some of the buttons were bold simply because they were more commonly used and helped to draw attention to them.. least I think that was my thinking. I am unsure why the two "Set .." commands are throwing exceptions.
I figured a lot of the <dot> commands were probably created by others. Not knowing the make-up of your staff I wasn't sure but as is the case with a lot of shards there's always multiple contributors. As I mentioned in my PM to you I'm not all that concerned about the setskill/setstat buttons as the "info" command allows access to those properties.
The wizard for the List Editor was never even started, let alone completed.
Right. I think there was an empty sub for it but no code. Again, it's not a major issue.

Thanks again for the program.
Post Reply