SA-MP Forums Archive
Detonator - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Detonator (/showthread.php?tid=158378)



Detonator - aNdReSk - 09.07.2010

pawn Код:
if(GetPlayerState(playerid) == PLAYER_STATE_ONFOOT) {
        if(GetPlayerWeapon(playerid)==40){
            if (PRESSED(KEY_FIRE)){
            SendClientMessage(playerid,COLOR_BRIGHTRED,"Beep!");
            }
        }
    }
What is wrong with that? I cant get to "SendClientMessage"

it's located on OnPlayerKeyStateChange


Re: Detonator - Kar - 09.07.2010

stop cnping<.<


Re: Detonator - aNdReSk - 09.07.2010

cnping? o_o what u mean


Re: Detonator - Kar - 09.07.2010

Copy n Pasting


Re: Detonator - aNdReSk - 09.07.2010

I just wrote that :S


Re: Detonator - Kar - 09.07.2010

pawn Код:
if(GetPlayerState(playerid) == PLAYER_STATE_ONFOOT)
{
    if(GetPlayerWeapon(playerid)== 40)
    {
        if (PRESSED(KEY_FIRE))
        {
            SendClientMessage(playerid,COLOR_BRIGHTRED,"Beep!");
        }
    }
}



Re: Detonator - aNdReSk - 09.07.2010

thats exactly the same code :P

__

nvm my code was right but it destroyes the detonator before i can check... (tested with a pistol and worked)
anyway around this?


Re: Detonator - Kar - 09.07.2010

i know but you make your codes horrible.


Re: Detonator - aNdReSk - 09.07.2010

why cuz of a couple of enters? :P
I can read them what way so.. Im ok with that

nvm on this one.. too much trouble to use the detonator as remote controller...


Re: Detonator - MisterTickle - 09.07.2010

Try

if(newkeys & KEY_FIRE) {

Theirs not too many problems you just need to do it right. I've never seen that PRESSED thing done before, THis will work fine.