Go Back   RunUO - Ultima Online Emulation > RunUO > Custom Script Release Archive

Custom Script Release Archive This is a pre-script database archive of what our users had released.

 
 
Thread Tools Display Modes
Old 05-29-2005, 11:46 PM   #1 (permalink)
Xanthos
Guest
 
Posts: n/a
Lightbulb Speech Cop Jailing System version 1.8

This is a basic jailing and speech monitor system.

Commands : [jail [unjail [AddJailWords [DeleteJailWords[ListJailWords

If a player says any of the words in the file jaiwords.cs, they will be automatically jailed on the spot. If you want the system to monitor chat speech as well there is a method, in jailcommand.cs, that must be called from the chat command handler. An example and explanation for how to do this with Knives Chat 2.0 is provided in jailcommand.cs. If you want to prevent players from leaving jail using the stuck option you will also need to set up a custom region encompassing your jail; Regions In a Box works well for that.

Installation:
  1. Unzip the package
  2. Drop in your custom folder
  3. Copy or move the jailwords.txt file to your Data folder.
  4. Restart your server.
  5. Add a JailTeleporter (ideally this is at a location accessible to inmates in your jail, however it need not be visible or accessible to them for the system to work properly).
  6. Modify the props on the teleporter to change the locations of the jail and release spots, etc. (most installations will not need to change the source files since the most common configurations can be accessed via the properties on the teleporter).
Changes in 1.8
  • Added the Murder Free Location to the in game configuration. Use props on the jail teleporter to configure it.
  • Cursing in jail now gets the player kicked, in addition to fined and an increased sentence.
  • There is now an option to the jail command to squelch the player when jailed.
Changes in 1.7 1/14/06
Thanks go to Novafire, whose ideas make up the bulk of this release.
  • Extracts a fine from jailed players.
  • Provides two free locations based on noteriety - one for murderers with 5 or more counts and one for the rest.
  • Swearing in jail no longer teleports the player to jail since they are already there.
  • Players are now jailed in a burst of flame and lighting which leaves behind nothing but their smoldering boots.
  • The package now unzips into a Xanthos directory - keeping the package files within the Xanthos directory in your customs directory is recommended.
Changes in 1.5 8/7/05
  • Fixed an interaction with the safe rez context whereby an immovable death shroud would be left in a dead jailed player's pack.
  • All jail configuration is now done in game - no more need to edit scripts or restart the server.
  • New commands: AddJailWords, DeleteJailWords and ListJailWords allow in game changes and review of the jailable words.
  • The speech filter can be enabled/diabled by editing the properties on the JailTeleporter allowing an admin to turn on and off autojailing on speech.
Changes in 1.4 6/10/05
Special thanks to Thundar for his help and ideas on this release.
  • Jail Rock is now deleted when players are released or jailed
  • Players are now teleported to the free location immediately upon release
  • Free players in the Jail Guard's line of sight who step too close are jailed
  • Access levels of jailed players are now persisted when the server shuts down - therefore players with access level counselor and above, jailed after this release, will have their proper access level restored when set free
  • Some of the messages have changed
  • The jail teleporter is now visible when created
  • Jail rock can no longer be created in-game using [add, unless JailRock.cs is compiled with JAIL_TESTING defined.
Changes in 1.3 6/7/05
  • Free and jail teleport locations, hammer difficulty and type of tiles to mine are now settable in game using the [props on the jail teleporter.
  • The teleporter will now remove any jail rock from the player's pack as they exit jail.
  • Fixed the guard spamming.
  • Fixed another crash in the unjail command related to the hashtable.
Changes in 1.2 6/5/05
  • Moved the name of the tiles to mine and the name of the rock mined there with the rest of the configuration variables.
  • Added a comment that describes how to find the name of the tiles to be mined.
  • Fixed the guard logic so he speaks again.
Changes in 1.1 6/2/05
  • All pets are now stabled when a player is jailed
  • Player access level is stored and set to Player, then back to its original value on release
  • Fixed a bug where the hammer could be unequipped on certain conditions. This change required that the Hammer inherit from BaseWeapon. Unfortunately this will cause a one time deletion of all existing hammers, and susbsequent release of all prisoners - guard your women and children!
  • Fixed a crashing bug when a player is set free using the [UnJail command
  • Moved all configurable options into the Jail class
  • Changed the hue of the teleporter to be more noticable
Attached Files
File Type: zip Jail 1.8.zip (12.2 KB, 475 views)
File Type: zip Utilities 1.2.zip (6.8 KB, 303 views)

Last edited by Xanthos; 03-19-2006 at 06:09 PM.
 
Old 05-30-2005, 12:32 PM   #2 (permalink)
Forum Expert
 
Join Date: Nov 2003
Posts: 561
Default

Sounds interesting. What bugs did you find in the previous submissions? I took SS and GR's code and modified it to fit my jail requirements and, so far, have experienced no difficulties.
ssalter is offline  
Old 05-30-2005, 12:52 PM   #3 (permalink)
Xanthos
Guest
 
Posts: n/a
Default

Well the most obvious problem was that they were rebuilding the bad word array everytime someone spoke. A lot of inconsistencies in the code like variable naming, unused variables, and so on that made it hard to follow. An error that allows players to end up with large negative amounts of rock to mine. I stopped keeping track at that point and went for a complete rewrite.
 
Old 06-01-2005, 10:02 AM   #4 (permalink)
Forum Expert
 
Iomega0318's Avatar
 
Join Date: Feb 2005
Location: Dirt City,TX
Age: 21
Posts: 608
Send a message via ICQ to Iomega0318 Send a message via AIM to Iomega0318 Send a message via MSN to Iomega0318 Send a message via Yahoo to Iomega0318
Default

lol.. ok I ve had theres for a bit but havent used it.. Ill use yours but I need help with something.. I made a custom mining camp/jail place and the whole floor is cave floor.. I dont know how to change it to make it work.. Ive tried all kinds of changes.. can you help me with it pls..
Iomega0318 is offline  
Old 06-01-2005, 08:20 PM   #5 (permalink)
Forum Expert
 
Join Date: May 2004
Age: 29
Posts: 358
Default

This is a great update for this. The only issues I've seen with this so far are,

Players with pets other then the mount hey had will probably end up loosing them. dono if thats by design or not.

Counslors can be jailed by cursing, but can use [tele [go or [who to get out.

and I experenced a crash. I belive, that it happned when I used the [unjail command, and either missed the guy, or hit esc to cancel.


Exception:
System.InvalidOperationException: Collection was modified; enumeration operation may not execute.
at System.Collections.ArrayListEnumeratorSimple.MoveN ext()
at Xanthos.SpeechCop.UnJailTarget.OnTarget(Mobile from, Object targ)
at Server.Targeting.Target.Invoke(Mobile from, Object targeted)
at Server.Network.PacketHandlers.TargetResponse(NetSt ate state, PacketReader pvSrc)
at Server.Network.MessagePump.HandleReceive(NetState ns)
at Server.Network.MessagePump.Slice()
at Server.Core.Main(String[] args)

I Did fix the counslor escape plan on my shard, but I also have staff orbs. I just added a change acess level to the jailing part, and since all possessions go in the bank that includes their orbs and they cant break out. I even went a step farther and included GMs in being able to be jailed, because I dont want any staff slip of the toungs...
MetallicSomber is offline  
Old 06-01-2005, 08:54 PM   #6 (permalink)
Forum Expert
 
Join Date: May 2004
Age: 29
Posts: 358
Default

dunka
MetallicSomber is offline  
Old 06-01-2005, 11:57 PM   #7 (permalink)
Forum Expert
 
Iomega0318's Avatar
 
Join Date: Feb 2005
Location: Dirt City,TX
Age: 21
Posts: 608
Send a message via ICQ to Iomega0318 Send a message via AIM to Iomega0318 Send a message via MSN to Iomega0318 Send a message via Yahoo to Iomega0318
Default

Quote:
Originally Posted by Xanthos
If you look in the original thread by Grim Reaper there are suggestions on how to get the hammer to mine in a cave. You will also need to change the teleport locations for your jail location and where you would like them released to when they step on the "door to freedom".
yes i know but it didnt help me any and I try'd everything they told me to change.. still wouldnt work..
Iomega0318 is offline  
Old 06-02-2005, 08:54 PM   #8 (permalink)
Xanthos
Guest
 
Posts: n/a
Default

Updated to version 1.1 - see the first post for the zip file and notes on the changes.
 
Old 06-03-2005, 08:29 PM   #9 (permalink)
Forum Expert
 
Iomega0318's Avatar
 
Join Date: Feb 2005
Location: Dirt City,TX
Age: 21
Posts: 608
Send a message via ICQ to Iomega0318 Send a message via AIM to Iomega0318 Send a message via MSN to Iomega0318 Send a message via Yahoo to Iomega0318
Default

Quote:
Originally Posted by Xanthos
What about the pickaxe or shovel code? If they can mine in a cave (im not sure if they can or not) then you could use that as your model.
hmm that may work... Ill go try that then get back with yall..
Iomega0318 is offline  
Old 06-03-2005, 09:25 PM   #10 (permalink)
 
Join Date: Nov 2003
Location: Noblesville, Indiana
Age: 34
Posts: 56
Send a message via ICQ to Saint666
Default how would i

how would i transform the script or edit it to make it so if you cuse in the house you own it will not put you in jail?
Saint666 is offline  
Old 06-05-2005, 11:31 AM   #11 (permalink)
 
Join Date: Aug 2004
Location: 127.0.0.1
Age: 35
Posts: 234
Send a message via ICQ to Thundar
Default

i changed the location to go to the internal jail in tram and i added cave floor tiles. i tested to see if i can mine normally from those tiles and i can but i am not sure what line to change in yer script to get it to mine from that instead of just mountain walls could u enlighten me if it is jsut that one line here in JailHammer.cs?

if ( toLand.Name == "rock" )

thx i love the script btw Also i checked the link from the archive i changed "rock" to "cave floor" and i still get no rock, any ideas?
Thundar is offline  
Old 06-05-2005, 09:51 PM   #12 (permalink)
Xanthos
Guest
 
Posts: n/a
Default

Get the latest release. I added some config variables and instruction in the comment next to the variable to help make mining different locations easier for everyone. Basically you use the command
Code:
[get name
and target a tile to get the name to set the variable to. Worked well for me - let me know if it gives you any grief
 
Old 06-05-2005, 10:08 PM   #13 (permalink)
Xanthos
Guest
 
Posts: n/a
Default

Quote:
Originally Posted by Saint666
how would i transform the script or edit it to make it so if you cuse in the house you own it will not put you in jail?
Look in HouseRegion.cs for how to determine if they are in their house. You would then use that to determine whether or not to call JailThem().
 
Old 06-06-2005, 02:29 AM   #14 (permalink)
 
Join Date: Aug 2004
Location: 127.0.0.1
Age: 35
Posts: 234
Send a message via ICQ to Thundar
Default

sweet thx Xanthos that worked just fine only one prob it still crashes as soon as i use the [unjail cmd on an inmate i have yer newest download too


*EDIT* Also i noticed that the player can leave the jail once done and keep all the Jail Rock he had extra i would think that the Jail Rock should be deleted upon steping on the door to freedom or at the time of turning in the last Jail Rock like the hammer disappears....once again this is a great script i love it u did a great job and this is only an idea for u keep up the good work
Thundar is offline  
Old 06-06-2005, 04:06 AM   #15 (permalink)
Xanthos
Guest
 
Posts: n/a
Default

I cannot repro the crash, can you send me the log?

Good suggestion on the jail rock removal - consider it done.
 
Old 06-06-2005, 04:21 AM   #16 (permalink)
 
Join Date: Aug 2004
Location: 127.0.0.1
Age: 35
Posts: 234
Send a message via ICQ to Thundar
Default

here is the crash report:

Quote:
xception:
System.NullReferenceException: Object reference not set to an instance of an object.
at Xanthos.SpeechCop.UnJailTarget.OnTarget(Mobile from, Object targ)
at Server.Targeting.Target.Invoke(Mobile from, Object targeted)
at Server.Network.PacketHandlers.TargetResponse(NetSt ate state, PacketReader pvSrc)
at Server.Network.MessagePump.HandleReceive(NetState ns)
at Server.Network.MessagePump.Slice()
at Server.Core.Main(String[] args)
np yw for the suggestion u have great support also
Thundar is offline  
Old 06-06-2005, 04:32 AM   #17 (permalink)
 
Join Date: Jan 2005
Age: 24
Posts: 174
Send a message via MSN to aleon
Default

Well im working on jail system that doesnt jail people but actualy gives a squeach jail and puts a book in the backpack to let the player read the book 1500 times during that time he could not speak just like squealched during that time until the book is finished when the reading is finished his squealch would go of its more practicular.Like for other things im looking at uo samurai empire easyuo doesnt work on samurai empire which is very useful for this im trying to change the core to enforce the players to use samurai empire but not beta because beta supports easyuo still working on it.

Also 1 more thing i just had a question i saw on the third party forum iris client just like World Of Warcraft but its based on uo changed uo motor much more better 3d motor does the runuo dev team working on the motors ?
aleon is offline  
Old 06-06-2005, 04:37 AM   #18 (permalink)
 
Join Date: Aug 2004
Location: 127.0.0.1
Age: 35
Posts: 234
Send a message via ICQ to Thundar
Wink

not sure if that book thing is gonna be effective because u can use razor to loop reading the book i beleive so basically they could read that book in a matter of seconds while taking a smoke break.. i could be wrong tho....just giving u feedback on that is all
Thundar is offline  
Old 06-06-2005, 11:30 PM   #19 (permalink)
 
Join Date: Nov 2003
Location: Noblesville, Indiana
Age: 34
Posts: 56
Send a message via ICQ to Saint666
Default

would is be this section?



public override void OnSpeech( SpeechEventArgs e )
{
Mobile from = e.Mobile;

if ( !from.Alive || !m_House.IsInside( from ) || !m_House.IsActive )
return;

bool isOwner = m_House.IsOwner( from );
bool isCoOwner = isOwner || m_House.IsCoOwner( from );
bool isFriend = isCoOwner || m_House.IsFriend( from );
Saint666 is offline  
Old 06-07-2005, 12:52 AM   #20 (permalink)
Xanthos
Guest
 
Posts: n/a
Default

Yes.
 
Old 06-07-2005, 01:05 AM   #21 (permalink)
 
Join Date: Aug 2004
Location: 127.0.0.1
Age: 35
Posts: 234
Send a message via ICQ to Thundar
Default

was that crash report sufficeint to figure out what the [unjail cmd crash was bieng caused by?...And also the jailer is speaking again (kewlness) but he skips back when u try to approach him is that normal workings to make him keep speaking or just a glitch? goo work by the way and i added rep points to u on last post of mine u answered for good work and response time
Thundar is offline  
Old 06-07-2005, 03:27 AM   #22 (permalink)
Xanthos
Guest
 
Posts: n/a
Default

I found the source of the crash. It had to do with the hashtable lookup - I have implemented a reliable means to be sure there is an entry for the key before I use the value. Im still trying to get the jailer to behave with no timer - although I consider the priority of this lower than some of my other tasks.
 
Old 06-07-2005, 03:40 AM   #23 (permalink)
 
Join Date: Aug 2004
Location: 127.0.0.1
Age: 35
Posts: 234
Send a message via ICQ to Thundar
Default

kewl if u have anything u want to try out just let me know and i can test it on my shard and get u some feedback and stuff
Thundar is offline  
Old 06-07-2005, 08:40 PM   #24 (permalink)
Xanthos
Guest
 
Posts: n/a
Default

I fixed the crash and a few other bugs. Go to the top to see the changes in 1.3.
 
Old 06-08-2005, 04:33 PM   #25 (permalink)
 
Join Date: Aug 2004
Location: 127.0.0.1
Age: 35
Posts: 234
Send a message via ICQ to Thundar
Default

ok i tried it out works alot better and no crashes. I found away to leave with the Jail Rock still (it is not a big deal just letting u know is all ) if u get jailed then mine say 200 rock, give 100 to the slave driver and put the rest in yer pack in separate pile, (Do Not step on teleporter yet) then say another cuss word and all yer items get sent to yer bank even the jail rock in yer bag. The thing will be that the guy will go and do this then get out of Jail and sell the Jail Rock for millions cause others cant figure out how to do it lol. ( like i said tho it is no biggie just thought u might want to know all the possibilities
Thundar is offline  
 

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off



Powered by vBulletin® Version 3.7.0
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0 RC5