Welcome, Guest |
You have to register before you can post on our site.
|
Forum Statistics |
» Members: 7,021
» Latest member: geppetog
» Forum threads: 2,349
» Forum posts: 12,234
Full Statistics
|
Online Users |
There are currently 259 online users. » 0 Member(s) | 257 Guest(s) Bing, Google
|
|
|
how to set timer when player logout? |
Posted by: naufalikbal00783 - 2023-05-30, 02:38 AM - Forum: Pawn Scripting
- No Replies
|
 |
Hi, I apologize if my English is not very good, I use a translator. I want to ask, I want to make a spawn system, if the player has logged out beyond the specified time, he cannot choose the last spawn. How do I set the timer?
|
|
|
Server creating help |
Posted by: [I]ncognito - 2023-05-26, 08:00 AM - Forum: Programming
- Replies (1)
|
 |
Hello!!
Guys can anyone send me complete guidance for creating server of SAMP,
From 0 level to Pro level
Any Youtube video or any link from where i can learn everything...
Please could be thankful to you all!!
|
|
|
I need a code to find the name and check its existence in the database. |
Posted by: imnikolaidev - 2023-05-24, 09:20 PM - Forum: Pawn Scripting
- No Replies
|
 |
I need a code to find the name and check its existence in the database, but I don't know what is the best code for this task so that it works at the highest possible speed and is optimal.
Sorry for my bad english ;)
Witch one is better?
Code: Std::MySQLCheckAccount(const name[]) {
new Query[128];
format(Query, sizeof(Query), "SELECT 1 FROM `users` WHERE `username`='%s' LIMIT 1", name);
mysql_tquery(gMySQL, Query, "OnMySQLCheckAccount");
return true;
}
Void::OnMySQLCheckAccount() {
switch cache_num_rows() do {
case false: return print("Not find");
default: return print("Find");
}
}
Or
Code: Std::MySQLCheckAccount2(const name[]) {
inline const checkAccount() {
switch cache_num_rows() do {
case false: return print("Not find");
default: return print("Find");
}
}
MySQL_PQueryInline(gMySQL, using inline checkAccount, "SELECT `username` FROM `users` WHERE `username` = '%s' LIMIT 1", name);
return true;
}
|
|
|
I need help. Got back into PAWN scripting after years of inactivity |
Posted by: LincolnClay - 2023-05-19, 01:34 PM - Forum: Pawn Scripting
- No Replies
|
 |
Hey everybody, i've been a PAWN scripter in the ancient times when YSI 3.0 and foreach were the top notch stuff. Decided to get back and start working on my old gamemode again. The gamemode is ANCIENT and of course i'm getting a bunch of errors when using the community pawn compiler and when i try to update to YSI 5.x. I know about foreach being discontinued and i replaced all foreach(Player, i); in my script to foreach( new i = player); and i've changed OnPlayerCommandPerformed, but i'm getting Y_INI errors. Have any Y_INI saving and loading functions changed that i'm not aware of ? I'm sorry for asking these dumb questions, i've been out of the loop for years.
Code: [/b]
[b]D:\[b]mod[/b]\pawno\include\YSI-Includes\YSI_Data\y_foreach\y_foreach_iterators.inc(862) : warning 219: local variable "X" shadows a variable at a preceding level[/b]
D:\[b]mod[/b]\pawno\include\YSI-Includes\YSI_Data\y_foreach\y_foreach_iterators.inc(862) : warning 219: local variable "Y" shadows a variable at a preceding level
D:\[b]mod[/b]\pawno\include\YSI-Includes\YSI_Data\y_foreach\y_foreach_iterators.inc(862) : warning 219: local variable "Z" shadows a variable at a preceding level
D:\[b]mod[/b]\pawno\include\YSI-Includes\YSI_Storage\y_ini\..\..\YSI_Coding\y_inline\..\y_va\y_va_entry.inc(165) : error 035: argument type mismatch (argument 4)
D:\[b]mod[/b]\pawno\include\YSI-Includes\YSI_Storage\y_ini\..\..\YSI_Coding\y_inline\..\y_va\y_va_entry.inc(174) : error 035: argument type mismatch (argument 2)
D:\[b]mod[/b]\pawno\include\YSI-Includes\YSI_Storage\y_ini\..\..\YSI_Coding\y_inline\..\y_va\y_va_entry.inc(183) : error 035: argument type mismatch (argument 3)
D:\[b]mod[/b]\pawno\include\YSI-Includes\YSI_Storage\y_ini\..\..\YSI_Coding\y_inline\..\y_va\y_va_entry.inc(192) : error 035: argument type mismatch (argument 2)
D:\[b]mod[/b]\pawno\include\YSI-Includes\YSI_Storage\y_ini\..\..\YSI_Coding\y_inline\..\y_va\y_va_entry.inc(201) : error 035: argument type mismatch (argument 3)
D:\[b]mod[/b]\pawno\include\YSI-Includes\YSI_Storage\y_ini\..\..\YSI_Coding\y_inline\..\y_va\y_va_entry.inc(264) : error 035: argument type mismatch (argument 1)
D:\[b]mod[/b]\pawno\include\YSI-Includes\YSI_Storage\y_ini\..\..\YSI_Coding\y_inline\..\y_va\y_va_entry.inc(361) : error 035: argument type mismatch (argument 1)
D:\[b]mod[/b]\pawno\include\YSI-Includes\YSI_Storage\y_ini\..\..\YSI_Coding\y_inline\..\y_malloc\y_malloc_warning.inc(7) : warning 237: user warning: y_malloc heap allocation is unstable. Use `YSI_NO_HEAP_MALLOC` to disable it, or `YSI_YES_HEAP_MALLOC` to disable this warning: git.io/YSI_HEAP_MALLOC
D:\[b]mod[/b]\pawno\include\YSI-Includes\YSI_Visual\y_commands\y_commands_impl.inc(220) : error 025: function heading differs from prototype
D:\mod\gamemodes\moddd.pwn(98) : warning 201: redefinition of constant/macro (symbol "SCM")
D:\[b]mod[/b]\gamemodes\moddd.pwn(1504) : error 021: symbol already defined: "DONT_USE_SCM"
D:\[b]mod[/b]\gamemodes\moddd.pwn(25291) : error 025: function heading differs from prototype
[b]
|
|
|
Need help fixing a minigame (payd). |
Posted by: Tixxt - 2023-05-19, 09:16 AM - Forum: Support
- No Replies
|
 |
Hi guys!
My first post but its a good one.. lol.
Im working on my freeroam server (its online/hosted). But i have a problem with the Fallout minigame. Most of the time not all the tiles spawn. And players fall to the ground right after the minigame started. Sometimes all the tiles do spawn. Does someone know how to fix this problem?
The one that can fix this will be rewarded via paypall..
Contact me via this thread or discord.
Greetz Tixxt.
|
|
|
multi player games in russia |
Posted by: alitik20 - 2023-05-09, 08:10 PM - Forum: Russian/???????
- No Replies
|
 |
There are many multiplayer games that are popular in Russia. Here are a few examples:
- Dota 2 - This multiplayer online battle arena (MOBA) game has a large player base in Russia and is known for its competitive gameplay.
- Counter-Strike: Global Offensive - This first-person shooter game is another popular choice for multiplayer gaming in Russia, with many local tournaments and events held throughout the country.
- World of Tanks - This massively multiplayer online game (MMO) features tank warfare and is known for its large player base in Russia and other parts of Europe.
- War Thunder - Another popular MMO featuring vehicular combat, War Thunder has a significant player base in Russia and is known for its realistic simulation of World War II battles.
- PlayerUnknown's Battlegrounds (PUBG) - This battle royale game has gained a large following in Russia since its release, with many players forming teams and competing in local and international tournaments.
|
|
|
Check if two weapons are in same slot |
Posted by: JasonDeRue - 2023-05-05, 08:16 AM - Forum: Pawn Scripting
- Replies (3)
|
 |
Hello, I'm making a weapon/save load system to MySQL and it seems working but I have a problem.
I need something to check if two weapons are in the same slot because now the save system inserts 2 rows in the table.
Example:
I buy Spas12, weapon gets inserted in the table, but if I buy sawn off, the weapon gets inserted in the table so I have 2 weapons of the same slot saved.
I need to avoid this.
This is the save code:
Code: public GivePlayerWeaponEx(playerid, weaponid, ammo)
{
new wepQuery[300];
if(IsValidWeaponID(weaponid))
{
mysql_format(g_SQL, wepQuery, sizeof(wepQuery), "INSERT INTO `weapons` (`userid`, `weaponid`, `ammo`) VALUES (%d, %d, %d) ON DUPLICATE KEY UPDATE ammo = %d",
ReturnAccDbID(playerid), weaponid, ammo, GetPlayerAmmo(playerid) + ammo);
mysql_pquery(g_SQL, wepQuery);
}
return GivePlayerWeapon(playerid, weaponid, ammo);
}
|
|
|
Run time error 4: "Array index out of bounds" |
Posted by: mihaiandrey2008 - 2023-04-12, 03:37 AM - Forum: Support
- No Replies
|
 |
hello, I've been a developer on a new gamemode of mine for a few days and I'm getting this error
[debug] Run time error 4: "Array index out of bounds"
[debug] AMX backtrace:
[debug] #0 00346a94 in OnDialogResponse (playerid=0, dialogid=177, response=1, listitem=0, inputtext[]=@0167cc44 "Owned vehicles", ... <1073741818 arguments>) at D:\SAMP\endless\gamemodes\end.pwn:35756
[debug] #1 0000d038 in public OnDialogResponse (... <5 arguments>) at D:\SAMP\endless\pawno\include\YSI_Coding\..\YSI_Internal\y_cgen.inc:30
https://pastebin.com/XiPnuvxx - line 29
|
|
|
|