Thread: Making an area wilderness?

Page 1 of 2 12 LastLast
Results 1 to 10 of 15
  1. #1 Making an area wilderness? 
    :')


    Join Date
    Oct 2008
    Age
    26
    Posts
    1,946
    Thanks given
    48
    Thanks received
    47
    Rep Power
    1545
    Close.
    Reply With Quote  
     

  2. #2  
    :')


    Join Date
    Oct 2008
    Age
    26
    Posts
    1,946
    Thanks given
    48
    Thanks received
    47
    Rep Power
    1545
    bump
    Reply With Quote  
     

  3. #3  
    Austin_
    Guest
    Add the coords in isInWild(){
    Reply With Quote  
     

  4. #4  
    :')


    Join Date
    Oct 2008
    Age
    26
    Posts
    1,946
    Thanks given
    48
    Thanks received
    47
    Rep Power
    1545
    Quote Originally Posted by Austin. View Post
    Add the coords in isInWild(){
    Code:
    public boolean isInWilderness(int coordX, int coordY, int Type) {
    	if(isInPkBox()) return false;
    	if(isinsafewild()) return true;
    		if (Type == 1) {
    			if ((coordY >= 3523) && (coordY <= 3967) && (coordX <= 3392) &&  (absX >= 3131 && absX <= 3133 && absY >=3708  && absY <=3710 ) || (absX >= 3158 && absX <= 3160 && absY >=3708  && absY <=3710 )
    					&& (coordX >= 2942) || absX >= 3220 && absX <= 3299 && absY >= 3520 && absY <=3548 || absX >= 2250 && absX <= 2296 && absY >= 4676 && absY <=4715) {
    				return true;
    			}
    		} else if (Type == 2) {
    			if ((coordY >= 3512) && (coordY <= 3967) && (coordX <= 3392)
    					&& (coordX >= 2942)) {
    				return true;
    			}
    
    		}
    		return false;
    	}
    Reply With Quote  
     

  5. #5  
    Registered Member
    Join Date
    Nov 2009
    Posts
    45
    Thanks given
    0
    Thanks received
    0
    Rep Power
    1
    Deleted
    Reply With Quote  
     

  6. #6  
    Banned

    Join Date
    Jan 2009
    Age
    28
    Posts
    2,662
    Thanks given
    66
    Thanks received
    207
    Rep Power
    0
    Post Both

    The Coords You Dont Want Wildy And The Coords You Want Wildy.



    Also Maybe Change Type == 2

    To Type == 1??

    Because i doubt u have your server checking for type == 2
    Reply With Quote  
     

  7. #7  
    Registered Member
    Join Date
    Nov 2009
    Posts
    45
    Thanks given
    0
    Thanks received
    0
    Rep Power
    1
    Deleted
    Reply With Quote  
     

  8. #8  
    Registered Member

    Join Date
    Nov 2007
    Age
    25
    Posts
    644
    Thanks given
    7
    Thanks received
    6
    Rep Power
    104
    You probably got one of the > or < mixed up. That would do it.
    [Only registered and activated users can see links. ] | [Only registered and activated users can see links. ] | [Only registered and activated users can see links. ] | [Only registered and activated users can see links. ]
    Reply With Quote  
     

  9. #9  
    Registered Member
    Join Date
    Nov 2009
    Posts
    45
    Thanks given
    0
    Thanks received
    0
    Rep Power
    1
    Deleted
    Reply With Quote  
     

  10. #10  
    Banned

    Join Date
    Jul 2008
    Age
    26
    Posts
    5,826
    Thanks given
    1,301
    Thanks received
    197
    Rep Power
    0
    Explanation:
    Your standing in front of the square of land you want to make attackable.
    The top of your screen is pointing north.

    - You want your X coordinate to be > than the pink circle, but < than the blue
    - You want your Y coordinate to be > than the yellow circle, but < than the green


    So,
    Code:
    if(X > pink && X < blue && Y > yellow && Y < green) {
    //inwild
    }
    
    public boolean isInWilderness(int coordX, int coordY, int Type) {
        if(coordX > pink && coordX < blue && coordY > yellow && coordY < green) {
            return true;
        }
    }
    Reply With Quote  
     

Page 1 of 2 12 LastLast

Thread Information
Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)


User Tag List

Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •