Page 1 of 1

User module and online character sheets

Posted: Sat Feb 19, 2011 11:02 pm
by Marcotte
I starting to get very close to what will be the first real release of B.O.B. (aka B.O.B. version 0.3.1), and I would like to enable the online character sheets feature that ToME has. That way I will be better able to see how players are faring. So far, looking at the code, it seems that the character sheet itself is relatively straightforward, simply by extending interface/PlayerDumpJSON, however the character sheet feature depends on the online profile. Looking at the player profile code, it tests the hash of the local version of the module online.

So, is there any process by which I will be able to register my module to the character vault? Or is it not yet ready for it?

By the way, line 241 of Module.lua (SVN 2762):

Code: Select all

	-- If bad hash, switch to dev profile
	if not hash_valid and not profile.auth then
		print("[PROFILE] switching to dev profile")
		_G.profile = engine.PlayerProfile.new("dev")
	end
Is it correct? I would think that having either the hash or authorization being incorrect would lead to being switched to the development profile, not requires both of them.

Re: User module and online character sheets

Posted: Sun Feb 20, 2011 11:02 am
by darkgod
Ah yes :)

As for registering your module, you just need need to send me the md5 of it (that the game gives when you boot it) and the version string, like "tome-3.9.20".
I then just register it in my database and you're good to go :)

And I gladly welcome a new module to join the online fun!

PS: the version string is available directly in game.__mod_info.version_name

Re: User module and online character sheets

Posted: Sun Feb 20, 2011 11:45 am
by darkgod
BTW you should drop by on IRC #tome on irc.rizon.net it'll be easier for the last bits of setup :)

Re: User module and online character sheets

Posted: Sun Feb 20, 2011 5:26 pm
by Marcotte
Thanks, that should be simple enough.

It should be ready to release in about a week, although I may wait until the next beta to do so.