The string just cuts off once it hits the non alpha number, but it will do all the alpha chars up to that point.
This includes " " space.
IE I do:
Code: Select all
if (ID == 17652){
int8* SigString = "Testing Sig";
int8 EncodedString[25];
EncodeStringSignature(SigString, EncodedString);
PItem->setSignature(EncodedString);
}
This goes for any non alpha symbol, not sure how to fix this.
Edit:
Im assuming the issue lies in here:
Code: Select all
for(uint8 currChar = 0; currChar < strlen((const char*)signature); ++currChar)
{
uint8 tempChar = 0;
if ((signature[currChar] >= '0') && (signature[currChar] <= '9'))
tempChar = signature[currChar]-'0'+1;
else if ((signature[currChar] >= 'A') && (signature[currChar] <= 'Z'))
tempChar = signature[currChar]-'A'+11;
else if ((signature[currChar] >= 'a') && (signature[currChar] <= 'z'))
tempChar = signature[currChar]-'a'+37;
packBitsLE(encodedSignature,tempChar,6*currChar,6);
chars++;
}
I assume this is the encoding process, and it only triggers for alphanumeric pieces.
But the game can support all characters, so what exactly is going on here? At the very least I want to encode the basic characters of ?,." and of course space.
The game SHOULD be able to handle such things, but I guess we aren't actually writing those symbols at all :x