[Tutorial] Basic - Get GangZone Center
#1

Hey Members.

Code:
pawn Код:
new                            Float:CenterX,
                                 Float:CenterY;

       CenterX = (zMinX+zMaxX) / 2;
     CenterY = (zMinY+zMaxY) / 2;
   
   
///Exemple:

GangZoneCreate(1248.011, 2072.804, 1439.348, 2204.319);


zMinX: 1248.011
zMinY: 2072.804
zMaxX: 1439.348
zMaxY:  2204.319


CenterX = (1248.011+1439.348) / 2;
     CenterY = (2072.804+2204.319) / 2;

//Create a MapIcon in Gangzone Center

CreateDynamicMapIcon(CenterX, CenterY,0.0, 19, -1, -1, -1,-1,100.0);// Cord. Z Value = 0.0
Sorry for bad english. and bad explanation
Reply
#2

Nice, I learnt how to half things to find out the centre of something...
Maybe you should add a little bit more comments explaining what everything does for the less knowledgeable on the forums. Its good, but could be improved.
Reply
#3

Thanks... but i not have a Good English for explain
Reply
#4

Nice work, basic mathematics
Reply
#5

Basic - Get GangZone Center

Basic!
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)