| Welcome, Guest |
You have to register before you can post on our site.
|
| Forum Statistics |
» Members: 7,698
» Latest member: n0mercyz
» Forum threads: 2,355
» Forum posts: 12,302
Full Statistics
|
| Online Users |
There are currently 242 online users. » 0 Member(s) | 239 Guest(s) Google, Bing, Applebot
|
| Latest Threads |
San Andreas Police Pursui...
Forum: Advertisements
Last Post: BriBri
Today, 12:06 AM
» Replies: 0
» Views: 26
|
[Include] OpenGate (Abrir...
Forum: Portuguese/Portugu?s
Last Post: Crazy_ArKzX
2025-11-13, 06:49 PM
» Replies: 0
» Views: 30
|
OpenGate (Open Proximity ...
Forum: Libraries
Last Post: Crazy_ArKzX
2025-11-13, 06:46 PM
» Replies: 0
» Views: 32
|
LS City Hall
Forum: Maps
Last Post: cosminupgaming
2025-11-12, 04:22 PM
» Replies: 3
» Views: 2,651
|
Crime Base
Forum: Maps
Last Post: cosminupgaming
2025-11-12, 04:19 PM
» Replies: 2
» Views: 1,246
|
GTA SA-MP Scripting: Issu...
Forum: General Discussions
Last Post: williamrhein
2025-11-12, 10:16 AM
» Replies: 0
» Views: 43
|
is it worth creating a se...
Forum: General Discussions
Last Post: cosminupgaming
2025-11-11, 05:30 PM
» Replies: 13
» Views: 18,313
|
Looking for an English De...
Forum: General Discussions
Last Post: cosminupgaming
2025-11-11, 05:21 PM
» Replies: 2
» Views: 2,803
|
Awakeninga an old server.
Forum: Support
Last Post: drwnrbbt
2025-11-11, 02:26 PM
» Replies: 0
» Views: 46
|
Starting a RP Server
Forum: General Discussions
Last Post: JakeFalcone
2025-11-11, 01:58 AM
» Replies: 0
» Views: 49
|
|
|
| Server lag |
|
Posted by: Hitler - 2021-03-24, 01:23 AM - Forum: Support
- Replies (1)
|
 |
Espa?ol:?Hola buenas, esto es solo dudas que tengo, sobre que era lo que ocasiona el lag en el servidor, anteriormente habia leido un post de forum samp sobre las razones del lag en el servidor, entre estas estaban:
- Mal uso de las celdas
- Plugins no actualizados
Esos recuerdo, alguien que me pueda decir m?s razones del lag en el servidor se lo agradecer?a
English:?Hello good, this is only doubts that I have, about what was causing the lag in the server, I had previously read a post on forum samp about the reasons for the lag in the server, among these were:
- Misuse of cells
- Plugins not updated
Those memories, someone who can tell me more reasons for the lag in the server would appreciate it
|
|
|
|
| GetPlayerCameraAspectRatio |
|
Posted by: robertocaribbean - 2021-03-23, 09:37 PM - Forum: Pawn Scripting
- Replies (2)
|
 |
Hello everyone.
I have read in the open.mp documentation about this function, and if I understand correctly it can only return three values:
Widescreen ON: Should be 1.7764707 but I get 1.000000.
Widescreen OFF: Should be 1.3333334 but I get 1.000000.
5:4 when the LETTERBOX mode is ON: 1.2470589. I don't know how to test this.
Is there something I'm not understanding or is the wiki wrong?
Here is the code:
PHP Code: public OnPlayerConnect(playerid) { ? ? new Float:pAspectRatio; ? ? pAspectRatio = GetPlayerCameraAspectRatio(playerid);
? ? new str[80]; ? ? format(str, sizeof(str), "Your aspect ratio is: %f", pAspectRatio); ? ? print(str); }
|
|
|
|
| [Solved] GetAnimationName() is not working properly |
|
Posted by: Radical - 2021-03-23, 08:43 PM - Forum: Pawn Scripting
- Replies (2)
|
 |
SOLUTION:
Store that animation lib and name in a variable.
e.g. :
Code: new rAnimLib[MAX_PLAYERS][20];
new rAnimName[MAX_PLAYERS][20];
COMMAND:anim(playerid, params[]) {
? ? ApplyAnimation(playerid, "PED", "IDLE_STANCE", 4.1, 0, 0, 0, 0, 0);
? ? rAnimLib[playerid] = "PED";
? ??rAnimName[playerid] = "IDLE_STANCE";
? ? return 1;
}
GetAnimationNameEx(playerid, Lib[20], Name[20])
{
? ? Lib = rAnimLib[playerid];
? ? Name = rAnimName[playerid];
}
//use this method instead of GetAnimationName.
I use GetAnimationName() function but it only returns PED, IDLE_STANCE or PED,SEAT_IDLE or PED,WOMAN_IDLESTANCE.
When i apply another animations like /eat, /sit, /lay
this function not give me the applied animation animlib and animname but just return PED, IDLE_STANCE.
PHP Code: ApplyAnimation(playerid,"BEACH","Lay_Bac_Loop",4.1, 0, 1, 1, 1, 1, 1); // Sit
ApplyAnimation(playerid,"BEACH", "bather",4.1, 0, 1, 1, 1, 1, 1); // Lay down
CMD:anim(playerid) {
? ? if(GetPlayerAnimationIndex(playerid))
{
? ? new animlib[32];
? ? new animname[32];
? ? new msg[128];? ?
? ? GetAnimationName(GetPlayerAnimationIndex(playerid),animlib,32,animname,32);
? ? format(msg, 128, "Running anim: %s %s", animlib, animname);
? ? SendClientMessage(playerid, -1, msg); // output is: PED IDLE_STANCE
}
? ? return 1;
}
In other gamemodes that I test, this problem does not occur.
I need to fix this problem quickly.
thanks for the anyone answer.
|
|
|
|
| [FIXED] can't run many timers, that are not working with backtrace notification. |
|
Posted by: PutuSuhartawan - 2021-03-23, 03:59 PM - Forum: Pawn Scripting
- Replies (4)
|
 |
Quote:Change to
SetTimerEx("PublicOwned", 1000, true, "i", playerid);
sorry, I am confused about the mistake where when I install a lot of timer functions it can't work. I also can't run the isvalidtimer function because that include is empty. is there a way to install the correct include timerfix?
Quote:Does not work if it repeats:
SetTimer ("TimeServer", 500, true);
SetTimer ("Change_Color", 5000, true);
will run if one call:
SetTimer ("UnFreezeMe", 3000.0);
|
|
|
|
| Whitelist System |
|
Posted by: Genon_May - 2021-03-23, 08:42 AM - Forum: General Discussions
- Replies (3)
|
 |
Hey, im wondering does anyone know where i can find a whitelist system for samp. There used to be a few on the samp forums but cant reach them right now since they are down. If anyone knows where i can find one (english version) i would be very grateful
|
|
|
|
| A tool/program for finding unmatched brackets? |
|
Posted by: Fawkes - 2021-03-22, 06:10 PM - Forum: Pawn Scripting
- Replies (4)
|
 |
I'm trying to optimize a script i made a few years ago and seperate it into libraries, i'm re-compiling it after every couple of changes to try and make it as easy as possible to identify errors and mistakes as i go along.
At the moment it won't compile (using pawno) unless i scroll to the bottom of the script first and compile from there (no errors or warnings if i don't scroll to the bottom first, it just doesn't create a working AMX unless i scroll to the bottom before compiling), i've checked the brackets with ctrl F and i've got 3 unmatched brackets (from years ago) which i remember used to cause the same problem in the past.
Does anyone know of any online web programs or software to highlight where unmatched bracket openings/closings begin/end without having to disect the whole script piece-by-piece to narrow down the lines manually?
I've tried searching for something to do this but they just give a long list of errors/warnings unrelated to brackets because they're intended for non-pwn.
Any help or suggestions would be great.
|
|
|
|
| sqlite and inputtext |
|
Posted by: robertocaribbean - 2021-03-21, 05:42 PM - Forum: Pawn Scripting
- Replies (6)
|
 |
I am trying to create an SQLite database, I only have three variables to keep it simple.
The problem is that the password is not saved unless I pass <inputtext> directly to the query.
Variables:
Code: enum USER_DATA {
? ? USER_ID,
? ? USER_NICKNAME[MAX_PLAYER_NAME],
? ? USER_PASSWORD[20]
};
new gUserData[MAX_PLAYERS][USER_DATA];
Code working:
Code: public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[]) {
? ? switch (dialogid) {
? ? ? ? case DIALOG_REGISTRATION: {
? ? ? ? ? ? if (!response) return Kick(playerid);
? ? ? ? ? ? if (!(3 <= strlen(inputtext) <= 20)) {
? ? ? ? ? ? ? ? SendClientMessage(playerid, -1, "Tu contrase?a debe tener entre 3 y 20 car?cteres");
? ? ? ? ? ? ? ? ShowPlayerDialog(playerid, DIALOG_REGISTRATION, DIALOG_STYLE_PASSWORD, "Register", "Type in a password below to register an account.", "Register", "Leave" );
? ? ? ? ? ? ? ? return 1;
? ? ? ? ? ? }
? ? ? ? ? ? new query[208], DBResult: result;
? ? ? ? ? ?
? ? ? ? ? ? format(query, sizeof query, "INSERT INTO users (nickname, password) VALUES ('%q', '%s')", gUserData[playerid][USER_NICKNAME], inputtext);
? ? ? ? ? ? db_query(db_handle, query);
? ? ? ? ? ? SendClientMessage(playerid, 0x00FF00FF, "[SERVER]: You have just registered to our server! You have been automatically logged in!");
? ? ? ? ? ? result = db_query(db_handle, "SELECT last_insert_rowid()");
? ? ? ? ? ? gUserData[playerid][USER_ID] = db_get_field_int(result);
? ? ? ? ? ? db_free_result(result);
? ? ? ? }
? ? }
? ? return 1;
}
Code isn't working:
Code: gUserData[playerid][USER_PASSWORD] = inputtext[strlen(inputtext)];? ? ? ? ? ?
? ? ? ? ? ? format(query, sizeof query, "INSERT INTO users (nickname, password) VALUES ('%q', '%s')", gUserData[playerid][USER_NICKNAME], gUserData[playerid][USER_PASSWORD]);
The password field on the database is empty, and other values are ok. No error has given from the compiler.
|
|
|
|
|