From fc1db767336c80b4a155e168d070cf7ae0ddba71 Mon Sep 17 00:00:00 2001 From: Sewmina Date: Sat, 7 Sep 2024 23:17:39 +0530 Subject: [PATCH] tweaks --- GameData.sol | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/GameData.sol b/GameData.sol index b23e277..a25b69f 100644 --- a/GameData.sol +++ b/GameData.sol @@ -87,6 +87,12 @@ contract GameData is ERC1155, Ownable, ERC1155Burnable { //----------User Management--------------------/ + uint256[] public userMintedIds; + function GetUserMintedIds() public view returns(uint256[] memory){ + return userMintedIds; + } + + function GetCurrentUserIndex() public view returns(uint256){ return nextUserId; } @@ -95,6 +101,7 @@ contract GameData is ERC1155, Ownable, ERC1155Burnable { require(msg.sender == operator || msg.sender == owner(), "Only the operator can do this"); _mint(newUserAddress, newUserId, 1, ""); + userMintedIds.push(newUserId); nextUserId++; } //------------------------------/