[BUG ?] fX, fY, fZ in OnPlayerWeaponShot
#1

pawn Код:
//I created 2 objects with different rotations.
    CreateObject(6959, 17.18580, -58.10570, 2.61260,   0.00000, 90.00000, 0.00000); //hitid 1
    CreateObject(6959, 17.18580, -18.14240, 2.61260,   180.00000, 90.00000, 0.00000); //hitid 2


public OnPlayerWeaponShot(playerid, weaponid, hittype, hitid, Float:fX, Float:fY, Float:fZ)
{
    new Float:X, Float:Y, Float:Z;
    switch(hittype)
    {
        case BULLET_HIT_TYPE_OBJECT: GetObjectPos( hitid, X, Y, Z );
    }
    CreateObject(1946, X - fZ, Y - fY, Z + fX, 0, 0, 0, 100); //You may noticed I put fZ in X, and fX in Z in CreateObject. And On X and Y I used minus, on Z, I used plus symbol.
//I don't know why, but it works perfect on hitid 1, but it doesn't work properly on hitid 2. Watch the video below;
    return 1;
}
[ame]http://www.youtube.com/watch?v=jIPYxbf_MSc[/ame]
Reply


Messages In This Thread
[BUG ?] fX, fY, fZ in OnPlayerWeaponShot - by newbienoob - 17.01.2014, 16:17
Re: [BUG ?] fX, fY, fZ in OnPlayerWeaponShot - by FUNExtreme - 17.01.2014, 16:36
Re: [BUG ?] fX, fY, fZ in OnPlayerWeaponShot - by newbienoob - 18.01.2014, 05:15
Re: [BUG ?] fX, fY, fZ in OnPlayerWeaponShot - by Drebin - 18.01.2014, 08:55
Re: [BUG ?] fX, fY, fZ in OnPlayerWeaponShot - by ACI - 18.01.2014, 10:22
Re: [BUG ?] fX, fY, fZ in OnPlayerWeaponShot - by FUNExtreme - 18.01.2014, 12:36

Forum Jump:


Users browsing this thread: 2 Guest(s)