How to Limit PlayerAttach Object Size
#7

still i can increase object size to bigger..

i used like this..

on top
pawn Код:
#define CONSTRAINT_MIN_X 0.75
#define CONSTRAINT_MIN_Y 0.75
#define CONSTRAINT_MIN_Z 0.75
#define CONSTRAINT_MAX_X 1.25
#define CONSTRAINT_MAX_Y 1.25
#define CONSTRAINT_MAX_Z 1.25

IsValidScale(Float:sx, Float:sy, Float:sz)
{
    if( sx <= CONSTRAINT_MIN_X || sx >= CONSTRAINT_MAX_X  || sy <= CONSTRAINT_MIN_Y || sy >= CONSTRAINT_MAX_Y  || sz <= CONSTRAINT_MIN_Z || sz >= CONSTRAINT_MAX_Z ) return 0;
    return 1;
}
and under onplayereditattachedobject.
pawn Код:
if(IsValidScale(fScaleX, fScaleY, fScaleZ))
{  
SetPlayerAttachedObject(playerid,index,modelid,boneid,fOffsetX,fOffsetY,fOffsetZ,fRotX,fRotY,fRotZ,fScaleX,fScaleY,fScaleZ);
}
Reply


Messages In This Thread
How to Limit PlayerAttach Object Size - by danish007 - 11.01.2015, 15:55
Re: How to Limit PlayerAttach Object Size - by IstuntmanI - 11.01.2015, 16:01
Re: How to Limit PlayerAttach Object Size - by Divergent - 11.01.2015, 16:02
Re: How to Limit PlayerAttach Object Size - by danish007 - 11.01.2015, 16:09
Re: How to Limit PlayerAttach Object Size - by Divergent - 11.01.2015, 16:15
Re: How to Limit PlayerAttach Object Size - by Pottus - 11.01.2015, 16:27
Re: How to Limit PlayerAttach Object Size - by danish007 - 11.01.2015, 17:06
Re: How to Limit PlayerAttach Object Size - by Pottus - 11.01.2015, 17:42
Re: How to Limit PlayerAttach Object Size - by danish007 - 11.01.2015, 20:28
Re: How to Limit PlayerAttach Object Size - by Aasim - 11.01.2015, 20:37

Forum Jump:


Users browsing this thread: 2 Guest(s)