Working with SushiSwap MasterChef Contract trying to add Capped Token

As said in the title, I am trying to create my own template for SushiSwap MasterChef. But I want SUSHI to be an ERC20Capped, in order to establish a maxCap of for example (1B). For this I’ve modified the SushiToken.sol and the main changes look like this:

pragma solidity ^0.6.0;



contract SushiToken is ERC20, ERC20Capped {

constructor ()


ERC20 (“MyTok”, “MT”)

ERC20Capped (1000000000 * (10** uint256 (18)))


//*! _mint(msg.sender, 1000000 * (10** uint256 (decimals())));



Then my doubt is where can I set a controller or at leat locate where the MasterChef Smart Contract distributes the SUSHI tokens in order to check before calling the MINT() function. As MasterChef is an already known contract I would really appreciate if you could just tell me the function where the magic happens so I can check the ERC20.cap() from the ERC20Capped Library.

Thanks in advance

1 Like