Welcome, Guest |
You have to register before you can post on our site.
|
Forum Statistics |
» Members: 6,511
» Latest member: snaptrap
» Forum threads: 2,233
» Forum posts: 12,034
Full Statistics
|
Online Users |
There are currently 349 online users. » 0 Member(s) | 347 Guest(s) Bing, Google
|
Latest Threads |
I humor myself
Forum: Programming
Last Post: nami16504
Yesterday, 04:28 PM
» Replies: 5
» Views: 8,045
|
Command does not work in-...
Forum: Pawn Scripting
Last Post: PANZEHIR_
2024-11-23, 06:36 PM
» Replies: 0
» Views: 43
|
White Screen
Forum: Support
Last Post: Phat202146_real
2024-11-21, 02:50 PM
» Replies: 0
» Views: 43
|
I get error 021 using y_h...
Forum: Pawn Scripting
Last Post: daniscript18
2024-11-18, 11:34 PM
» Replies: 0
» Views: 61
|
Il reste des français sur...
Forum: French/Fran?ais
Last Post: tysanio
2024-11-18, 05:39 AM
» Replies: 2
» Views: 470
|
Object creation issues
Forum: Programming
Last Post: K1271
2024-11-15, 11:51 PM
» Replies: 0
» Views: 56
|
Is the SAMP Hosting the s...
Forum: General Discussions
Last Post: OperaGX
2024-11-14, 09:33 PM
» Replies: 0
» Views: 76
|
Run time error 19: "File ...
Forum: Pawn Scripting
Last Post: Rexey
2024-11-14, 03:50 AM
» Replies: 0
» Views: 65
|
How to Compile Your Gamem...
Forum: Tutorials
Last Post: thelante
2024-11-13, 08:50 AM
» Replies: 3
» Views: 478
|
Modeller wanted
Forum: Development Updates
Last Post: acc.gangbeni
2024-11-11, 05:10 PM
» Replies: 9
» Views: 16,531
|
|
|
[HELP] Weapon Skill Command |
Posted by: spyrothedragon96 - 2021-08-03, 08:33 AM - Forum: Pawn Scripting
- Replies (2)
|
|
Hello everyone.
I made 3 commands to set the skill level of the weapons, /poor, /gangster and /hitman.
The problem is that when me and the other players die / disconnect, the level goes back to the initial level, that is to the maximum, and the command I had set is not saved.
How can I do to get it saved when one dies / disconnects?
Quote:COMMAND:poor(playerid, params[])
{
? ? if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid, 0xFF0000AA, "Devi loggare come RCON.");
? ? {
for(new i=0; i<MAX_PLAYERS; i)
{
if(IsPlayerNPC(i) || IsPlayerConnected(i))
{
SetPlayerSkillLevel(i, WEAPONSKILL_PISTOL, 1);
SetPlayerSkillLevel(i, WEAPONSKILL_PISTOL_SILENCED, 1);
SetPlayerSkillLevel(i, WEAPONSKILL_DESERT_EAGLE, 1);
SetPlayerSkillLevel(i, WEAPONSKILL_SHOTGUN, 1);
SetPlayerSkillLevel(i, WEAPONSKILL_SAWNOFF_SHOTGUN, 1);
SetPlayerSkillLevel(i, WEAPONSKILL_SPAS12_SHOTGUN, 1);
SetPlayerSkillLevel(i, WEAPONSKILL_MICRO_UZI, 1);
SetPlayerSkillLevel(i, WEAPONSKILL_MP5, 1);
SetPlayerSkillLevel(i, WEAPONSKILL_AK47, 1);
SetPlayerSkillLevel(i, WEAPONSKILL_M4, 1);
SetPlayerSkillLevel(i, WEAPONSKILL_SNIPERRIFLE, 1);
? ? ? ? }
? ? }
? ? }
return 1;
}
COMMAND:gangster(playerid, params[])
{
? ? if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid, 0xFF0000AA, "Devi loggare come RCON.");
? ? {
for(new i=0; i<MAX_PLAYERS; i)
{
if(IsPlayerNPC(i) || IsPlayerConnected(i))
{
? ? SetPlayerSkillLevel(playerid, WEAPONSKILL_PISTOL, 40);
? ? SetPlayerSkillLevel(playerid, WEAPONSKILL_PISTOL_SILENCED, 500);
? ? SetPlayerSkillLevel(playerid, WEAPONSKILL_DESERT_EAGLE, 200);
? ? SetPlayerSkillLevel(playerid, WEAPONSKILL_SHOTGUN, 200);
? ? SetPlayerSkillLevel(playerid, WEAPONSKILL_SAWNOFF_SHOTGUN, 200);
? ? SetPlayerSkillLevel(playerid, WEAPONSKILL_SPAS12_SHOTGUN, 200);
? ? SetPlayerSkillLevel(playerid, WEAPONSKILL_MICRO_UZI, 50);
? ? SetPlayerSkillLevel(playerid, WEAPONSKILL_MP5, 250);
? ? SetPlayerSkillLevel(playerid, WEAPONSKILL_AK47, 200);
? ? SetPlayerSkillLevel(playerid, WEAPONSKILL_M4, 200);
? ? SetPlayerSkillLevel(playerid, WEAPONSKILL_SNIPERRIFLE, 300);
? ? ? ? }
? ? }
? ? }
? ? return 1;
}
COMMAND:hitman(playerid, params[])
{
? ? if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid, 0xFF0000AA, "Devi loggare come RCON.");
? ? {
for(new i=0; i<MAX_PLAYERS; i)
{
if(IsPlayerNPC(i) || IsPlayerConnected(i))
{
? ? SetPlayerSkillLevel(playerid, WEAPONSKILL_PISTOL, 999);
? ? SetPlayerSkillLevel(playerid, WEAPONSKILL_PISTOL_SILENCED, 999);
? ? SetPlayerSkillLevel(playerid, WEAPONSKILL_DESERT_EAGLE, 999);
? ? SetPlayerSkillLevel(playerid, WEAPONSKILL_SHOTGUN, 999);
? ? SetPlayerSkillLevel(playerid, WEAPONSKILL_SAWNOFF_SHOTGUN, 999);
? ? SetPlayerSkillLevel(playerid, WEAPONSKILL_SPAS12_SHOTGUN, 999);
? ? SetPlayerSkillLevel(playerid, WEAPONSKILL_MICRO_UZI, 999);
? ? SetPlayerSkillLevel(playerid, WEAPONSKILL_MP5, 999);
? ? SetPlayerSkillLevel(playerid, WEAPONSKILL_AK47, 999);
? ? SetPlayerSkillLevel(playerid, WEAPONSKILL_M4, 999);
? ? SetPlayerSkillLevel(playerid, WEAPONSKILL_SNIPERRIFLE, 999);
? ? ? ? }
? ? }
? ? }
? ? return 1;
}
|
|
|
[HELP] PawnPlus Warning. |
Posted by: xBigDK - 2021-08-02, 09:50 PM - Forum: Pawn Scripting
- No Replies
|
|
Hi Guys, sorry for bad english.
I'm doing a samp server, and I put the PawnPlus include on my server, my host is linux, I uploaded PawnPlus.so, but this warning appears, I have no idea what it is. Also after a few minutes the server simply doesn't load the files, it's still online, but as if it were a "Blank Script"
Code: ----------
Loaded log file: "server_log.txt".
----------
SA-MP Dedicated Server
----------------------
v0.3.7-R2, (C)2005-2015 SA-MP Team
[18:25:36] password = ""? (string)
[18:25:36] filterscripts = ""? (string)
[18:25:36]
[18:25:36] Server Plugins
[18:25:36] --------------
[18:25:36]? Loading plugin: sscanf.so
[18:25:36]
[18:25:36]? ===============================
[18:25:36]? ? ? sscanf plugin loaded.? ?
[18:25:36]? ? ? ? ? Version:? 2.8.3? ? ? ?
[18:25:36]? (c) 2018 Alex "Y_Less" Cole?
[18:25:36]? ===============================
[18:25:36]? Loaded.
[18:25:36]? Loading plugin: streamer.so
[18:25:36]
*** Streamer Plugin v2.9.4 by Incognito loaded ***
[18:25:36]? Loaded.
[18:25:36]? Loading plugin: pawncmd.so
[18:25:36] [Pawn.CMD] plugin v3.3.3 by urShadow loaded
[18:25:36]? Loaded.
[18:25:36]? Loading plugin: PawnPlus.so
[18:25:36]? PawnPlus v1.3.2 loaded
[18:25:36]? Created by IllidanS4
[18:25:36]? Loaded.
[18:25:36]? Loaded 4 plugins.
[18:25:36]
[18:25:36] Filterscripts
[18:25:36] ---------------
[18:25:36]? Loaded 0 filterscripts.
[18:25:36] Objetos: 13 carregado(s) de Objetos/CaixaEletronico.txt
[18:25:36]
====================================
[18:25:36] |? ? ? GAMEMODE BY: BigDK |
[18:25:36] |? ? ? Heist RolePlay ? |
[18:25:36] ====================================
[18:25:36] Number of vehicle models: 1
[18:26:19] [connection] 189.10.145.144:22403 requests connection cookie.
[18:26:20] [connection] incoming connection: 189.10.145.144:22403 id: 0
[18:26:20] [join] Big_dk has joined the server (0:189.10.145.144)
[18:34:27] [PawnPlus] Warning: amx_FindPublic returned negative index -10060 for function 'pp_on_error'. Possible collision with SAMPGDK detected. Use pp_public_min_index or pp_use_funcidx to remove this warning.
[18:34:27] [PawnPlus] pool_has: argument 'index' is out of range
[18:34:27] [part] Big_dk has left the server (0:1)
i have the includes:
a_samp
td-streamer
streamer
sscanf2
dof2
Pawn.CMD
foreach
a_zones
cpstream
|
|
|
I think open.mp forums should have a better domain |
Posted by: NoxxeR - 2021-08-01, 12:37 PM - Forum: Chat
- Replies (8)
|
|
I think open.mp should change the forum domain to?https://forums.open.mp/ or something like that, its sounds more related than burgershot.gg, maybe in the future?
And the design on the forums needs to be improved a bit, so people register on the forums. Advertising the forums would be much easier if the domain is https://forums.open.mp/ but thats just my point. :P
|
|
|
Help - SetObjectMaterial with Custom Object (0.3.DL)? |
Posted by: Jurgen33 - 2021-08-01, 12:10 PM - Forum: Pawn Scripting
- Replies (1)
|
|
Hello,
How can use SetObjectMaterial with Custom Object for SA-MP?0.3.DL Version.
Example:
SetDynamicObjectMaterial(tmpobjid,?0, -1001, "custom_object_txd_file_name",?"texture_name_in_txd_file",?0x00000000);
Please help. I couldn't find what to write instead of txd file name. That's why not work!
|
|
|
clear/empty an array |
Posted by: redex - 2021-07-31, 01:21 PM - Forum: Programming
- Replies (6)
|
|
hi!
i wanted to know is there anyway to clear an array with only a few lines? i have player info in this array:
Code: enum e_playerinfo
{
? ? someInt,
? ? Float:someFloat,
??? someString[144],
}
new playerInfo[MAX_PLAYERS][e_playerinfo];
and i wanted to know how can i clear it in on player disconnect after saving the values in sql, i used to do like this:
Code: public OnPlayerDisconnect(...)
{
? ? playerInfo[playerid][...] = 0;
? ? playerInfo[playerid][...] = 0.0;
? ? playerInfo[playerid][...] = "";
? ? ...
}
and i had to do this for every variable i add, is there anyway to make this more simple?
|
|
|
Timer |
Posted by: njoBe_ - 2021-07-30, 08:49 PM - Forum: Pawn Scripting
- Replies (6)
|
|
Im trying to make /mute command, but i dont know how to set timer which is equal to time which i set in command and when this timer ends it sets to player stats Muted = 0
Code: CMD:mute(playerid, params[])
{
if (!IsPlayerAdmin(playerid) || PlayerInfo [playerid] [pAdmin] < 1) return SendClientMessage(playerid, COLOR_SERVER, "[BC:RP] {FFFFFF}Niste admin.");
if (IsPlayerAdmin(playerid) || PlayerInfo [playerid] [pAdmin] > 0)
{
new id, reason[128], str[128], string[256], pName[MAX_PLAYER_NAME], pMutedName[MAX_PLAYER_NAME], time;
if(sscanf(params, "uis", id, time, reason)) return SendClientMessage(playerid, COLOR_SERVER, "[Usage]: {FFFFFF}/mute [ID/Ime] [Vrijeme] [Razlog]") ;
else if (time < 0 || time > 1000) return SendClientMessage(playerid, COLOR_SERVER, "[Usage]: Vrijeme ne moze biti manje od 0 (skidanje mute-a) i vece od 1000. ");
else if (time == 0) return SendClientMessage(playerid, -1, "Admin vam je skinuo mute.");
GetPlayerName(playerid, pName, sizeof(pName));
GetPlayerName(id, pMutedName, sizeof(pMutedName));
format(str, sizeof(str), "{FF0000}Utisani ste od strane admina {FFFFFF}%s {FF0000} na {FFFFFF}%d {FF0000}minuta. Razlog: {FFFFFF}%s.", pName, time, reason);
SendClientMessage(id, -1, str);
format(string, sizeof(string), "{FF0000}[Mute]: Admin {FFFFFF}%s {FF0000}je utisao igraca {FFFFFF}%s {FF0000}na {FFFFFF}%d {FF0000}minuta. Razlog: {FFFFFF}%s", pName, pMutedName, time, reason);
foreach(Player, i)
if(PlayerInfo [i] [pStaff] == 1)
{
SendClientMessage(i, -1, string);
}
PlayerInfo [id] [pMuted] = time;
PlayerInfo [id] [pMutedReason] = reason;
SetTimerEx("mutetime", time*1000, false, "d", id);
}
return 1;
}
|
|
|
I cannot find the erorr here! |
Posted by: Scylla - 2021-07-30, 09:13 AM - Forum: Pawn Scripting
- Replies (3)
|
|
I have been getting this error and I don't know where this is happening. This error was really long time ago so I stopped coding. Now I want to continue it, and still I'm getting this error and it sucks.
Error:
Code: \CF.pwn(125) : error 010: invalid function or declaration
\CF.pwn(483) : error 017: undefined symbol "DIALOG_LOGIN"
\CF.pwn(487) : error 017: undefined symbol "DIALOG_REGISTER"
\CF.pwn(1105) : error 017: undefined symbol "DIALOG_REGISTER"
\CF.pwn(1110) : error 017: undefined symbol "DIALOG_REGISTER"
\CF.pwn(1126) : error 017: undefined symbol "DIALOG_LOGIN"
\CF.pwn(1138) : error 017: undefined symbol "DIALOG_LOGIN"
Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
7 Errors.
Line 125 - 129:
Code: enum
{
? ? ? ?DIALOG_REGISTER = 0,
? ? ? ?DIALOG_LOGIN,
};
Line 483:
Code: ShowPlayerDialogEx(playerid, DIALOG_LOGIN, DIALOG_STYLE_PASSWORD, "{FFFF00}Login to proceed", "{FFFFFF}This account is registered... Please login to continue with your account.", "Enter", "Close");
My includes:
Code: #include "a_samp"
#include "YSI\y_ini"
#include "YSI\y_timers"
#include "sscanf2"
#include "progress"
#include "zcmd"
#include "mSelection"
#include "weapon-config"
#include "streamer"
#include "foreach"
Please help!
|
|
|
Server Start normally by there's an Error on Server Logs |
Posted by: RainG - 2021-07-28, 05:12 PM - Forum: Pawn Scripting
- Replies (1)
|
|
Code: Couldn't connect to radio station database... server will continue to operate normally.
Code: [17:08:36]? ? Error: Function not registered: 'SvCreateGStream'
[17:08:36]? ? Error: Function not registered: 'SvDeleteStream'
[17:08:36]? ? Error: Function not registered: 'SvAttachSpeakerToStream'
[17:08:36]? ? Error: Function not registered: 'SvDetachSpeakerFromStream'
[17:08:36]? ? Error: Function not registered: 'SvGetVersion'
[17:08:36]? ? Error: Function not registered: 'SvHasMicro'
[17:08:36]? ? Error: Function not registered: 'SvCreateDLStreamAtPlayer'
[17:08:36]? ? Error: Function not registered: 'SvAttachListenerToStream'
[17:08:36]? ? Error: Function not registered: 'SvAddKey'
|
|
|
|