Recent posts

#31
Script Showroom / Re: Dipeos command
Last post by PSL - Mar 10, 2024, 06:25 AM
Thanks to Xmair for the tip. I forgot about the player quitting.
Another point is that when the player falls into the water, the coordinates are not recorded.
DiePos<-{}; //Create a table where you can store coordinates
function onPlayerPart(player, reason) {
    if (DiePos.rawin(player.ID))
        DiePos.rawdelete(player.ID);
}

function onPlayerSpawn(player)
{
if(DiePos.rawin(player.ID)) //If an ID exists in the table
    {
        player.Pos=DiePos.rawget(player.ID); //Restores the player to death point
        DiePos.rawdelete(player.ID); //Delete coordinates after recovery
    }
}
function onPlayerDeath(player,reason)
{
 if(reason!=43)
{
 DiePos.rawset(player.ID,player.Pos); //After the player dies, the ID is used as the search object, and the death coordinates are stored in the table
}
}
#32
Script Showroom / Re: Dipeos command
Last post by Xmair - Mar 09, 2024, 06:56 PM
Quote from: PSL on Mar 09, 2024, 08:11 AMThe following code may help you
DiePos<-{}; //Create a table where you can store coordinates
function onPlayerSpawn(player)
{
if(DiePos.rawin(player.ID)) //If an ID exists in the table
    {
        player.Pos=DiePos.rawget(player.ID); //Restores the player to death point
        DiePos.rawdelete(player.ID); //Delete coordinates after recovery
    }
}
function onPlayerDeath(player,reason)
{
DiePos.rawset(player.ID,player.Pos); //After the player dies, the ID is used as the search object, and the death coordinates are stored in the table
}

You should also remove the player data once the player disconnects.
function onPlayerPart(player, reason) {
    if (DiePos.rawin(player.ID))
        DiePos.rawdelete(player.ID);
}
#33
Community Plugins / Re: NPC/Bots implementation in...
Last post by PSL - Mar 09, 2024, 02:54 PM
I always find problems as soon as you release a new version. Now I have no more problems to report.
This plugin is very good, with it you can make a lot of gameplay.
Hi Habi. How can I tell if an ID is an NPC player in an NPC script. Recognize players and NPCS. I don't want to give NPCS a uniform name or skin.
function OnPlayerStreamIn(playerid)
{
    print("I see the "+GetPlayerName(playerid)+" enter my field of view, and his ID is: "+playerid+".");

    local r=RFC("IsPlayerNPC")(playerid);
    print(""+r+""); //Always return true
}
#34
Script Showroom / Re: Dipeos command
Last post by PSL - Mar 09, 2024, 08:11 AM
The following code may help you
DiePos<-{}; //Create a table where you can store coordinates
function onPlayerSpawn(player)
{
if(DiePos.rawin(player.ID)) //If an ID exists in the table
    {
        player.Pos=DiePos.rawget(player.ID); //Restores the player to death point
        DiePos.rawdelete(player.ID); //Delete coordinates after recovery
    }
}
function onPlayerDeath(player,reason)
{
DiePos.rawset(player.ID,player.Pos); //After the player dies, the ID is used as the search object, and the death coordinates are stored in the table
}
#35
Script Showroom / Dipeos command
Last post by Abbas_905 - Mar 08, 2024, 01:24 PM
Anyone i want diepos command u can give me diepos command i want to add, diepos command in my server
#36
Community Plugins / Re: NPC/Bots implementation in...
Last post by habi2 - Mar 06, 2024, 05:32 PM
No need to apologize! I'm glad that the problem is fixed.
#37
Servers / Re: [0.4]Grand Theft Auto Syri...
Last post by Abbas_905 - Mar 05, 2024, 02:04 PM
Nice bro
#38
Bugs and Crashes / Re: [Bug]One bug in squirrel m...
Last post by PSL - Mar 05, 2024, 11:35 AM
GetShowOnlyTeamMarkers()
This function gets an error every time it is called.
Hopefully the developers can fix it.
#39
Community Plugins / Re: NPC/Bots implementation in...
Last post by PSL - Mar 05, 2024, 02:48 AM
This problem has been fixed perfectly, and I'm sorry to have caused you so much trouble.
#40
Community Plugins / Re: NPC/Bots implementation in...
Last post by habi2 - Mar 04, 2024, 04:40 PM
Hi PSL, i fixed the second issue. Now the error "vehicle not acquired by npc" is not shown. Also it drives vehicle good.
Here is a windows only patch of npcclient.exe
rel006
windows https://www.mediafire.com/file/yx1onimsqn8uq5e/npcclient-v1.8-beta-p1a.zip/file
linux-64 https://www.mediafire.com/file/p8z51uteldg6h9b/npcclient64-linux-v1.8-beta-p1a.zip/file
rel004
windows https://www.mediafire.com/file/wz00axkfzeid81d/npcclient_r004-v1.8-beta-p1a.zip/file
linux-64 https://www.mediafire.com/file/6nkxeepdkpbk37q/npcclient64_r004-linux-v1.8-beta-p1a.zip/file
I will release all editions soon. Please report any bugs you find like this.