Cant track player stats for rank

JoshuaJewellJoshuaJewell

很久以前 | 帖子#1
I do this when a player enters my server:

( c# code )
wordsFormed2Letter = player.GetRankingScore("twoLetterWords");

and then as the game progresses I accumulate this counter. When the player finally leaves the game I do this:

( c# code )
player.SetRankingScore( "twoLetterWords", wordsFormed2Letter );

I was expecting that each time a player joins a game their rank would accumulate. In fact while testing locally, and at one point on nonoba this is the response I got.

Now it seems like GetRankingScore is always returning 0 and the ranks are being reset. This happened after I uploaded a new version of my game.

In the past I tried using SetData and GetData to persist these stats but every time I uploaded a new version of my client and server this data would be wiped out and reset back to 0. Took me a bit too figure out.

Am I doing something silly here? Maybe I have a misunderstanding about how things should work. Any clarification would be great.

Thanks,
Joshua Jewell

OliverOliver

很久以前 | 帖子#2
Hey Joshua,

Could you send me the code you are testing with ? I'd love to be able to reproduce this in context.

my e-mail is my username at this domain.

-- Oliver

JoshuaJewellJoshuaJewell

很久以前 | 帖子#3
Hey Oliver I sent you a private message with information for connection to my subversion repo.

JoshuaJewellJoshuaJewell

很久以前 | 帖子#4
Found the problem, someway through my testing the player.GetRankingScore() call became case sensitive. For example

player.GetRankingScore("twoLetterWords");
will not work

player.GetRankingScore("twoletterwords");
will work

JoshuaJewellJoshuaJewell

很久以前 | 帖子#5
I got another problem, not sure if its related. Out of no where all my ranks were reset to 0 again.

It is really hard to figure out whats going on since the server is basically a black box to me. One thing that would be helpful is a log of all the server side requests my game makes using the Nonoba api. Is this something that is available? It could shed some light onto what is happening behind the scenes, assuming I didn't so something wrong myself.

Has anyone else had any problems with rankings?
最后编辑很久以前

JoshuaJewellJoshuaJewell

很久以前 | 帖子#6
The new problem that is occurring looks like it may be a problem with my game specifically, I will have to dig a bit deeper. The lack of transparency does make things a bit harder to debug.

Also as a note it seems like user data is only persistent within a certain version of the game. When I have some free time I will dig into this further.

OliverOliver

很久以前 | 帖子#7
One of the problems is that we don't have the same datastorage in development mode as we do in live (locally we use some files while we use databases live), which means we've got two implementations that are supposed to do the same thing.

If you make any test case that fails, i'll look into it.

i'm pretty sure ranking lists are supposed to be case insensitive... i'll look into it...

JoshuaJewellJoshuaJewell

很久以前 | 帖子#8
Ok the ranks being reset to zero was something wrong with my code, however the case sensitivity issue still persists for me.

For example, I have a ranked list called:

twoletterwords

When I output the following to console I get two different answers:

[c# code]
Console.WriteLine( player.GetRankingScore("twoletterwords").ToString() );

[c# code]
Console.WriteLine( player.GetRankingScore("TWOletterwords").ToString() );


The first call prints the correct rank score, the second call prints 0.

I am using version 1.5.2 of the development server

回复主题

现在就注册以回复主题

5dyouxi

5dyouxi.com是一个独立的游戏网站,在这里你将可以免费玩到各种好玩的单人和多人游戏。

开发者工具

如果你是一位flash游戏开发者,我们有一些非常强大的工具来帮助你开发更加优秀的游戏。

经典游戏

为什么不试试我们这里的一些最为优秀的在线flash游戏呢?这可是完全免费的!

Copyright ©2007-2012 5dyouxi™ - All rights reserved.31.2001ms on SERVER34096
注册 或者