Can't find the problem! :S
Hey All
I've been working on this problem for a while now... Right now it's midnight, and I started around 21:00 (9:00PM). I can't figure it out, and i'm going to bed; but maybe someone can help me. The problem I think is something to do with vault. It ocuurs hen I load someones exp. The save debug messages look fine. But when I load it the debugs are bad. (e.x. "Exp data () loaded for user: (username)" "Current exp = 0" ) I cannot figure this out, because the code seems perfect to me. Here it is, there's a lot but i'll try only to post what's relevant. Code:
I always get () as the data in the debug message, which sets exp to 0. For interests sake, I can save and load the players alliance fine: Code:
The alliance code works fine, saves, loads and displays like it should. The experience code at the top does not. Can someone tell me why? OFFTOPIC: How does the set_hudmessage function work? This code displays the message at the top left of the screen: Code:
While this code displays it at the bottom right Code:
The only difference I see is the latter one has decimals, and has the effect set to 1. That shouldn't make such a huge difference should it? |
in this
Code:
you are formatting data to use a number as a string. You should do a num_to_str before you store it. Code:
|
Thanx man :)
That worked, but now i'm confused as hell. Why don't I have to do that with Alliance as well? It works fine. Anyways, now I am getting array index out of bounds errors like you wouldn't believe. I'll work on it after school, but if anything pops into your head please post. When I join the server (in console) Quote:
ok so as i type this post it works.. i'll scroll up and find it: Quote:
hmmm :S the only array in there is PlayerExp[id] which goes from 0 to 32 |
Code:
Remember to save the last character for the string terminator. Increase your strTargetID size to 3 and your strExp size to 9, but leave your read_argv's the same. |
ahh.. didn't know that, thanx. Also, i'm still wondering about how the coords work on set_hudmessage. I need top left, top center, and top right. It would be nice if someone could explain the system to me though.
|
There's a plugin that will help you get the coords. :)
|
| All times are GMT -4. The time now is 09:57. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.