• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Strange symbols in database

_Aion_

Nothing Else
Joined
Jan 19, 2010
Messages
400
Solutions
4
Reaction score
10
Location
Jequie,Bahia,Brazil
Can anyone help me?
a while ago I had a problem with a script, then deactivated the script.
But the "nothing" gave the same error in a current script, made by Darkoahs.
Link of script that are giving erro http://otland.net/f83/grizzly-adams-killing-name-quest-all-tasks-more-real-tibia-159150/
The error consists of, instead of getting numerical values ​​in the database, something is "corrupting" my database, rendering them with symbols.
Look at the picture.

Capturar.JPG

If anyone knows how I can fix, I thank you.
I think it must be something in the sourcer, because the script made ​​by him is without error.
Note: I'm using TFS 0.3.6 PL1
 
Last edited:
Well, I think you can just dump the database. It seems to be the only logical way to go about such a problem. Otherwise I'd try to delete the storage keys that are bigger than 65000 from your database completely. I do not have much experience with databases, but I believe that may solve your problem.
I've done it and it did not work when the player will perform the action again, the same values ​​will appear (even if I change 65000 to 12000) will give this problem, however with a different key.
have tested all possible ways (as I know), I used a database "virgin" and nothing works.

- - - Updated - - -

BUMP
anyone know how to solve?
 
Have many scripts that give this error
example, where is place that show "attempt to perform..."
Example: local new = setPlayerStorageValue(cid, 47061) + (newlevel - oldLevel) * 2 ) <<< in one of my scripts, this line shows how error
 
Have many scripts that give this error
example, where is place that show "attempt to perform..."
Example: local new = setPlayerStorageValue(cid, 47061) + (newlevel - oldLevel) * 2 ) <<< in one of my scripts, this line shows how error

err, where is the rest of this line? you have a close parenthesis at the end but no open parenthesis matching. i'm not even entirely sure what you're attempting to do here and i don't know shit about servers and storage and any of what you are doing but i'll throw out a couple things that might get the ball rolling (or just waste my time because i'm wrong, which is fine, i'm just here to try to help!)

issue 1 that may arise: if you meant "local new = setPlayerStorageValue((cid, 47061) + (newlevel - oldLevel) * 2 )" then you would have a huge number because 47k would be multiplied by 2

issue 2 that may arise: if you meant "local new = setPlayerStorageValue(cid, 47061) + ((newlevel - oldLevel) * 2 )" then you would run into the risk of multiplying 0 by 2 or setting storage that is lower than 47061 if the new level is less than the old level (i.e. if they died and their new level is less than their old level). i don't know anything about servers but i do know that a lot of programs don't like playing with negative numbers and put characters in the place of signed fields or numbers over their threshold

issue 3 that may arise: if what you put is correct, then you may want to try to figure out what you are multiplying by 2 in your statement because it looks mighty weird from my perspective.
 
there are many people who use this quest and you are the only one with this problem. i don't think it has anything to do with tables
 
Would you mind posting a script that corrupts the storage value (not grizzly adams)? :p

- - - Edited - - -

Just tested the script myself and didn't have any issues at all. Would you mind posting the whole console error (attempt to perform arithmetic~)?
 
Last edited:
Here, other script that corrupts
Code:
function onAdvance(cid, skill, oldlevel, newlevel)

local attribute = (getPlayerStorageValue(cid, 47061) + (newlevel - oldlevel) * 2) -- line that show "attempt to perform..."

if skill == 8 then
  doSendMagicEffect(getThingPos(cid), math.random(28, 30))
  doSendAnimatedText(getThingPos(cid), "LEVEL UP!", math.random(1, 255))
  doCreatureAddHealth(cid, getCreatureMaxHealth(cid))
  doCreatureAddMana(cid, getCreatureMaxMana(cid))
  setPlayerStorageValue(cid, 47061, attribute)
  end
  return true
end
 
Back
Top