Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Shaga-moonlight client (part of the Shaga Protocol) #1251

Draft
wants to merge 22 commits into
base: master
Choose a base branch
from

Conversation

chat-grp
Copy link

Hi core maintainers, we've interacted a bit on the discord server when i asked about alternative pairings for Sunshine-Moonlight interactions, im a 21 yo cs engineering student from milan, italy.

While at uni, i wanted to buy a high-end gaming pc but didn't have money and thought that i would be spending most of my time away from home.

I really wished there was either a way to rent a gaming pc that didn't suck because of high latencies, or even a way for me to buy a gaming pc and recover some of the costs when i wasn't using it.

I had already been a moonlight-android user since 2019 so i was already familiar with the possibilities and also the limitations.

Recently i've started working on Shaga, a Sunshine-Moonlight Enhancer that will allow unknown Hosts and Clients to connect, allowing some to make some passive income money with their Gaming PC and others to have a High-End Gaming Experience for cheap (for a limited time).

Of course the limitations for the latency are there and this will only be useful (maybe, eventually) in highly dense metropolitan cities but there's neighborhoods where this could work that aren't as dense as tokyo or los angeles.

I think this will be beneficial to the Sunshine-Moonlight community and hopefully many hubs will grow in the future, where proximity enables to have decent latencies, to form local physical gaming communities.

Now about the tech:

I will be using initially Solana because it's really cheap and really fast and allows borrowers and lenders to transact without too much hassle.

The accounts of shaga-moonlight clients and shaga-sunshine hosts will be there, just think of solana as a reliable backend.
It will also be used to store reputation for shaga-sunshine hosts, to prevent hosts from starting to lend and going offline shortly after the payment.
Also, the connection establishment will be done through cryptographic proofs on solana of the moonlight client payments that the sunshine host will verify before establishing the connection and starting to stream content.

Initially, the discovery of available sunshine hosts from the moonlight clients will be done through accounts on solana, and the data will be visualized on the shaga-moonlight apk through mapbox, to give a "uber" ux where m.c. (moonlight clients) are able to discover s.h (sunshine hosts). They will be able to test latency in advance before the payment.

The sessions will be Compressed-NFTs on solana and a solana program will be used to act as a "marketplace" to aggregate the session-nfts and let the moonlight client fetch data about the available ones and visualize it on the app.

As of right now, i've started implementing some basic wallet functions on the moonlight-android apk that use a solana kotlin library "https://github.com/metaplex-foundation/SolanaKT".

Then, i will be modifying the sunshine simple-web-server adding solana functionalities from "https://solana-labs.github.io/solana-web3.js/"

At the end of my work i hope i'll be producing an mvp for this system showing the potentialities of a global/local gaming network, hopefully also bringing contributors from the solana ecosystem to the sunshine-moonlight codebase.

It will be highly-insecure software and not even close to be production ready, but hopefully it will be the start of something that can benefit gamers all over the globe.

Before everything was digitized, sharing a game disk with a friend or renting game disks at blockbuster was a totally normal thing, now with shaga, but mostly moonlight&sunshine, i hope to bring back the sharing ability by sharing the computer itself.

#SeizeTheMeansOfComputation

This work will be done for the solana hyperdrive hackathon "https://solana.com/hyperdrive".

All the credits will be given to you for what you've accomplished so far and of course, anything that comes out of this will be open-source, for two main reasons:

  1. I'm in awe of your progress and am building on "the shoulders of giants"
  2. Whoever is going to participate in the Shaga-Moonlight-Sunshine Protocol will want to know what is running on their machines and open-source software is mandatory to let anyone audit what they're running.

I would love to have your feedback on this and if possible guide me with integration tips. I hope this will be received well by the Moonlight-Sunshine Community.

You can learn more at https://twitter.com/Web3Shaga.

nietBabishka and others added 22 commits September 16, 2023 15:09
- added lots of solana stuff without breaking core functionality

next: test JSON RPC calls to visualize wallet balance on screen (home page, where Sunshine/Gamestream hosts are shown)
- added lots of solana stuff without breaking core functionality

next: test JSON RPC calls to visualize wallet balance on screen (home page, where Sunshine/Gamestream hosts are shown)
- added lots of solana stuff without breaking core functionality

next: test JSON RPC calls to visualize wallet balance on screen (home page, where Sunshine/Gamestream hosts are shown)
…ypairs by mapping them to x25519 keypairs and using them to encrypt the PIN and transmit it directly at pair http request.

Waiting to have the Solana Shaga Program & Session PDAs ready to start testing the connection.

Then, we'll implement a MapUI if everything works fine.
…ypairs by mapping them to x25519 keypairs and using them to encrypt the PIN and transmit it directly at pair http request.

Waiting to have the Solana Shaga Program & Session PDAs ready to start testing the connection.

Then, we'll implement a MapUI if everything works fine.
map integrated & apk working with synthetic data, time to start integrating the solana instructions & start testing the Shaga Protocol (Solana-Moonlight)
map integrated & apk working with synthetic data, time to start integrating the solana instructions & start testing the Shaga Protocol (Solana-Moonlight)
started testing affair fetching & displaying, it was working with synthetic data
started testing affair fetching & displaying, it was working with synthetic data
started testing affair fetching & displaying, it was working with synthetic data
started testing affair fetching & displaying, it was working with synthetic data
started testing affair fetching & displaying, it was working with synthetic data
started testing affair fetching & displaying, it was working with synthetic data
started testing affair fetching & displaying, it was working with synthetic data
started testing affair fetching & displaying, it was working with synthetic data
started testing affair fetching & displaying, it was working with synthetic data
started testing affair fetching & displaying, it was working with synthetic data
started testing affair fetching & displaying, it was working with synthetic data
started testing affair fetching & displaying, it was working with synthetic data
Hyperdrive submission (still rough, needs bit more love)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants