|
||
|
|||||||
| Custom Script Releases This forum is where you can release your custom scripts for other users to use. Please note: By releasing your scripts here you are submitting them to the public and as such agree to make them public domain. The RunUO Team has made its software GPL for you to use and enjoy you should do the same for anything based off of RunUO. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 (permalink) | |
|
Forum Expert
|
Key Words:// ObjectPropertyList, OPL, Wrapper, Packets, Localizer, Extended
Supported Versions: * RunUO 1.0 Final * RunUO 2.0 RC1 * RunUO 2.0 RC2 (?) Here we go, another instance of "Impossible...? pfft". How many people have claimed that something is "impossible" with RunUO? Well, here is a development of a good friend, Dominik Seifert, aka, Squishy. When I posted in the Script Support section asking for help with converting ObjectPropertyLists to a string format, that could easily be used in Gumps, I recieved negative karma from an un-named source, because I was positive that it was completely possible to do this, and would not accept that it was impossible... I was talking to Dominik and I mentioned the subject, since that talk, he strived to prove the fact that nothing was impossible. Even though it took a lot of trial and error, as everything does, we have the final product... So, without further adue, I give you; Squishy's Extended Localizer - Package: Quote:
__________________
![]() WWW.RPK-UO.COM - The WoW-UO Cross-Over Shard Last edited by Admin Vorspire; 12-06-2006 at 09:59 PM. Reason: Update |
|
|
|
|
|
|
#2 (permalink) | ||||||||
|
Forum Expert
|
F.A.Q.
Quote:
-------------*****------------- Quote:
-------------*****------------- Quote:
Quote:
Quote:
Quote:
Quote:
Quote:
1) See Above ![]() 2) The messages contained within the Cliloc files in your Ultima Online directory/folder. For english it gets the right clilocs dependant on your language. English is "Cliloc.enu". 3) Yes, it will get whatever custom Object Property Lists you have already set, since it gets the Packet information, then uses the right cliloc number (Example: list.Add( 3000103, arg ) in any Item/Mobile's "GetProperties()" or "AddNameList()" overrided method. - This make this package totally dynamic, and you shouldn't ever have to edit the source code ![]() ------------------------------ Examples of usage...(soon)
__________________
![]() WWW.RPK-UO.COM - The WoW-UO Cross-Over Shard Last edited by Admin Vorspire; 12-06-2006 at 10:25 AM. Reason: Update |
||||||||
|
|
|
|
|
#6 (permalink) |
|
Forum Master
Join Date: Feb 2005
Location: ShatteredSosaria.com
Posts: 9,260
|
He just changed the attachments, try again.
P.S. @Vorspire: you may want to change those to .zip archives; some people don't have WinRAR (stupid school computers don't; I wanted to look at the code while I was here ) |
|
|
|
|
|
#12 (permalink) | |
|
Forum Expert
|
erm... what is Ultima???
Code:
using Ultima; Quote:
__________________
;)My C# Bookshelf (carpented by Soultaker);) BTW: Please ask questions in the adequat forum and not on a private message! Otherwise nobody can learn from it!
|
|
|
|
|
|
|
#13 (permalink) |
|
Forum Expert
|
Code:
/// <summary> /// Needed to copy PacketReader and add one simple method because for some very odd reason, /// the original does not have ReadUnicodeStringLE(int fixedLength) (save values cannot be used because /// of the tab-seperator (\t)). /// RunUO Team, what's wrong? /// /// Author: squishy (Dominik Seifert) 05/12/2006 /// </summary> |
|
|
|
|
|
#14 (permalink) |
|
Forum Expert
|
Because, if you read everything properly, including the readme, it explains there is no overridable function to use.
As for "cannot find Ultima" - you too, need to read the readme... lol, doesn't anyone read that these days? You need Ultima.dll from the UO SDK (Ultima Online Software Development Kit)
__________________
![]() WWW.RPK-UO.COM - The WoW-UO Cross-Over Shard |
|
|
|
|
|
#15 (permalink) |
|
Forum Expert
|
guess I didn't understand it! I read it! really! *blushes*
I think I will look pretty stupid, but I don't care: What is the UO SDK? (don't give me the longterm, that I read!) and where to find it?
__________________
;)My C# Bookshelf (carpented by Soultaker);) BTW: Please ask questions in the adequat forum and not on a private message! Otherwise nobody can learn from it!
Last edited by Liacs; 12-05-2006 at 04:14 PM. |
|
|
|
|
|
#17 (permalink) | |
|
Forum Expert
|
Quote:
Code:
using System;
using System.Text;
using System.IO;
namespace Server.Network {
/// <summary>
/// Needed to copy PacketReader and add one simple method because for some very odd reason,
/// the original does not have ReadUnicodeStringLE(int fixedLength) (save values cannot be used because
/// of the tab-seperator (\t)).
/// RunUO Team, what's wrong?
///
/// Author: squishy (Dominik Seifert) 05/12/2006
/// </summary>
public class GoodPacketReader : PacketReader {
public GoodPacketReader(byte[] data, bool fixedSize) : base(
data, fixedSize ) { }
public string ReadUnicodeStringLE() {
return ReadUnicodeStringLE(m_Size);
}
public string ReadUnicodeStringLE(int fixedLength) {
int bound = m_Index + (fixedLength << 1);
int end = bound;
if (bound > m_Size)
bound = m_Size;
StringBuilder sb = new StringBuilder();
int c;
while ((m_Index + 1) < bound && (c = (m_Data[m_Index++] | (m_Data[m_Index++] << 8))) != 0) {
sb.Append((char)c);
}
m_Index = end;
return sb.ToString();
}
public string ReadUnicodeStringLESafe(int fixedLength) {
int bound = m_Index + (fixedLength << 1);
int end = bound;
if (bound > m_Size)
bound = m_Size;
StringBuilder sb = new StringBuilder();
int c;
while ((m_Index + 1) < bound && (c = (m_Data[m_Index++] | (m_Data[m_Index++] << 8))) != 0) {
if (IsSafeChar(c))
sb.Append((char)c);
}
m_Index = end;
return sb.ToString();
}
public string ReadUnicodeStringLESafe() {
StringBuilder sb = new StringBuilder();
int c;
while ((m_Index + 1) < m_Size && (c = (m_Data[m_Index++] | (m_Data[m_Index++] << 8))) != 0) {
if (IsSafeChar(c))
sb.Append((char)c);
}
return sb.ToString();
}
|
|
|
|
|
|
|
#20 (permalink) | |
|
Forum Expert
|
Wasn't trying to offend, but if you read it properly, it says
Quote:
![]()
__________________
![]() WWW.RPK-UO.COM - The WoW-UO Cross-Over Shard |
|
|
|
|
|
|
#22 (permalink) |
|
Forum Newbie
Join Date: Feb 2006
Posts: 30
|
I have to ask almost the same question as Pyro. What can be done with it that couldn't be done before?
I looked at all the files in the script but the only thing I could come up with is that it translates the language? (probably wrong but my best guess) |
|
|