Welcome, Guest
You have to register before you can post on our site.

Username
  

Password
  





Search Forums



(Advanced Search)

Forum Statistics
» Members: 6,509
» Latest member: crazyosman365
» Forum threads: 2,233
» Forum posts: 12,033

Full Statistics

Online Users
There are currently 350 online users.
» 1 Member(s) | 347 Guest(s)
Bing, Google, crazyosman365

Latest Threads
Command does not work in-...
Forum: Pawn Scripting
Last Post: PANZEHIR_
2024-11-23, 06:36 PM
» Replies: 0
» Views: 36
White Screen
Forum: Support
Last Post: Phat202146_real
2024-11-21, 02:50 PM
» Replies: 0
» Views: 32
I get error 021 using y_h...
Forum: Pawn Scripting
Last Post: daniscript18
2024-11-18, 11:34 PM
» Replies: 0
» Views: 51
Il reste des français sur...
Forum: French/Fran?ais
Last Post: tysanio
2024-11-18, 05:39 AM
» Replies: 2
» Views: 455
Object creation issues
Forum: Programming
Last Post: K1271
2024-11-15, 11:51 PM
» Replies: 0
» Views: 52
Is the SAMP Hosting the s...
Forum: General Discussions
Last Post: OperaGX
2024-11-14, 09:33 PM
» Replies: 0
» Views: 69
Run time error 19: "File ...
Forum: Pawn Scripting
Last Post: Rexey
2024-11-14, 03:50 AM
» Replies: 0
» Views: 59
How to Compile Your Gamem...
Forum: Tutorials
Last Post: thelante
2024-11-13, 08:50 AM
» Replies: 3
» Views: 456
Modeller wanted
Forum: Development Updates
Last Post: acc.gangbeni
2024-11-11, 05:10 PM
» Replies: 9
» Views: 16,469
SA:MP forum offline
Forum: Portuguese/Portugu?s
Last Post: weslley_script
2024-11-09, 05:27 PM
» Replies: 7
» Views: 9,907

 
Question Best Practices for MySQL Native Functions?
Posted by: dr.iyz - 2024-02-03, 04:09 AM - Forum: Pawn Scripting - Replies (1)

I'm using BlueG's MySQL plugin version R41-4 and MySQL 8.0.35 on my Ubuntu 22.04.
Every hour, the RAM usage of my mysqld process slowly increases. I have running queries every minute to update business earnings, and at this point, I assume that the problem is due to these minute-by-minute updates.

So, my question is, what is the best MySQL native function for this case? Currently, I'm using mysql_query to update every minute.
Honestly, I also use mysql_query for all queries in my script, and I'm unsure when to use mysql_tquery or mysql_pquery.

I'm also curious about why the RAM usage of my mysqld process always increases?


  Help crash
Posted by: nbx2000 - 2024-02-02, 05:46 AM - Forum: Pawn Scripting - Replies (1)

i am having problems with this function. crashdetect flagged this for me
[debug] AMX backtrace:
[debug] #0 00002774 in ?? (4016892) in XAF.amx
[debug] #1 00002dd4 in ?? (0, 4016892, 5000, 3) in XAF.amx
[debug] #2 001e3734 in public Timer1minute (0) in XAF.amx


Code:
ptask Timer1minute[60000](i) {
    if (JugadorInfo[i][zLogueado] == true) {
        // Verifica si el jugador quiere ver los textos
        if (JugadorInfo[i][zVerTextos][1] == 1) {
            ServerInfo[AnuncioTextoCmds]++;
            if (ServerInfo[AnuncioTextoCmds] == 3) ServerInfo[AnuncioTextoCmds] = 1;
            switch (ServerInfo[AnuncioTextoCmds]) {
                case 1: PlayerTextDrawSetString(i, InfoDeCmds, "");
                case 2: PlayerTextDrawSetString(i, InfoDeCmds, "");
                case 3: PlayerTextDrawSetString(i, InfoDeCmds, "");
            }
            PlayerTextDrawShow(i, InfoDeCmds);
        }
        // Incrementa el tiempo del jugador
        JugadorInfo[i][zMiTiempo]++;
        JugadorInfo[i][zTimeMiRango]++;
        // Actualiza la base de datos con el nuevo tiempo
        static Query[180];
        format(Query, sizeof(Query), "UPDATE `USERS` SET TIEMPO = '%d', TRG = '%d' WHERE `ID` = '%d' COLLATE NOCASE", JugadorInfo[i][zMiTiempo], JugadorInfo[i][zTimeMiRango], JugadorInfo[i][zMiID]);
        db_query(ZLDB, Query);

        // Verifica las caducidades para el VIP y el rango
        VerificarCaducidadVip(i);
        VerificarCaducidadRango(i);

        // Incrementa el tiempo del staff si es administrador
        if (JugadorInfo[i][zAdmin] > 0 && JugadorInfo[i][zAfk] < 3) {
            JugadorInfo[i][zTiempoStaff]++;
            static Query2[150];
            format(Query2, sizeof(Query2), "UPDATE `USERS` SET TIMESTAFF = '%d' WHERE `ID` = '%d' COLLATE NOCASE", JugadorInfo[i][zTiempoStaff], JugadorInfo[i][zMiID]);
            db_query(ZLDB, Query2);
        }

        // Incrementa el tiempo de juego si el jugador no está AFK
        if (JugadorInfo[i][zAfk] < 3) {
            JugadorInfo[i][zPlayTiempo]++;
            static Query2[150];
            format(Query2, sizeof(Query2), "UPDATE `USERS` SET PLAYTIME = '%d' WHERE `ID` = '%d' COLLATE NOCASE", JugadorInfo[i][zPlayTiempo], JugadorInfo[i][zMiID]);
            db_query(ZLDB, Query2);
        }

        // Verifica el tiempo de juego reclamado
        if (JugadorInfo[i][zPlayReclamado] == 0) VerificarPlayTime(i);

        // Verifica si el jugador está encarcelado
        if (JugadorInfo[i][zJailed] == 1) {
            JugadorInfo[i][zJailTime]--;
            format(Query, sizeof(Query), "UPDATE `USERS` SET TIMEJAIL = '%d' WHERE `ID` = '%d' COLLATE NOCASE", JugadorInfo[i][zJailTime], JugadorInfo[i][zMiID]);
            db_query(ZLDB, Query);
            if (JugadorInfo[i][zJailTime] <= 0) JailRelease(i);
        }

        // Manejo de items
        // Score Free Kill
        if (JugadorInfo[i][zScoreFreeKill] == 1) {
            JugadorInfo[i][zTScoreFreeKill]--;
            format(Query, sizeof(Query), "UPDATE `USERS` SET TIMESCFREE = '%d' WHERE `ID` = '%d' COLLATE NOCASE", JugadorInfo[i][zTScoreFreeKill], JugadorInfo[i][zMiID]);
            db_query(ZLDB, Query);
            if (JugadorInfo[i][zTScoreFreeKill] <= 0) {
                format(Query, sizeof(Query), "UPDATE `USERS` SET TIMESCFREE = '0', SCFREE = '0' WHERE `ID` = '%d' COLLATE NOCASE", JugadorInfo[i][zMiID]);
                db_query(ZLDB, Query);
                JugadorInfo[i][zTScoreFreeKill] = 0;
                JugadorInfo[i][zScoreFreeKill] = 0;
                SendClientMessage(i, COLOR_ROJO, "« Info » "COL_BLANCO"Tu item score freeroam kill ha sido desactivado (tiempo finalizado), vuélvelo a comprar desde tu panel.");
            }
        }

        // Armour Spawn
        if (JugadorInfo[i][zArmourSpawn] == 1) {
            JugadorInfo[i][zTArmourSpawn]--;
            format(Query, sizeof(Query), "UPDATE `USERS` SET TIMEARSPW = '%d' WHERE `ID` = '%d' COLLATE NOCASE", JugadorInfo[i][zTArmourSpawn], JugadorInfo[i][zMiID]);
            db_query(ZLDB, Query);
            if (JugadorInfo[i][zTArmourSpawn] <= 0) {
                format(Query, sizeof(Query), "UPDATE `USERS` SET TIMEARSPW = '0', ARSPW = '0' WHERE `ID` = '%d' COLLATE NOCASE", JugadorInfo[i][zMiID]);
                db_query(ZLDB, Query);
                JugadorInfo[i][zTArmourSpawn] = 0;
                JugadorInfo[i][zArmourSpawn] = 0;
                SendClientMessage(i, COLOR_ROJO, "« Info » "COL_BLANCO"Tu item armour spawn ha sido desactivado (tiempo finalizado), vuélvelo a comprar desde tu panel.");
            }
        }

        // Volar (Fly)
        if (JugadorInfo[i][zVolar] == 1) {
            JugadorInfo[i][zTimeVolar]--;
            format(Query, sizeof(Query), "UPDATE `USERS` SET TIMEFLY = '%d' WHERE `ID` = '%d' COLLATE NOCASE", JugadorInfo[i][zTimeVolar], JugadorInfo[i][zMiID]);
            db_query(ZLDB, Query);
            if (JugadorInfo[i][zTimeVolar] <= 0) {
                format(Query, sizeof(Query), "UPDATE `USERS` SET TIMEFLY = '0', FLY = '0' WHERE `ID` = '%d' COLLATE NOCASE", JugadorInfo[i][zMiID]);
                db_query(ZLDB, Query);
                JugadorInfo[i][zTimeVolar] = 0;
                JugadorInfo[i][zVolar] = 0;
                if (JugadorInfo[i][zEnVuelo] == true) {
                    SendClientMessage(i, COLOR_ROJO, "« Info » "COL_BLANCO"Vuelo finalizado.");
                    JugadorInfo[i][zEnVuelo] = false;
                    StopFly(i);
                    GameTextForPlayer(i, "~b~Vuelo ~g~Finalizado", 6000, 3);
                }
                SendClientMessage(i, COLOR_ROJO, "« Info » "COL_BLANCO"Tu item vuelo ha sido desactivado (tiempo finalizado), vuélvelo a comprar desde tu panel.");
            }
        }

        // Teleport Click
        if (JugadorInfo[i][zTeleP] == 1) {
            JugadorInfo[i][zTimeTeleP]--;
            format(Query, sizeof(Query), "UPDATE `USERS` SET TIMETELE = '%d' WHERE `ID` = '%d' COLLATE NOCASE", JugadorInfo[i][zTimeTeleP], JugadorInfo[i][zMiID]);
            db_query(ZLDB, Query);
            if (JugadorInfo[i][zTimeTeleP] <= 0) {
                format(Query, sizeof(Query), "UPDATE `USERS` SET TIMETELE = '0', TELE = '0' WHERE `ID` = '%d' COLLATE NOCASE", JugadorInfo[i][zMiID]);
                db_query(ZLDB, Query);
                JugadorInfo[i][zTimeTeleP] = 0;
                JugadorInfo[i][zTeleP] = 0;
                SendClientMessage(i, COLOR_ROJO, "« Info » "COL_BLANCO"Tu item teleport click ha sido desactivado (tiempo finalizado), vuélvelo a comprar desde tu panel.");
            }
        }
    }
    return 1;
}


  Game randomly closing
Posted by: Krisitis - 2024-02-01, 08:01 PM - Forum: Support - No Replies

Hello!

So I've been trying to use Steam version of GTA San Andreas by downgrading it to 1.0 and doing other stuff for it to work smoothly. The game itself on single player works fine, but once I play SA-MP for like an hour, game just randomly closes without even giving any errors.

Any idea what is that?


  crashdetect is crashing my server?
Posted by: CJ101 - 2024-01-31, 07:50 PM - Forum: Support - No Replies

I want to use crashdetect , but it just crashes my server

[19:41:27] [Info] [debug] Server crashed while executing rxv4.amx
[19:41:27] [Info] [debug] AMX backtrace:
[19:41:27] [Info] [debug] #0 00000f70 in ?? () in rxv4.amx
[19:41:27] [Info] [debug] #1 000025b4 in public OnGameModeInit () in rxv4.amx

[19:41:27] [ERROR] signal 11 (SIGSEGV) catched; shutting log-core down (errno: 0, signal code: 1, exit status: 0)

I am loading it as the first plugin

the error is not my script, i commented out all of GameModeInit and still the same.

Using plugins:

streamer, discordconnector, and mysql . all updated to latest version


Question How do you create a spawn selector?
Posted by: julio-jered - 2024-01-30, 08:52 PM - Forum: Support - Replies (1)

I'm rather new to SA-MP scripting, but I'm trying to make a selector for spawnpoints (like the class one).
Does anyone know how? I've had a hard time finding it online.


  Busco dearolladores para server
Posted by: lucasstar1442 - 2024-01-30, 08:08 PM - Forum: Programaci?n - No Replies

Buenas soy Sr.Zeppelin, 

Estoy buscando gente que quiera formar parte en mi nuevo proyecto y que pueda plasmar mis ideas en un servidor roleplay en SAMP, toda ayuda o colaboración (Con remuneración)  contactar conmigo por discord: Sr.Zeppelin


  Compile all files in gamemode folder
Posted by: JasonDeRue - 2024-01-29, 01:59 PM - Forum: Pawn Scripting - Replies (2)

Hello, I'm using this build system for Sublime Text to compile my gamemode:

Code:
{
"cmd": ["pawncc.exe", "-i includes", "$file", "-;+", "-v2", "-d3", "-Z+", "-\\)+"],
"path": "C:/Users/*****/Desktop/Server/pawno"
}


Imagine now I have 2 different files in gamemode folder that I want to compile at same time, how I can do it?


Exclamation Looking for a dialog include!
Posted by: nerdplaytuturias231 - 2024-01-29, 02:53 AM - Forum: Questions and Suggestions - No Replies

Encontrei a inclusão que eu estava procurando. Se possível, por favor, exclua este post.


Star Elevate Your GTA San Andreas Multiplayer Experience with OXY.Games Hosting! 🚗💨
Posted by: rz@google - 2024-01-27, 12:17 AM - Forum: General Discussions - No Replies

Hey GTA legends! 🎮

Are you ready to take your San Andreas adventures to the next level? We've got just the thing for you - OXY.Games now offers premium SA-MP server hosting with Open.MP! 🌐

Why choose OXY.Games for your SA-MP server? Here's the lowdown:

Instant Server Setup: Get your server up and running in no time! ⏱️
Top-Notch Hardware: Experience smooth gameplay with high-performance hardware. 🖥️
DDoS Protection: Enjoy uninterrupted play with top-tier security. 🛡️
Full Control: Manage your server with ease using our user-friendly control panel. 🕹️
Global Servers: Low latency gameplay, no matter where you are. 🌍
24/7 Support: Got a question? Our gamer-friendly team is here to help! 🤝
And that's just the beginning! With OXY.Games, you're not just hosting a server; you're creating an epic GTA experience. 🌆

Ready to dominate the streets of San Andreas? Check out link below and start your SA-MP journey today! 🏁
https://oxy.games/game-servers/gta-san-a...ge=english
Same page in Dutch: https://oxy.games/game-servers/gta-san-a...uage=dutch

Starting from €3,20/month for plenty of resources (and unlimited slots!) for an amazing dedicated SA-MP Open.MP server experience (2 GB RAM, 20 GB SSD NVMe, DDoS Protection included).

Let's make those San Andreas dreams a reality! 🎉

[Image: oxy_logo_for_openmpforum_V2.png]

PS: admin/moderators, I found only one relevant category where to post this, if you think this is not the right place feel free to replace.


  Issue using y_iterator
Posted by: CJ101 - 2024-01-23, 01:07 AM - Forum: Pawn Scripting - Replies (1)

PHP Code:
C:\Users\jdawg\OneDrive\Desktop\server folder\pawno\include\YSI_Data\y_foreach\..\..\YSI_Core\y_core\y_samp_natives.inc(162) : error 035argument type mismatch (argument 1)
C:\Users\jdawg\OneDrive\Desktop\server folder\pawno\include\YSI_Data\y_foreach\..\..\YSI_Core\y_core\..\..\YSI_Players\y_android\..\..\YSI_Core\y_core\y_rconfix.inc(125) : error 035argument type mismatch (argument 1)
Pawn compiler 3.2.3664 Copyright (c1997-2006ITB CompuPhase 


At the top of my script I am including
#include <YSI_Data\y_iterate>
like i should