Page 1 of 2

Gamerzilla

PostPosted: 30 Mar 2020, 00:17
by dulsi
I've decided to implement my idea of a game trophies in Hubzilla. Don't use this initial commit. This is only a really awful UI. There is no way to enter trophy information yet. My plan is to implement a library that will upload results so it is easy for developers to make use of the feature. (I haven't decided if it will be a standalone library or start/communicate with a separate process.)

Documentation for developing hubzilla plugins is bad. It references an older API. (I had hopes when looking at it that I could easily support friendica but it looks like that would probably need separate code.)

https://github.com/dulsi/gamerzilla

Re: Gamerzilla

PostPosted: 30 Mar 2020, 01:23
by Julius
Sorry to be a bit dense, but what exactly are "trophies" in this context? Something like Steamworks Achivements? Or something related to competitive play?

But nice that you chose Hubzilla as a platform, it is a really nice system over all.

Re: Gamerzilla

PostPosted: 30 Mar 2020, 06:20
by dulsi
Playstation has trophies. Steam has achievements. I don't remember what Xbox calls them.

Hubzilla lacks plugin documentation and it hasn't been updated. For example, I'm like to add the achievements to the menu like photos but I haven't found an example that does that. PHP is also not my favorite but I understand that it is easy to deploy in a lot of places.

Re: Gamerzilla

PostPosted: 30 Mar 2020, 12:33
by Lyberta
Deleted.

Re: Gamerzilla

PostPosted: 31 Mar 2020, 00:14
by Technopeasant
Then don't use them...

Though honestly I do not particularly enjoy them either. A challenge is much more rewarding if it is something you decide to do yourself.

Re: Gamerzilla

PostPosted: 31 Mar 2020, 23:37
by Lyberta
Deleted.

Re: Gamerzilla

PostPosted: 06 Apr 2020, 00:32
by dulsi
Started working on the library for games to use. Not usable yet.

https://github.com/dulsi/libgamerzilla

The library will allow the game to store all the information locally and not talk to hubzilla if you want. I don't really expect most programs will want to have a setting screen for hubzilla. Instead it will connect to another process so that only that process would need to be configured. A program like Gnome Games would be ideal for that process. Unlike steam you wouldn't be required to use that program nor would you be required to record trophies anywhere.

I'm not sure how communication will be done. I'm thinking unix domain socket on linux. My concern is what would be best for supporting flatpak and snap. (I personally don't like those packaging method but I understand some do.)

Re: Gamerzilla

PostPosted: 20 Apr 2020, 01:35
by dulsi
Started working on the server implementation in the library. It doesn't do anything yet. I decided to go with abstract unix domain sockets for communication. They are Linux specific which is unfortunate. Microsoft added support for them apparently which leaves Macs and BSD. Of course, issue ticket suggests it doesn't work.

Re: Gamerzilla

PostPosted: 20 Apr 2020, 01:59
by Julius
Hmm, not an expert at all on that topic, but I have seen most non-performance critical apps to use TCP loopback instead? Maybe that works more universally?

Re: Gamerzilla

PostPosted: 20 Apr 2020, 15:35
by dulsi
Julius {l Wrote}:Hmm, not an expert at all on that topic, but I have seen most non-performance critical apps to use TCP loopback instead? Maybe that works more universally?

It probably is more universal.I may end up needing to do that in the end to support most platform. Since only socket creation is different, it wouldn't be hard to code support for both. I was initially going to do TCP loopback and then saw an article about how some security problems have occurred due to people assuming that was safe only to have javascript in the browser connect to the TCP loopback service. (Granted web browsers might have unix domain sockets available or add it and create the same problem.)

Re: Gamerzilla

PostPosted: 30 Apr 2020, 21:32
by dulsi
LibGamerzilla and Gamerzilla plugin have progressed. I now have images for games. Work has progressed on making LibGamerzilla work with a game manager and offline. Readme has a section for game developers to use it although not everything is implemented yet. The API for game managers is still in progress. I have a simple program to relay actions but nothing else yet.
Image

Re: Gamerzilla

PostPosted: 02 May 2020, 01:25
by Sockstah
I really like the idea behind this.
There have been a couple of suggestions and implementations of an "open source Steam" but really what they are are just frontends for downloading open source games. It seems what a lot of people think Steam is is just a storefront, ignoring all the Steamworks infrastructure it provides.
This achievement system could be the first step towards an open ecosystem like that. I'd really like to see that and I think it's something that could help gaming in general become more free (as in freedom) or at least help popularity of open source games. When Steam came to Linux their popularity took a steep decline I'd say (not that I have data to back this up) and I don't just think this is because proprietary games are better, I think it's also because of a lot of the conveniences Steam provides. Open source games and the ecosystem built around them really lag behind in that regard.

Re: Gamerzilla

PostPosted: 04 May 2020, 00:13
by dulsi
I got SWIG running and tried adding support to seahorse adventures. It can work although I just hardcoded giving me the one trophy to try it out. I don't really like the interface.

{l Code}: {l Select All Code}
        gamerzilla.GamerzillaInit(False, os.path.join(data_home, "seahorse-adventures") + "/")
        seahorse = gamerzilla.Gamerzilla()
        seahorse.short_name = "seahorse_adventures"
        seahorse.name = "Seahorse Adventures"
        seahorse.image = "data/gamerzilla/seahorse-adventures.png"
        seahorse.version = 1
        seahorse.numTrophy = 1
        trophy = gamerzilla.GamerzillaTrophy()
        trophy.name = "Defeat Boss"
        trophy.desc = "Defeat all levels and boss in order"
        trophy.maxprogress = 1
        trophy.true_image = "data/gamerzilla/win1.png"
        trophy.false_image = "data/gamerzilla/win0.png"
        trophyArray = gamerzilla.new_GamerzillaTrophyArray(1)
        gamerzilla.GamerzillaTrophyArray_setitem(trophyArray, 0, trophy);
        seahorse.trophy = trophyArray
        gameid = gamerzilla.GamerzillaGameInit(seahorse)

Right now you need to create a trophy array. Then create each trophy and set the value in the array. I think maybe I need a function to add trophies instead. Something like:

{l Code}: {l Select All Code}
        gamerzilla.GamerzillaAddTrophy(seahorse, "Defeat Boss", "Defeat all levels and boss in order", 1,"data/gamerzilla/win1.png", "data/gamerzilla/win0.png")

Re: Gamerzilla

PostPosted: 12 May 2020, 03:54
by dulsi
LibGamerzilla now compiles and works on windows. It uses localhost network connection to communicate with the game manager process at the moment. You may be able to use abstract unix domain sockets on windows 10 but I doubt it is available on other versions additionally the Fedora cross-compiler doesn't support it. So I went with the simple solution for now. I have a little more cleanup to do. Right now it is not encoding everything. A game with an ampersand in the name won't work.

Re: Gamerzilla

PostPosted: 13 May 2020, 00:03
by Julius
Cool. Thanks for sharing the progress. So any games particularly that you would like to integrate it with?

Re: Gamerzilla

PostPosted: 13 May 2020, 04:23
by dulsi
No games in particular. I just want to get as much support as possible in games and game managers. I expect to add it to Ostrich Riders and Shippy 1984. Once it is fully usable I'd like to post about it on itch.io and see if I can even get closed source indie games to adopt it.

Re: Gamerzilla

PostPosted: 18 May 2020, 13:49
by dulsi
The server functionality now fully syncs. It needs a little more to it's interface to be usable. Then I just need to get it into a game manager.

Re: Gamerzilla

PostPosted: 17 Jun 2020, 21:02
by dulsi
I've created a video to explain the basics of Gamerzilla. Plan is to tag a version of libgamerzilla and get it included in Fedora.

Re: Gamerzilla

PostPosted: 10 Jul 2020, 02:40
by dulsi
Libgamerzilla has been submitted to Fedora. Although it hasn't gotten through the testing process yet. I just released 0.0.3 so the time period has been reset. I have the start of a gamerzilla implementation for Gamehub. It doesn't do anything yet except listen and forward requests to hubzilla. I submitted a pull request mainly to get feedback from Gamehub maintainer as to what he thinks of the idea. Gamehub is written in vala. I will say the way to interface with a C library is very slick. You write very little but then again swig allow the same for python.

I'm think the setup process of Gamerzilla is too complex. Right now you have to fill in this srtucture and call GamerzillaSetGame. Filling in the structure in non-C languages is a pain. I was thinking of changing it to just load the game information from a json file.

Re: Gamerzilla

PostPosted: 19 Jul 2020, 17:05
by dulsi
There is a new function to read the trophy information from a file. I've added enough functionality to implement support in GameHub. Now I just need to get it accepted.
Image

Re: Gamerzilla

PostPosted: 31 Jul 2020, 01:25
by dulsi
Looks like I'm too late to convince Epic to use Gamerzilla.

Re: Gamerzilla

PostPosted: 04 Aug 2020, 08:00
by Lyberta
Deleted.

Re: Gamerzilla

PostPosted: 04 Aug 2020, 10:16
by Julius
That was obviously a joke. And please (as much as I agree that this is horrible) leave the geo-politics out of this discussion/forum (if you insist, there is the off-topic section). But yes, I think most of us are here because we don't want to take part in stuff companies like Epic do. Gamerzilla seems like a nice ethical alternative even if you might disagree that achievements are a good game mechanic in general.

Re: Gamerzilla

PostPosted: 04 Aug 2020, 10:46
by Lyberta
Deleted.

Re: Gamerzilla

PostPosted: 13 Nov 2020, 19:16
by dulsi
Gamerzilla is now available on the FreeGameDev's hubzilla server. You can now see how I'm doing in some games. Still don't have a game launcher with merged support yet.