SA-MP Forums Archive
Weapon in my back .. Help Me . - 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)
+--- Thread: Weapon in my back .. Help Me . (/showthread.php?tid=231335)



Weapon in my back .. Help Me . - LOLtz120 - 25.02.2011

delete


Re: Weapon in my back .. Help Me . - BlackWolf120 - 25.02.2011

im not sure ive understood u correctly but i believe u want a script attaching not used weapons to ur back?
there are several filterscripts released: e.g.:

http://forum.sa-mp.com/showthread.ph...=weapon+holder
http://forum.sa-mp.com/showthread.ph...=weapon+holder
http://forum.sa-mp.com/showthread.ph...=weapon+holder

regards...


AW: Weapon in my back .. Help Me . - LOLtz120 - 25.02.2011

tnx ! :]


Re: Weapon in my back .. Help Me . - BlackWolf120 - 25.02.2011

np


AW: Weapon in my back .. Help Me . - LOLtz120 - 25.02.2011

delete


Re: Weapon in my back .. Help Me . - BlackWolf120 - 25.02.2011

ive tested this few days ago and for me it worked.
But i didnt use it as a filterscript i just copied&pasted it into my own gamemode filterscript.
Try that.
Just try to paste the code from the weapon holder script into ur filterscript into the specific callback.


AW: Weapon in my back .. Help Me . - LOLtz120 - 25.02.2011

i want Only Sniper and M6 ...
you can give me CODE or make(you can help in link) plz ?
i dont want FS and More .. i want easy code - tnx for help.


Re: Weapon in my back .. Help Me . - BlackWolf120 - 25.02.2011

i took this from this code:

http://forum.sa-mp.com/showthread.ph...=weapon+holder

this was originally done for m4 and ak47.
i just changed the weapon and weapon object id's to the id's of ur requested weps.

pawn Code:
//OnPlayerUpdate
    new weapons[13][2], weapid = GetPlayerWeapon(playerid), object;
    for(new i = 0; i < 13; i++)
    {
    GetPlayerWeaponData(playerid, i, weapons[i][0], weapons[i][1]);
    }
    if(weapid == 34 || weapid == 31 || weapons[5][1] == 0) RemovePlayerAttachedObject(playerid, holdindex);//here
    else {
        if(weapons[5][0] == 34) object = 358; else if(weapons[5][0] == 31) object = 356;//and here
        #define EachSkin(%0,%1,%2,%3,%4,%5) SetPlayerAttachedObject(playerid, holdindex, object, 1, (%0), (%1), (%2), (%3), (%4), (%5), 1.000000, 1.000000, 1.000000);
        switch(GetPlayerSkin(playerid))
        {
            case 0: EachSkin(0.299511, -0.122143, 0.134006, 0.000000, 158.504928, 0.000000)
            case 1..2: EachSkin(0.299511, -0.133396, 0.134006, 0.000000, 158.504928, 0.000000)
            case 9: EachSkin(0.299511, -0.111301, 0.135122, 0.000000, 158.504928, 0.000000)
            case 10: EachSkin(0.236573, -0.121403, 0.135122, 0.000000, 158.504928, 0.000000)

//and so on, but u also have to include the rest of EliranPesahov's filterscript
untested, i dont have time right now but it should work


AW: Weapon in my back .. Help Me . - LOLtz120 - 26.02.2011

delete


Re: Weapon in my back .. Help Me . - BlackWolf120 - 26.02.2011

first of all there are NO errors!
For me it just compiled fine.
Next this is for 0.3c!
And last but not least i dont know what u want at all.

peace