Bug with strings?

Report core bugs regarding the Ultima Online Emulator Core release (version 097). You can attach your Core Dump. One bug per post.

Moderator: POL Developer

Neophyte Poster
Posts: 33
Joined: Mon Apr 02, 2007 1:13 pm

Bug with strings?

Post by Nightson » Thu Sep 25, 2008 11:18 am

Code: Select all

var skill := Randomint(48)+1;
skill := GetAttributeIdBySkillId(skill); // Function from attributes.inc
bonus := Randomint(4)+1;
name := GetBonusNameByAttribute(skill); <== This function returns string like that "[Alchemii]"
This script above creates item then another script ( item identification )

Code: Select all

var factor := GetObjProperty(item,"dmagic");
item.name := item.desc+""+factor[4];
And almost everrything works ok but sometimes i have item name like that (example) "Robe Unable to unpack string length. String length excessive."

i tryed to GetObjProperty Then SetObjProperty on item and in my array there was no "[Alchemii]" only Unable to unpack string length. String length excessive.

imho core bug

POL Expert
Posts: 1090
Joined: Sun Feb 12, 2006 9:50 pm
Location: Cross Lanes, WV

Re: Bug with strings?

Post by MuadDib » Tue Dec 30, 2008 2:18 pm

The string length excessive would be when the item is read or saved to the Data files. First, check there, as that would point to an invalid saving of the CProp itself. let me know if you can find this. (you HAVE to have the item's saved information from the txt file from BEFORE it messed up the name when POL Loaded, as we would need to see the BAD saved CProp on the item that had the [NameofAttribute] stored on before it gave the error.
POL Developer - The Penguin Scripter