Git Product home page Git Product logo

loopringunity's Introduction

LoopringUnity

Loopring API Integration with Unity Engine

LoopringUnity is a free to use package, which can easily integrate the Loopring API into your Unity WebGL game/app. It was originally created to support the development Loop Monsters game.

Notes:

  • This has been tested and working in Unity Verion 2020.3.30f1.
  • You MUST switch your taget platform to WebGL (File > Build Settings).
  • Chainsafe SDK is used to query an ethereum smart contract.
  • WalletConnectUnity is used to handle the WalletConnect authentication and signing.

Features

  • Connect with Metamask, Gamestop Wallet or WalletConnect.
  • Make API calls to Looprings API.
  • 1 Click Import the package to have the bare essentials set up your Loopring DAPP.

Dapps using LoopringUnity

Submit any to [email protected]

  • Loop Monsters Alpha Play

Current API Calls

These are the current Loopring API calls intergrated, if you look at the ApiCaller.cs script, you can easily add more. (more will be added in the future).

All of the responses from these functions are stored in an object with all of its attributes.

Function Use
GetAPIKey Gets users L2 API Key
GetAccountIDTask Gets users account information
GetTokenBalance Gets users NFT data
ResolveENS Gets Loopring ENS
GetMetadata Gets Metadata from IPFS

Installation

  1. Download and install Unity Version 2020.3.30f1 with the WebGL package.
  2. Download the LoopringUnityPackage.unitypackage file and import it as a custom package into your unity project.
  3. Ensure your project platform is set to WebGL (File > Build Settings).
  4. Add the following scenes to the build settings: Login, Unlock, Main
  5. Build and Run, the demo shows the first 8 characters of your L2 API key so you can verify it is correct.

Security

Due to handling a Loopring API key, precautions are taken to ensure it stays secure. After it has been used to query the data, it is wiped from the app. You ALWAYS want to ensure your API and Privatekey are being handled safely, if you open the network tab (f12), you can see where the API key is being sent (Looprings API), if you notice an app that sends data to an external location, PLEASE REPORT IT IMMEDIATELY that that means your API +/ Private key has been potentially compromised.

Support

Feel free to raise any issues if you come across any problems, I will try to resolve them asap.

If you wish to support the project, you can follow @LoopmonNetwork on twitter, join our discord or on Reddit r/LoopMonsters. Also give Fudgey a follow @fudgeyDOTeth.

Terms and Conditions

This cannot be sold or resold, or integrate any components as a paid service. Any derivative of this must be free.

Credits

Loopmon - Signing and authentication Integration donation address: monster.loopmon.eth

Exquoesme - Web3 Wallet Integration donation address: exquoesme.loopring.eth

Fudgey - PoseidonSharp donation address: fudgey.eth

loopringunity's People

Contributors

grandwiz avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.