mahdiyar30301/ZorenixAI_botPublic · Bot Template

Not Bot Is Hacking You 🤣🤩

Utilityutility
ProfileTelegram
455 commands2 envUpdated 7h agoCreated Aug 26, 2026
Back to folder

commands/gcz.js

javascript · 42 lines

Raw
1/**#command2name: gcz3answer: 4keyboard: 5parse_mode: markdown6aliases: 7allow_only_group: false8need_reply: false9is_web: 010#command**/11 12/**#command13name: gcz14answer: 15keyboard: 16parse_mode: markdown17aliases: 18allow_only_group: false19need_reply: false20is_web: 021#command**/22 23try {24var uid = "";25if (typeof user !== "undefined" && user) {26  if (user.telegramid) uid = String(user.telegramid);27  else if (user.id) uid = String(user.id);28}29if (!uid) return;30var raw = "";31if (typeof params !== "undefined" && params) raw = String(params).trim().toUpperCase().replace(/[^A-Z0-9]/g, "");32if (!raw) { Bot.sendMessage("کد هدیه کوین:\n/gcz کد"); return; }33var toman = parseInt(await db.global.get("gcz_" + raw) || 0) || 0;34if (toman < 1) { Bot.sendMessage("کد نامعتبر."); return; }35if (await db.global.get("gczu_" + uid + "_" + raw)) { Bot.sendMessage("این کد را قبلاً زدی."); return; }36await db.global.set("gczu_" + uid + "_" + raw, "1");37var bal = parseInt(await db.global.get("wal_" + uid) || 0) || 0;38await db.global.set("wal_" + uid, bal + toman);39Bot.sendMessage("🎁 +" + (toman / 100) + " ZC\nکیف: " + ((bal + toman) / 100) + " ZC");40} catch (e) {41  Bot.sendMessage("خطا gcz");42}