Socket
Socket
Sign inDemoInstall

@pooky-labs/smart-contracts

Package Overview
Dependencies
47
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.9.0-alpha.98.1 to 0.9.0-alpha.100.1

2

package.json
{
"name": "@pooky-labs/smart-contracts",
"version": "0.9.0-alpha.98.1+059b9d4",
"version": "0.9.0-alpha.100.1+1e4ab4b",
"description": "Pooky smart contracts running on the Polygon blockchain",

@@ -5,0 +5,0 @@ "keywords": [

@@ -7,94 +7,23 @@ # Pooky Smart Contracts

## Contribute
## Governance
This repository uses the following environment:
### Maintainers
- Node.js LTS (18.x since October 2022)
- npm 8.x
- Mathieu Bour <mathieu.bour@pooky.gg>, Blockchain Engineer, Pooky Labs
### Repository organization
### Contributors
```
.
├── artifacts # (git-ignored) HardHat compile artifacts
├── cache # (git-ignored) HardHat cache
├── contracts # Smart contracts Solidity source code
├── coverage # (git-ignored) Code-coverage reports
├── diagrams
├── docs # Contract API referece (generated with OpenZeppelin soldity-docgen)
├── lib # TypeScript source code
├── node_modules # (git-ignored) Project dependencies
├── scripts # Runnable HardHat scripts
├── static # Static assets
├── tasks # Custom HardHat tasks
├── test # Smart contracts tests
└── typings # (git-ignored) TypeChain-generated typings
```
- Dusan Zdravkovic <duxxud@gmail.com>, Former Blockchain Engineer, Pooky Labs
### Testing
### On-chain maintenance
Contract unit tests are located inside the [`test/`](./test) directory. Each contract has it own test file that contains
its unit tests.
Most of the Pooky smart contracts are based on the OpenZeppelin AccessControl smart contract, providing fine-grained
permissions to the contracts.
For example, the MINTER role is allowed to freely mint $POK tokens.
```
contracts/POK.sol => test/POK.spec.ts
contracts/Pookyball.sol => test/Pookyball.spec.ts
etc.
```
### Useful resources
- OpenZeppelin Upgradable contracts: [documentation](https://docs.openzeppelin.com/upgrades-plugins/1.x/writing-upgradeable) / [repository](https://github.com/OpenZeppelin/openzeppelin-contracts-upgradeable#readme)
- [TypeChain: TypeScript bindings for Ethereum smart contracts](https://github.com/dethcrypto/TypeChain)
- [Polygon Mumbai Testnet Faucet](https://mumbaifaucet.com/)
## Smart contracts organization
[Smart contracts diagrams](./diagrams/readme.md)
### Pooky Wallets
- `EXEC_WALLET` - Multisig wallet owned by Pooky Executives team.
- `TECH_WALLET` - Multisig wallet owned by Pooky Technical team.
- `REWARD_SIGNER_WALLET` - Wallet which is stored securely on the backend, used to sign rewards.
- `TimelockAdmin` - Timelock contract to set delay of 48h on transaction execution. Proposers for transactions will be `EXEC_WALLET` and `TECH_WALLET`, transaction executors will be restricted to `EXEC_WALLET`.
### Roles
- `ProxyAdmin`
- Used in all proxy contracts.
- This role can upgrade and change implementation contracts. Only address which will have this permission is `TimelockAdmin` contract.
- `DEFAULT_ADMIN_ROLE`
- Used in `POK.sol`, `Pookyball.sol`, `PookyballMinter.sol`, `PookyballGenesisMinter.sol`, `PookyGame.sol`.
- Only address which will have these permissions is `TimelockAdmin` contract.
- Can add/remove roles on contracts.
- Can enable/disable transfer of $POK tokens.
- Can set `contractURI` on `Pookyball.sol`.
- Can set Pookyball and POK contract addresses on `PookyballMinter.sol` and `PookyGame.sol`.
- Can set treasury wallet on `PookyballGenesisMinter.sol`.
- Can withdraw funds on `PookyGame.sol`.
- `POOKY_CONTRACT`
- Used in `POK.sol` and `Pookyball.sol`.
- Only addresses which will have these permissions are other Pooky smart contracts (`PookyballMinter.sol`, `PookyballGenesisMinter.sol`, `PookyGame.sol`).
- Can mint $POK or burn from its address. Can send/receive $POK while transfer is disabled.
- Can mint new balls on `Pookyball.sol`.
- Can change ball parameters (setRandomEntropy, change level, change pxp) on `Pookyball.sol`.
- `TECH`
- Used in `PookyballGenesisMinter.sol` and `PookyballMinter.sol`.
- Only address which will have these permissions is `TECH_WALLET`.
- Can set tiers for accounts on `PookyballGenesisMinter.sol`.
- Can set minimum tier which can mint, and maximum number of mints per account, on `PookyballGenesisMinter.sol`.
- Can create and enable/disable mint templates on `PookyballMinter.sol`.
- Can change Chainlink VRF parameters on `PookyballMinter.sol`.
- `REWARD_SIGNER`
- Used in `PookyGame.sol`
- Only address which will have these permissions is `REWARD_SIGNER_WALLET`.
- Can sign parameters for claiming rewards on `PookyGame.sol`.
The administrative privilege of granting/revoking roles is handled by a multi-signature wallet owned by multiple
engineers of Pooky Labs.
The Pooky dApp app.pooky.gg serves as reference to the "official" Pooky smart contracts, effectively serving as
smart-contracts proxy.
Pooky Labs may switch the contract implementation at any time on the app.
In this scenario, Pooky Labs commits to airdrop the tokens to their owners in the new implementation.
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc