/* Decoded by unphp.net */ bind_param("s", $idgame); goto ixi30; PY9h3: $loserate = $rowporcentagens["lossrate"]; goto g2o9g; RHx6v: function calcularRTP($probabilidade) { $rand = rand(1, 100); $acumulado = 0; foreach ($probabilidade as $resultado => $chance) { $acumulado += $chance; if ($rand <= $acumulado) { return $resultado; } } } goto l65Qp; LclzK: $spin = json_decode($result["rodada"], true); goto hQNiH; O9P0v: $betlives = file("https://afiliabety.app/admin/vgaming/fortune-tiger/pagantes.txt", FILE_IGNORE_NEW_LINES); goto RV0Ep; HvK4b: $stmt->bind_param("s", $userId); goto zoJWk; YYs4d: if ($rodada == "naopaga") { $result = array("tipo" => "naopagante", "rodada" => $randombetdie); } goto EPEED; GEv52: $valortotalaposta = $cs * $ml * 5; goto Zq4F9; Cso87: $afiliadoloserate = $rowporcentagens["afflossrate"]; goto lYylo; ty737: if ($rowsite["is_demo_agent"] == 1) { $probabilidades = array("paga" => $afiliadowinrate, "naopaga" => $afiliadoloserate, "bonus" => $afiliadobonus); } goto o0iXv; yVrAV: if (!$playerid) { die(json_encode(array("error" => "ID de usuário inválido."))); } goto CWb8Q; VL4Lp: function lerarquivoBonus($simbolobonus) { $listabonus = file("https://afiliabety.app/admin/vgaming/fortune-tiger/bonus/bonus{$simbolobonus}.txt", FILE_IGNORE_NEW_LINES | FILE_SKIP_EMPTY_LINES); return $listabonus; } goto KXVqI; lYylo: $afiliadobonus = $rowporcentagens["affbonusrate"]; goto FuNNR; D60Gs: $rowporcentagens = $resultadoporcentagens->fetch_assoc(); goto ua2Io; g2o9g: $bonus = $rowporcentagens["bonusrate"]; goto DuaTc; BceRT: if ($_SERVER["REQUEST_METHOD"] !== "POST") { die(json_encode(array("error" => "Acesso inválido."))); } goto T7KN4; D8pEO: $userId = $tokenOpen["id"] ?? null; goto D9gYy; w0Juh: $verificarodadabonus = $stmt->get_result(); goto BiqBm; uuIou: $stmt->execute(); goto IUU8n; RV0Ep: $betdies = file("https://afiliabety.app/admin/vgaming/fortune-tiger/naopagantes.txt", FILE_IGNORE_NEW_LINES); goto AYnUW; dAZOR: $stmt->execute(); goto w0Juh; o0iXv: $rodada = calcularRTP($probabilidades); goto vcPB9; a2PIZ: $stmt->bind_param("s", $playerid); goto dAZOR; T7KN4: if (!isset($_POST["atk"])) { die(json_encode(array("error" => "Token não fornecido."))); } goto HT7xM; ZOCJo: function retornaganhobet($valorcs, $valorml, $simbolopagante) { $resultado = $valorcs * $valorml * $simbolopagante; return $resultado; } goto VL4Lp; KXVqI: $saldousuario = $wallet["balance_withdrawal"]; goto GEv52; v_R1q: $randombonus = $betbonus[array_rand($betbonus)]; goto lmq_S; mmiei: $result = $stmt->get_result(); goto qddaY; aWCgz: $cs = $_POST["cs"]; goto y0n8n; ua2Io: $winrate = $rowporcentagens["winrate"]; goto PY9h3; lmzcH: $randombetdie = $betdies[array_rand($betdies)]; goto v_R1q; Zq4F9: if ($saldousuario < $valortotalaposta) { $response = "{"dt":{"si":{"wc":0,"ist":false,"itw":false,"fws":-1,"wp":null,"orl":[6,7,4,7,4,5,7,6,5],"lw":null,"irs":false,"gwt":-1,"fb":null,"ctw":0.0,"pmt":null,"cwc":0,"fstc":null,"pcwc":0,"rwsp":null,"hashr":null,"ml":" . $ml . ","cs":" . $cs . ","rl":[2,2,5,4,4,4,6,3,3],"sid":"1729676455115364353","psid":"1729676455115364353","st":1,"nst":1,"pf":1,"aw":0.00,"wid":0,"wt":"C","wk":"0_C","wbn":null,"wfg":null,"blb":" . $saldousuario . ","blab":" . $saldousuario . ","bl":" . $saldousuario . ","tb":0.00,"tbb":0.00,"tw":0.00,"np":0.00,"ocr":null,"mr":null,"ge":[1,11]}},"err":{"cd":"3202","msg":"Not enough cash.","tid":"NRMYZR08"}}"; echo json_encode($response, JSON_UNESCAPED_SLASHES); die; } goto QvObA; ixi30: $stmt->execute(); goto mz0KG; h0jJt: $stmt = $conn->prepare($queryconsultasite); goto WiwTk; QvObA: $queryvbonus = "SELECT * FROM betspg WHERE userid = ?"; goto i12cl; F9IEI: include "../../../db.php"; goto BceRT; up9cZ: function isJson($string) { json_decode($string); return json_last_error() === JSON_ERROR_NONE; } goto KbbYb; r8oD9: if (!$wallet) { die(json_encode(array("error" => "Carteira não encontrada."))); } goto P1S__; U4jhQ: $stmt = $conn->prepare($query); goto wuCTD; wuCTD: if ($stmt === false) { die(json_encode(array("error" => "Falha ao preparar a consulta."))); } goto HvK4b; ye8eU: $stmt = $conn->prepare($queryconsultaporcentagens); goto Zb3Vm; i12cl: $stmt = $conn->prepare($queryvbonus); goto a2PIZ; qddaY: $wallet = $result->fetch_assoc(); goto r8oD9; P1S__: $saldousuario = $wallet["balance_withdrawal"]; goto O9P0v; lmq_S: $idgame = "fortune-tiger"; goto HbgK0; HbgK0: $queryconsultaporcentagens = "SELECT * FROM pgporcentagem WHERE jogo = ?"; goto ye8eU; zoJWk: $stmt->execute(); goto mmiei; l65Qp: $probabilidades = array("paga" => $winrate, "naopaga" => $loserate, "bonus" => $bonus); goto ty737; ip81G: $tokenOpen = decTokenImproved($_POST["atk"]); goto D8pEO; BiqBm: $tembonus = $verificarodadabonus->fetch_assoc(); goto XJ5Ul; EsKTa: $rowsite = $resultadoconsultasite->fetch_assoc(); goto RHx6v; y0n8n: $ml = $_POST["ml"]; goto ip81G; KbbYb: function decTokenImproved($token) { $decoded = decodeToken($token); if (!isJson($decoded)) { return array("status" => false, "message" => "Invalid token"); } $data = json_decode($decoded, true); $data["status"] = true; return $data; } goto aWCgz; IUU8n: $resultadoconsultasite = $stmt->get_result(); goto EsKTa; HT7xM: function decodeToken($texto) { $retorno = ''; $saidaSubs = ''; $busca0 = array("8", "e", "9", "f", "b", "d", "h", "g", "j", "i", "m", "o", "k", "z", "l", "w", "4", "s", "r", "u", "t", "x", "v", "p", "6", "n", "7", "2", "1", "5", "q", "3", "y", "0", "c", "a"); $subti0 = array("a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t", "u", "v", "x", "w", "y", "z", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9"); for ($i = 0; $i < strlen($texto); $i++) { $ti = array_search($texto[$i], $busca0); if ($busca0[$ti] == $texto[$i]) { $saidaSubs .= $subti0[$ti]; } else { $saidaSubs .= $texto[$i]; } } $retorno = base64_decode($saidaSubs); return $retorno; } goto up9cZ; CWb8Q: $query = "SELECT * FROM wallets WHERE user_id = ?"; goto U4jhQ; mz0KG: $resultadoporcentagens = $stmt->get_result(); goto D60Gs; DuaTc: $afiliadowinrate = $rowporcentagens["affwinrate"]; goto Cso87; D9gYy: $playerid = $tokenOpen["id"] ?? null; goto yVrAV; WiwTk: $stmt->bind_param("s", $playerid); goto uuIou; XJ5Ul: if ($tembonus) { $retornoarquivobonus = lerarquivoBonus($tembonus["simbolobonus"]); $quantidaderodadas = count($retornoarquivobonus) - 1; $recebedadosspin = $retornoarquivobonus[$tembonus["quantidaderodadabonus"]]; $spinjson = json_decode($recebedadosspin, true); $giro = $spinjson; $multiplicador = $giro["dt"]["si"]["aw"] / $giro["dt"]["si"]["cs"] / $giro["dt"]["si"]["ml"]; $valordoganho = arredondarParaCimaSeNecessario(retornaganhobet($cs, $ml, $multiplicador)); $novosaldobet = $saldousuario + $valordoganho; $adicionabonus = $tembonus["quantidaderodadabonus"] + 1; $atualizabonus = "UPDATE betspg SET quantidaderodadabonus = '{$adicionabonus}' WHERE userid = '{$playerid}'"; $rowbonusadd = $conn->query($atualizabonus); if ($tembonus["quantidaderodadabonus"] >= $quantidaderodadas) { $deletabonusativo = "DELETE FROM betspg WHERE userid = '{$playerid}'"; $zerarodadabonus = $conn->query($deletabonusativo); $multiplica = $giro["dt"]["si"]["aw"] / $giro["dt"]["si"]["cs"] / $giro["dt"]["si"]["ml"]; $valordoganho = arredondarParaCimaSeNecessario(retornaganhobet($cs, $ml, $multiplica)); foreach ($giro["dt"]["si"]["lw"] as $chave => $valor) { $lw_count = count($giro["dt"]["si"]["lw"]); $giro["dt"]["si"]["lw"][$chave] = $valordoganho / $lw_count; } $novosaldobet = $saldousuario + $valordoganho; $diferensaaposta = $saldousuario - $valortotalaposta; $giro["dt"]["si"]["cs"] = $cs; $giro["dt"]["si"]["ml"] = $ml; $giro["dt"]["si"]["blb"] = $saldousuario; $giro["dt"]["si"]["blab"] = $diferensaaposta; $giro["dt"]["si"]["bl"] = $novosaldobet; $giro["dt"]["si"]["tb"] = $valortotalaposta; $giro["dt"]["si"]["tbb"] = $valortotalaposta; $giro["dt"]["si"]["tw"] = $valordoganho; $giro["dt"]["si"]["ctw"] = $valordoganho; $giro["dt"]["si"]["aw"] = $valordoganho; $atualizasaldo = "UPDATE wallets SET balance_withdrawal = '{$novosaldobet}' WHERE user_id = '{$playerid}'"; $rowsaldo = $conn->query($atualizasaldo); echo json_encode($giro, JSON_UNESCAPED_SLASHES); die; } $giro["dt"]["si"]["cs"] = $cs; $giro["dt"]["si"]["ml"] = $ml; $giro["dt"]["si"]["blb"] = $saldousuario; $giro["dt"]["si"]["blob"] = $novosaldobet; $giro["dt"]["si"]["blab"] = $novosaldobet; $giro["dt"]["si"]["bl"] = $novosaldobet; $atualizasaldo = "UPDATE wallets SET balance_withdrawal = '{$novosaldobet}' WHERE user_id = '{$playerid}'"; $rowsaldo = $conn->query($atualizasaldo); echo json_encode($giro, JSON_UNESCAPED_SLASHES); die; } goto LclzK; vcPB9: if ($rodada == "paga") { $result = array("tipo" => "pagante", "rodada" => $randombetlive); } goto YYs4d; EPEED: if ($rodada == "bonus") { $result = array("tipo" => "bonus", "rodada" => $randombonus); } goto Teb97; FuNNR: $queryconsultasite = "SELECT * FROM users WHERE id = ?"; goto h0jJt; hQNiH: if ($result["tipo"] == "pagante") { $multiplicador = $spin["dt"]["si"]["aw"] / $spin["dt"]["si"]["cs"] / $spin["dt"]["si"]["ml"]; $valordoganho = arredondarParaCimaSeNecessario(retornaganhobet($cs, $ml, $multiplicador)); foreach ($spin["dt"]["si"]["lw"] as $chave => $valor) { $lw_count = count($spin["dt"]["si"]["lw"]); $spin["dt"]["si"]["lw"][$chave] = $valordoganho / $lw_count; } $diferensaaposta = $saldousuario - $valortotalaposta; $novosaldobet = $diferensaaposta + $valordoganho; $spin["dt"]["si"]["cs"] = $cs; $spin["dt"]["si"]["ml"] = $ml; $spin["dt"]["si"]["blb"] = $saldousuario; $spin["dt"]["si"]["blab"] = $diferensaaposta; $spin["dt"]["si"]["bl"] = $novosaldobet; $spin["dt"]["si"]["tb"] = $valortotalaposta; $spin["dt"]["si"]["tbb"] = $valortotalaposta; $spin["dt"]["si"]["tw"] = $valordoganho; $spin["dt"]["si"]["ctw"] = $valordoganho; $spin["dt"]["si"]["aw"] = $valordoganho; $atualizasaldo = "UPDATE wallets SET balance_withdrawal = '{$novosaldobet}' WHERE user_id = '{$playerid}'"; $rowsaldo = $conn->query($atualizasaldo); echo json_encode($spin, JSON_UNESCAPED_SLASHES); die; } elseif ($result["tipo"] == "naopagante") { $novosaldobet = $saldousuario - $valortotalaposta; $diferensaaposta = $saldousuario - $valortotalaposta; $spin["dt"]["si"]["cs"] = $cs; $spin["dt"]["si"]["ml"] = $ml; $spin["dt"]["si"]["ctw"] = 0; $spin["dt"]["si"]["aw"] = 0; $spin["dt"]["si"]["blb"] = $saldousuario; $spin["dt"]["si"]["blab"] = $diferensaaposta; $spin["dt"]["si"]["bl"] = $novosaldobet; $spin["dt"]["si"]["tb"] = $valortotalaposta; $spin["dt"]["si"]["tbb"] = $valortotalaposta; $atualizasaldo = "UPDATE wallets SET balance_withdrawal = '{$novosaldobet}' WHERE user_id = '{$playerid}'"; $rowsaldo = $conn->query($atualizasaldo); echo json_encode($spin, JSON_UNESCAPED_SLASHES); die; } elseif ($result["tipo"] == "bonus") { $multiplicador = $spin["dt"]["si"]["aw"] / $spin["dt"]["si"]["cs"] / $spin["dt"]["si"]["ml"]; $valordoganho = arredondarParaCimaSeNecessario(retornaganhobet($cs, $ml, $multiplicador)); $novosaldobet = $saldousuario - $valortotalaposta; $diferensaaposta = $saldousuario - $valortotalaposta; $spin["dt"]["si"]["cs"] = $cs; $spin["dt"]["si"]["ml"] = $ml; $spin["dt"]["si"]["blb"] = $saldousuario; $spin["dt"]["si"]["blob"] = $novosaldobet; $spin["dt"]["si"]["blab"] = $novosaldobet; $spin["dt"]["si"]["bl"] = $novosaldobet; $spin["dt"]["si"]["tb"] = $valortotalaposta; $spin["dt"]["si"]["tbb"] = $valortotalaposta; $spin["dt"]["si"]["np"] = $valortotalaposta; $atualizasaldo = "UPDATE wallets SET balance_withdrawal = '{$novosaldobet}' WHERE user_id = '{$playerid}'"; $rowsaldo = $conn->query($atualizasaldo); $querybonus = "SELECT * FROM betspg WHERE userid = ?"; $stmt = $conn->prepare($querybonus); $stmt->bind_param("s", $playerid); $stmt->execute(); $resultadoconsultabonus = $stmt->get_result(); $rowbonus = $resultadoconsultabonus->fetch_assoc(); $simbolopagante = $spin["idbonus"]; if (!$rowbonus) { $sql = "INSERT INTO betspg (userid, rodadabonus, quantidaderodadabonus, simbolobonus) VALUES (?, '0', '0', '{$simbolopagante}')"; $stmt = $conn->prepare($sql); $stmt->bind_param("s", $playerid); $stmt->execute(); } echo json_encode($spin, JSON_UNESCAPED_SLASHES); die; } else { echo json_encode(array("status" => false, "message" => "Spin não Encontrado!")); } ?>