Thread: [HELP] 1 Error when adding objects with cases [HELP]

Results 1 to 4 of 4
  1. #1 [HELP] 1 Error when adding objects with cases [HELP] 
    Registered Member
    Join Date
    Oct 2010
    Posts
    68
    Thanks given
    7
    Thanks received
    2
    Rep Power
    1
    Hey Rune-Server,

    I'm using DevastationRS as base, and I'm adding CastleWars to it, which shouldn't be difficult because it's exactly the same as CreativeScape, so infact it's just copy & paste.

    Now when i'm in "ObjectClick.java" I'm trying to add the doors, flags etc. all those objects you need to play CastleWars

    When I try to add 1 single item to CastleWars I get this error:
    Code:
    server\model\player\packet\ObjectClick.java:3794: orphaned case
            case 4465: // sara small doors
            ^
    1 error
    Press any key to continue . . .
    If I'm right this means the case is already in use right?

    This is the case I've been trying to add:
    Code:
    case 4465: // sara small doors
    		if(client.SaraPlayer){
    		if(client.isBusy()){
    			return;
    		}
    		client.setBusy(true);
    			Server.getCastleWars().SaraDoorsOpen = false;
    			client.getActionAssistant().startAnimation(881);
    		final Client csadad = client;
    		EventManager.getSingleton().addEvent(null, new Event() {
    			public void execute(EventContainer c) {
    				Server.getCastleWars().processor();
    				csadad.setBusy(false);
    				c.stop();
    			}
    
    			@Override
    			public void stop() {
    			}
    		}, 2000);
    		} else {
    			client.getActionAssistant().sendMessage("These doors seem to be locked.");
    		}
    		break;
    Please tell me what I'm doing wrong?
    I already tried searching with Notepad++ in CreativeScape and DevastationRS on "4465" and compared everything, the CastleWars class is EXACTLY the same, really no difference, and all the other things don't have to do anything with CastleWars exept ObjectClick.java...

    If anyone can help me.. Please

    Grz. Yannick
    Reply With Quote  
     

  2. #2  
    Registered Member
    bracket's Avatar
    Join Date
    Aug 2009
    Posts
    5,278
    Thanks given
    1,059
    Thanks received
    1,465
    Rep Power
    5000
    you miss a } on the end or have one to much
    Reply With Quote  
     

  3. #3  
    Registered Member
    Join Date
    Oct 2010
    Posts
    68
    Thanks given
    7
    Thanks received
    2
    Rep Power
    1
    Quote Originally Posted by owner pkin View Post
    you miss a } on the end or have one to much
    Nope I just checked with Notepad++, the bracket becomes red with the bracket it's connected to, and all of them are connected right to each other..

    EDIT: Also note the cases I copy are exact the same as in CreativeScape.. in CreativeScape they just work, and DevastationRS is based of Creativescape... that's why I didn't understand
    Last edited by waaawywlad; 10-30-2010 at 02:33 PM. Reason: extra note
    Reply With Quote  
     

  4. #4  
    Registered Member
    Its paris's Avatar
    Join Date
    Apr 2009
    Posts
    1,141
    Thanks given
    56
    Thanks received
    234
    Rep Power
    689
    It's not that you're missing one, it's that the whole case is outside the switch statement.
    Check the ending bracket from the switch statement. I'm sure the case comes behind it.
    Reply With Quote  
     


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. Link cases with the baby cases
    By buck in forum Help
    Replies: 8
    Last Post: 08-20-2009, 08:22 AM
  2. Replies: 7
    Last Post: 07-19-2009, 06:08 PM
  3. Replies: 8
    Last Post: 07-02-2009, 09:20 AM
  4. [317]Adding cases[317]
    By happyisbackk in forum Requests
    Replies: 0
    Last Post: 06-24-2009, 09:01 AM
  5. Making Objects Cases
    By sarah101 in forum Tutorials
    Replies: 6
    Last Post: 05-15-2007, 09:34 AM
Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •