SA-MP Forums Archive
look! help plox :D - 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: look! help plox :D (/showthread.php?tid=181229)



look! help plox :D - thomas.. - 04.10.2010

pawn Код:
stock CreateStrip(Float:x,Float:y,Float:z,Float:Angle)
{
    for(new i = 0; i < sizeof(SpikeInfo); i++)
    {
        if(SpikeInfo[i][sCreated] == 0)
        {
            SpikeInfo[i][sCreated]=1;
            SpikeInfo[i][sX]=x+10;
            SpikeInfo[i][sY]=y;
            SpikeInfo[i][sZ]=z-0.7;
            SpikeInfo[i][sObject] = CreateObject(2899, x+10, y, z-0.7, 0, 0, Angle);
            return 1;
        }
    }
    return 0;
}
how to make the object create with the same X pos as the player? i tried hundreds of times < literally and now i have given up on it

pawn Код:
new Float:plocx,Float:plocy,Float:plocz,Float:ploca;
            GetPlayerPos(playerid, plocx, plocy, plocz);
            GetPlayerFacingAngle(playerid,ploca);
            CreateStrip(plocx,plocy,plocz,ploca);
p.s

maybe getvehiclefacing angle? i am so confused with this :@ i thought it would work


Re: look! help plox :D - samgreen - 04.10.2010

pawn Код:
stock CreateStrip(Float:x,Float:y,Float:z,Float:Angle)
{
    for(new i = 0; i < sizeof(SpikeInfo); i++)
    {
        if(SpikeInfo[i][sCreated] == 0)
        {
                SpikeInfo[i][sCreated]=1;
                SpikeInfo[i][sX]=x;
                SpikeInfo[i][sY]=y;
                SpikeInfo[i][sZ]=z-0.7;
                SpikeInfo[i][sObject] = CreateObject(2899, x, y, z-0.7, 0, 0, Angle);
            return 1;
        }
    }
    return 0;
}



Re: look! help plox :D - thomas.. - 04.10.2010

Quote:
Originally Posted by samgreen
Посмотреть сообщение
pawn Код:
stock CreateStrip(Float:x,Float:y,Float:z,Float:Angle)
{
    for(new i = 0; i < sizeof(SpikeInfo); i++)
    {
        if(SpikeInfo[i][sCreated] == 0)
        {
                SpikeInfo[i][sCreated]=1;
                SpikeInfo[i][sX]=x;
                SpikeInfo[i][sY]=y;
                SpikeInfo[i][sZ]=z-0.7;
                SpikeInfo[i][sObject] = CreateObject(2899, x, y, z-0.7, 0, 0, Angle);
            return 1;
        }
    }
    return 0;
}
i meant the same angle