RunUO Community

This is a sample guest message. Register a free account today to become a member! Once signed in, you'll be able to participate on this site by adding your own topics and posts, as well as connect with other members through your own private inbox!

[RunUO 2.0 RC1] Lokai's XML Bible System

Lokai

Knight
nadious;700501 said:
Hehehe... It is kind of neat, though. I placed a wandering preacher right by the Brit bank, with a music stand which is holding the Bible on it. (You know.. preachers have to go out and street preach sometimes. :D ) My players this is is just hilarious that when bad karma players go by, that the preacher starts to quote scriptures. They go by often just to see him do it. :D

But still... it is kind of neat to see players asking if they can get a Bible. So, I made them free (charge for God's word? LOL) on the vendor stone. I was doing some world clean up and noticed that a few of them have them locked down in their houses. Maybe they are doing a little afternoon reading while they work skills.

I DID have Xantho's Jail script installed (removed in when we upgrade to the SVN). Should have started an 'mandatory Bible program' for people that kept getting sent to jail. HAHAHAHA! Tell them they couldn't come out till they were 'reformed.' :D What would have been even funnier... if there was a way to place rock hammers inside of the Bibles.

ROFL!


There is.

Modify the OnDoubleClick() method of the Bible.

Add something like this:

Code:
if (from.Region == Region.Jail)
     GiveHammer(from);

Then add this somewhere.

Code:
public void GiveHammer(Mobile from)
{
     foreach (Item i in from.Items)
          if (i is RockHammer)
               return;
 
     RockHammer hammer = new RockHammer();
     from.DropItem(hammer);
}
 

Tru

Knight
I think it would be more affective if you also spawned a preacher to do some preaching while said criminal was doing his rocks.
 

nadious

Sorceror
Hahhaha. That's awesome. Definitely one of the most creative scripts out there.

I have my preacher quote 2 Chronicles 7:14 (I think that's right... off the top of my head there...) when my 'bad' players run by:

If my people, who are call by my name, shall humble themselves, and pray, and seek my face, and turn from their wicked ways; then will I hear from heaven, and will forgive their sin, and will heal their land.

:D They are always like... 'What did that guy just say?'
 

Hotshot

Sorceror
This is Awesome !!!! The Lords Works thru others and I Believe he is doing it thru you. Very Awesome Script !
God Bless bro and Thank You.
 

dwayne2700

Wanderer
After installing the Bible script my server slows down and I get these two warnings. Am I doing something wrong?

Code:
Warnings:
 + Customs/Scripts/Custom/Bible System/BibleReader.cs:
    CS0618: Line 202: 'System.Collections.CaseInsensitiveHashCodeProvider' is ob
solete: 'Please use StringComparer instead.'
    CS0618: Line 202: 'System.Collections.Hashtable.Hashtable(System.Collections
.IHashCodeProvider, System.Collections.IComparer)' is obsolete: 'Please use Hash
table(IEqualityComparer) instead.'

Thanks
Dwayne
 
We have recently started a Saturday Night Prayer meeting on our shard and I got to talking with our my shard owner and he is very excited about the new avenue the shard offers. As we got further into the descusion he brought up maybe also holding a bible study as well and I thought I remembered something like this being here.....and here it is. I ICQed him the link and will run this on my test server.

Regardless if this script isnt used by our main group, the fact that it is available for someone who may later join the group who has no other access to a bible is a powerful tool in itself. Thank you for taking the time to care enough to do something like this.

Itll be awhile until I actually start my server up, so is this a KJV bible? Im assuming since it has a concordanance, it is a KJV. Hoping that it is.

Ill try to rotate accounts here and refresh this thread when needed to keep this thread fresh and on the first or second page.

Thanks again.
 
wondering how hard would it be to change it from the "Bible" to be used for other belief system type bibles? For instance we are using a D&D style shard, with 26 gods. would it be possible to change this to fit each god? What files would we edit to get that done. We wanna make our shard a straight RP shard and this would go a LOOONG way for that!
 

Lokai

Knight
drgsldr69;749171 said:
wondering how hard would it be to change it from the "Bible" to be used for other belief system type bibles? For instance we are using a D&D style shard, with 26 gods. would it be possible to change this to fit each god? What files would we edit to get that done. We wanna make our shard a straight RP shard and this would go a LOOONG way for that!

You can change the name, and change the look and feel, if you want, but the index, concordance, topic reader, and quote system are all hard coded to refer to exact passages in the XML bible provided.

If you were a hard-core writer, you could fiddle with the text, leaving passage references in place, but I would fear for your soul... just kidding. But seriously, you could always use the coding examples in the script to extract passages from your favorite texts.

I started writing an XML Book script, but didn't get far with it. You can see from an earlier version of this that it was capable of reading other books, as I provided one in my downloads (a dry French political commentary):

http://www.runuo.com/forums/custom-script-release-archive/54490-xml-bible.html

Have fun!
 

Braun

Wanderer
I seem to be having an issue downloading this file. When i try to open it in winrar or winzip, I get an error. It says it is a corrupt file.
 

Lokai

Knight
Braun;752205 said:
I seem to be having an issue downloading this file. When i try to open it in winrar or winzip, I get an error. It says it is a corrupt file.

Many people are having this problem on the forums. You can keep trying, or download a safe download manager. The attachment is not corrupt, it seems to be an issue on the forums in general.
 

Braun

Wanderer
This is a great script...
Here is what I found...

Using my Admin account, with another staff memeber using thier admin account... I noticed that everytime they changed books , it would change mine to whatever they were looking at. We both had the gump open at the same time and every time one of us would go to another book, it would change both of our gumps to that book.

example: I would be looking at the book of John and she would switch over to the book of revelations and it would change my gump over to revelations as well.

This is not a big deal, just thought I would let you know.

Thanks for the awesome script.
 

Braun

Wanderer
ok we tested this some more and it seems this only happens with staff members, in other words, a staff member can change the book and it will change whoever has it open, but a player can change books and it will not affect anyone elses but thier own. This is cool.
 
i have tried a download manager and it still aint working. i have tried winrar, winzip and even 7zip to open it and they all tell me same story corrupt file.
 

Lokai

Knight
drgsldr69;754274 said:
i have tried a download manager and it still aint working. i have tried winrar, winzip and even 7zip to open it and they all tell me same story corrupt file.

Have you tried this?

1. Unzip the file "XML Bible System.zip" (izarc can handle it, even though it thinks the file is corrupt.)
2. Delete the file "XML Bible System.zip"
3. Rename the file you just unzipped from "XML Bible System" to "XML Bible System.zip" (by adding .zip to the end.)
4. Unzip "XML Bible System.zip".

This will work for 99% of the files on the forums, and it works for this one too, (I just tested it.)
 

Miller.

Wanderer
I tried adding the Bible to the NPC Provisioner's SB Info much like I have added other things (runics, socket hammer, hammer of recovery) but I get a compile error.

Code:
[COLOR="DarkRed"]Errors:
 + Mobiles/Vendors/SBInfo/SBProvisioner.cs:
    CS0246: Line 73: The type or namespace name 'Bible' could not be 
found (are you missing a using directive or an assembly reference?)[/COLOR]

This is the line I added:

Add( new GenericBuyInfo( typeof( Bible ), 1, 20, 0x2252, 0x297 ) );
 

Lokai

Knight
The Bible is in the Server.Custom namespace, so you need to add the following line to top of your script:

Code:
using Server.Custom;
 
Top