DAOFacet
DaoTransferred
DaoTreasuryTransferred
ForgeTransferred
UpdateCollateralModifiers
AddCollateralType
AddItemType
UpdateItemType
CreateHaunt
GrantExperience
AddWearableSet
UpdateWearableSet
ItemTypeMaxQuantity
GameManagerAdded
GameManagerRemoved
ItemManagerAdded
ItemManagerRemoved
WearableSlotPositionsSet
ItemModifiersSet
RemoveExperience
UpdateItemPrice
isGameManager
Query if an address is a game manager
Parameters
Name | Type | Description |
---|---|---|
_manager | address | Address to query |
Return Values
Name | Type | Description |
---|---|---|
[0] | bool | True if |
gameManagerBalance
Query the balance of a game manager
Parameters
Name | Type | Description |
---|---|---|
_manager | address | Address to query |
Return Values
Name | Type | Description |
---|---|---|
[0] | uint256 | Balance of game manager |
gameManagerRefreshTime
Query the refresh time of a game manager
Parameters
Name | Type | Description |
---|---|---|
_manager | address | Address to query |
Return Values
Name | Type | Description |
---|---|---|
[0] | uint256 | Refresh time of game manager |
setDao
Allow the Diamond owner or DAO to set a new Dao address and Treasury address
Parameters
Name | Type | Description |
---|---|---|
_newDao | address | New DAO address |
_newDaoTreasury | address | New treasury address |
setForge
Allow the Diamond owner or DAO to set a new Forge address
Parameters
Name | Type | Description |
---|---|---|
_newForge | address | New DAO address |
addCollateralTypes
Allow an item manager to add new collateral types to a haunt
If a certain collateral exists already, it will be overwritten
Parameters
Name | Type | Description |
---|---|---|
_hauntId | uint256 | Identifier for haunt to add the collaterals to |
_collateralTypes | struct AavegotchiCollateralTypeIO[] | An array of structs where each struct contains details about a particular collateral |
addItemManagers
Allow the Diamond owner or DAO to add item managers
Parameters
Name | Type | Description |
---|---|---|
_newItemManagers | address[] | An array containing the addresses that need to be added as item managers |
removeItemManagers
Allow the Diamond owner or DAO to remove item managers
Will throw if one of the addresses in _itemManagers
is not an item manager
Parameters
Name | Type | Description |
---|---|---|
_itemManagers | address[] | An array containing the addresses that need to be removed from existing item managers |
updateCollateralModifiers
Allow the Diamond owner or DAO to update the collateral modifiers of an existing collateral
Parameters
Name | Type | Description |
---|---|---|
_collateralType | address | The address of the existing collateral to update |
_modifiers | int16[6] | An array containing the new numeric traits modifiers which will be applied to collateral |
updateItemTypeMaxQuantity
Allow an item manager to increase the max quantity of an item
Will throw if the new maxquantity is less than the existing quantity
Parameters
Name | Type | Description |
---|---|---|
_itemIds | uint256[] | An array containing the identifiers of items whose quantites are to be increased |
_maxQuantities | uint256[] | An array containing the new max quantity of each item |
createHaunt
Allow the Diamond owner or DAO to create a new Haunt
Will throw if the previous haunt is not full yet
Parameters
Name | Type | Description |
---|---|---|
_hauntMaxSize | uint24 | The maximum number of portals in the new haunt |
_portalPrice | uint96 | The base price of portals in the new haunt(in $GHST) |
_bodyColor | bytes3 | The universal body color applied to NFTs in the new haunt |
CreateHauntPayload
createHauntWithPayload
allow an item manager to create a new Haunt, also uploagding the collateral types,collateral svgs,eyeshape types and eyeshape svgs all in one transaction
Parameters
Name | Type | Description |
---|---|---|
_payload | struct DAOFacet.CreateHauntPayload | A struct containing all details needed to be uploaded for a new Haunt |
mintItems
Allow an item manager to mint new ERC1155 items
Will throw if a particular item current supply has reached its maximum supply
Parameters
Name | Type | Description |
---|---|---|
_to | address | The address to mint the items to |
_itemIds | uint256[] | An array containing the identifiers of the items to mint |
_quantities | uint256[] | An array containing the number of items to mint |
grantExperience
Allow the DAO, a game manager or the aavegotchi diamond owner to grant XP(experience points) to multiple aavegotchis
recipients must be claimed aavegotchis
Parameters
Name | Type | Description |
---|---|---|
_tokenIds | uint256[] | The identifiers of the aavegotchis to grant XP to |
_xpValues | uint256[] | The amount XP to grant each aavegotchi |
removeExperience
Allow the DAO, a game manager or the aavegotchi diamond owner to remove XP(experience points) from multiple aavegotchis
recipients must be claimed aavegotchis
Parameters
Name | Type | Description |
---|---|---|
_tokenIds | uint256[] | The identifiers of the aavegotchis to grant XP to |
_xpValues | uint256[] | The amount XP to grant each aavegotchi |
addItemTypes
Allow an item manager to add item types
Parameters
Name | Type | Description |
---|---|---|
_itemTypes | struct ItemType[] | An array of structs where each struct contains details about each item to be added |
addItemTypesAndSvgs
Allow an item manager to add item types and their svgs
Parameters
Name | Type | Description |
---|---|---|
_itemTypes | struct ItemType[] | An array of structs where each struct contains details about each item to be added |
_svg | string | The svg to be added |
_typesAndSizes | struct LibSvg.SvgTypeAndSizes[] | An array of structs, each struct containing details about the item types and sizes |
updateItemTypes
Allow an item manager to update item types
Parameters
Name | Type | Description |
---|---|---|
_indices | uint256[] | An array of item id to be updated |
_itemTypes | struct ItemType[] | An array of structs where each struct contains details about each item to be updated |
addWearableSets
Allow an item manager to add a wearable set
Parameters
Name | Type | Description |
---|---|---|
_wearableSets | struct WearableSet[] | An array of structs, each struct containing the details about each wearableset to be added |
updateWearableSets
Allow an item manager to update existing wearablesets
Parameters
Name | Type | Description |
---|---|---|
_setIds | uint256[] | An array containing the identifiers of the wearablesets to be updated |
_wearableSets | struct WearableSet[] | An array oof structs,each struct representing the updated wearableset details |
addGameManagers
Allow the DAO or the aavegotchi diamond owner to add new game managers and their corresponding limits
Parameters
Name | Type | Description |
---|---|---|
_newGameManagers | address[] | An array containing the addresses to be added as game managers |
_limits | uint256[] | An array containing the corresponding limits applied to ech address in |
removeGameManagers
Allow the DAO or the aavegotchi diamond owner to remove existing game managers
It also resets the limit of each removed game manager to 0
Parameters
Name | Type | Description |
---|---|---|
_gameManagers | address[] | An array containing the addresses to be removed from existing game managers |
setWearableSlotPositions
Allow the DAO or the aavegotchi diamond owner to set the wearable slot position for a particular wearable
Parameters
Name | Type | Description |
---|---|---|
_wearableId | uint256 | The identifier of the wearable to change its slot position |
_slotPositions | bool[16] | An array of booleans pointing out where |
setItemTraitModifiersAndRarityModifier
Allow an item manager to set the trait and rarity modifiers of an item/wearable
Only valid for existing wearables
Parameters
Name | Type | Description |
---|---|---|
_wearableId | uint256 | The identifier of the wearable to set |
_traitModifiers | int8[6] | An array containing the new trait modifiers to be applied to a wearable with identifier |
_rarityScoreModifier | uint8 | The new rarityScore modifier of a wearable with identifier |
batchUpdateItemsPrice
Allow an item manager to set the price of multiple items in GHST
Only valid for existing items that can be purchased with GHST
Parameters
Name | Type | Description |
---|---|---|
_itemIds | uint256[] | The items whose price is to be changed |
_newPrices | uint256[] | The new prices of the items |