Thread: PvP System ERROR!

Page 1 of 4 123 ... LastLast
Results 1 to 10 of 32
  1. #1 PvP System ERROR! 
    Donator

    Join Date
    Jun 2012
    Posts
    93
    Thanks given
    1
    Thanks received
    0
    Rep Power
    11
    Okay so I used Adolf Hitlers PVP System Guide and i did everything correctly. BUT when i compiled, i got errors.
    Code:
            src\server\model\players\Player.java:637: error: illegal start of expression
            public boolean inPvP()
            ^
    src\server\model\players\Player.java:637: error: ';' expected
            public boolean inPvP()
                                ^
    src\server\model\players\Player.java:641: error: illegal start of expression
            public boolean inSafeZone()
            ^
    src\server\model\players\Player.java:641: error: ';' expected
            public boolean inSafeZone()
                                     ^
    4 errors
    Press any key to continue . . .
    Reply With Quote  
     

  2. #2  
    Legit Rank
    Bermuda's Avatar
    Join Date
    Aug 2009
    Posts
    1,463
    Thanks given
    380
    Thanks received
    298
    Rep Power
    2320
    Quote Originally Posted by morgan linder View Post
    and i did everything correctly.
    Clearly not, or else you wouldn't have errors.


    You're probably missing a bracket.
    Attached image
    Reply With Quote  
     

  3. #3  
    Donator

    Join Date
    Jun 2012
    Posts
    93
    Thanks given
    1
    Thanks received
    0
    Rep Power
    11
    notice its only 4 errors now? any idea?
    Reply With Quote  
     

  4. #4  
    Registered Member
    danimals br0's Avatar
    Join Date
    Aug 2010
    Posts
    885
    Thanks given
    64
    Thanks received
    94
    Rep Power
    109
    you probably adding it on wrong place
    Reply With Quote  
     

  5. #5  
    Donator

    Join Date
    Jun 2012
    Posts
    93
    Thanks given
    1
    Thanks received
    0
    Rep Power
    11
    added it in player.java, like i was supposed to.
    Reply With Quote  
     

  6. #6  
    Registered Member

    Join Date
    Nov 2010
    Posts
    1,528
    Thanks given
    1,017
    Thanks received
    348
    Rep Power
    240
    method within a method..
    None.
    Reply With Quote  
     

  7. #7  
    Registered Member
    danimals br0's Avatar
    Join Date
    Aug 2010
    Posts
    885
    Thanks given
    64
    Thanks received
    94
    Rep Power
    109
    Quote Originally Posted by morgan linder View Post
    added it in player.java, like i was supposed to.
    no i mean you added in wrong place in player.java
    Reply With Quote  
     

  8. #8  
    Donator

    Join Date
    Jun 2012
    Posts
    93
    Thanks given
    1
    Thanks received
    0
    Rep Power
    11
    Code:
    public boolean inPirateHouse() {
    	
    
    	/*
    	 * Start of PvP Zones, Safe Zones, and Etc.
    	 */
    	
    	public boolean inPvP() {
    		return(!inSafeZone());
    	}
    
    	
    	public boolean inSafeZone() 
    		return(inEdgevilleBank() || inWestVarrockBank() || inEastVarrockBank() ||
    		   inWestFaladorBank() || inEastFaladorBank() || inCamelotBank() ||
    		   inCatherbyBank() || inNorthArdougneBank() ||inSouthArdougneBank() ||
    		   grandExchangeRoof());
    	}
    I SEE theres no } after public boolean inPirateHouse() { so its 2 booleans in 1?
    Reply With Quote  
     

  9. #9  
    Registered Member
    danimals br0's Avatar
    Join Date
    Aug 2010
    Posts
    885
    Thanks given
    64
    Thanks received
    94
    Rep Power
    109
    public boolean inPirateHouse() {

    }


    /*
    * Start of PvP Zones, Safe Zones, and Etc.
    */

    public boolean inPvP() {
    return(!inSafeZone());
    }


    public boolean inSafeZone() {
    return(inEdgevilleBank() || inWestVarrockBank() || inEastVarrockBank() ||
    inWestFaladorBank() || inEastFaladorBank() || inCamelotBank() ||
    inCatherbyBank() || inNorthArdougneBank() ||inSouthArdougneBank() ||
    grandExchangeRoof());
    }
    Reply With Quote  
     

  10. #10  
    Registered Member
    danimals br0's Avatar
    Join Date
    Aug 2010
    Posts
    885
    Thanks given
    64
    Thanks received
    94
    Rep Power
    109
    It should be like this

    public boolean inPirateHouse() {

    }


    /*
    * Start of PvP Zones, Safe Zones, and Etc.
    */

    public boolean inPvP() {
    return(!inSafeZone());
    }


    public boolean inSafeZone() {
    return(inEdgevilleBank() || inWestVarrockBank() || inEastVarrockBank() ||
    inWestFaladorBank() || inEastFaladorBank() || inCamelotBank() ||
    inCatherbyBank() || inNorthArdougneBank() ||inSouthArdougneBank() ||
    grandExchangeRoof());
    }
    Reply With Quote  
     

Page 1 of 4 123 ... LastLast

Thread Information
Users Browsing this Thread

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


User Tag List

Similar Threads

  1. Replies: 87
    Last Post: 08-15-2021, 01:10 AM
  2. PI Pvp System
    By Dale123 in forum Help
    Replies: 6
    Last Post: 03-26-2012, 07:30 AM
  3. PvP System
    By Palidino in forum Show-off
    Replies: 99
    Last Post: 01-02-2010, 04:31 AM
  4. PvP System -Error
    By hitman in forum Help
    Replies: 5
    Last Post: 06-04-2009, 12:51 PM
  5. PvP System
    By CTucker in forum Requests
    Replies: 5
    Last Post: 02-10-2009, 05:43 PM
Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •