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

Chainsafe SDK Injection #28

Open
Gizmotronn opened this issue Feb 20, 2022 · 1 comment
Open

Chainsafe SDK Injection #28

Gizmotronn opened this issue Feb 20, 2022 · 1 comment

Comments

@Gizmotronn
Copy link
Member

WebLogin.cs script:

using System;
using System.Runtime.InteropServices;
using UnityEngine;
using UnityEngine.SceneManagement;

#if UNITY_WEBGL
public class WebLogin : MonoBehaviour
{
    [DllImport("__Internal")]
    private static extern void Web3Connect();

    [DllImport("__Internal")]
    private static extern string ConnectAccount();

    [DllImport("__Internal")]
    private static extern void SetConnectAccount(string value);

    private int expirationTime;
    private string account; 

    public void OnLogin()
    {
        Web3Connect();
        OnConnected();
    }

    async private void OnConnected()
    {
        account = ConnectAccount();
        while (account == "") {
            await new WaitForSeconds(1f);
            account = ConnectAccount();
        };
        // save account for next scene
        PlayerPrefs.SetString("Account", account);
        // reset login message
        SetConnectAccount("");
        // load next scene
        SceneManager.LoadScene(SceneManager.GetActiveScene().buildIndex + 1);
    }

    public void OnSkip()
    {
        // burner account for skipped sign in screen
        PlayerPrefs.SetString("Account", "");
        // move to next scene
        SceneManager.LoadScene(SceneManager.GetActiveScene().buildIndex + 1);
    }
}
#endif
@Gizmotronn Gizmotronn added this to To do in Minimal Minigames via automation Feb 20, 2022
@Gizmotronn Gizmotronn self-assigned this Feb 20, 2022
@Gizmotronn Gizmotronn added this to To do in Unity Blockchain Injection via automation Feb 20, 2022
Gizmotronn added a commit that referenced this issue Feb 20, 2022
🩸🔑 -> #28 Build for Chainsafe login done
@Gizmotronn
Copy link
Member Author

Remix

Metadata of "subtracttoken" was published successfully.
contracts/Counter.sol : 
dweb:/ipfs/QmQ1oWFqad62DDvpeMi9SQ79CJuSmgeYCQpciP4cLb5ePJ
metadata.json : 
dweb:/ipfs/QmWEoth4v9gNaFMotBmyafcHKu9o2RTbeEmpTVEXZwz8v5

Commit for this: ba888bd

Gizmotronn added a commit that referenced this issue Mar 4, 2022
🎁🤖 -> Calling custom contracts in Unity for #28, integrating with #11
Gizmotronn added a commit to Signal-K/client that referenced this issue Feb 20, 2023
Users can now navigate to `/planets/{$planetID}` to see information relating to their planet, including datasets, articles, a sandbox, basic stats/info, a gallery, and a generator.

Generator:
Signal-K/sytizen#18
Right now it's just the same generator script, but eventually it will take in the fields like radius from the table the page itself is generated from. We'll update the frontend fields to use a UI based on the <Card /> component we've designed for the Profile pages. users will be able to edit these fields and create a fork of the anomaly in its dataset sandbox for use in their own projects, and this can be part of the "XP" demo for "citizen science points" to mimic the behaviour of the reputation erc20 token:

Now that staking has been re-added, time to close #18

Signal-K/sytizen#16 Profile pages
Signal-K/sytizen#13
Signal-K/sytizen#6 -> Generator & staking
Signal-K/sytizen#1 -> sandbox & generator
Signal-K/Unity-Demo#28
Signal-K/Unity-Demo#5
Signal-K/starsailors#4 -> user input on anomalies
Signal-K/Silfur#26
Signal-K/Silfur#25 -> Some small changes with the Thirdweb module behaviour, still yet to commence full re-integration now though
Signal-K/Silfur#24
Signal-K/Silfur#22 -> Replacing "mint" FOR NOW with just a "claim" button that sends the planet to your supabase table inventory (array/foreign key in 'profiles' table

Signal-K/Silfur#21
Signal-K/Silfur#12 -> Keep an eye on this, but for now this is deprecated
Signal-K/Silfur#3 -> Again keep an eye on the original card game contract, but until we commence the full re-integration of the smart contracts, this is not needed

Signal-K/Silfur#30 -> This is working a treat
Signal-K/Silfur#29 -> Now need to add true threaded comments & integrate it with sandbox items

Full notes available here: https://www.notion.so/skinetics/February-Flow-Planets-8c864b66147c447f82136772336e9bc6?pvs=4#09b8260b2360412683ef5935309fd011
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

3 participants