Jump to content



Photo

[JAVA]'else' without 'if' help please

java coding runescape else-if help please running out of words

  • Please log in to reply
3 replies to this topic

#1 Tyler Johnston

Tyler Johnston

    Resident One Post Wonder

  • Joined: 02-March 13

Posted 02 March 2013 - 08:13

The Error's I get when I compile.
src\org\dementhium\tickable\impl\PlayerAreaTick.java:35: error: 'else' without 'if'
    else if (World.getWorld().getAreaManager().getAreaByName("safepk2").contains(player.getLocation())) {
    ^
src\org\dementhium\tickable\impl\PlayerAreaTick.java:150: error: 'else' without 'if'
			 else if  (World.getWorld().getAreaManager().getAreaByName("Nex").contains(player.getLocation())); {
			 ^
src\org\dementhium\tickable\impl\PlayerAreaTick.java:153: error: 'else' without 'if'
			    } else {



#2 Tuishimi

Tuishimi

    Michinator

  • Joined: 19-November 10
  • OS: Windows 8

Posted 02 March 2013 - 08:38

Seeing the actual source code would be easier. Probably a mismatched paren or bracket.

#3 Torolol

Torolol

  • Joined: 24-November 12

Posted 02 March 2013 - 08:44

or perhaps you add ';' after "if (condtions)" into something like "if (condtions);"
which make the complier thinks the if part already ended.

#4 Tuishimi

Tuishimi

    Michinator

  • Joined: 19-November 10
  • OS: Windows 8

Posted 02 March 2013 - 08:46

or perhaps you add ';' after "if (condtions)" into something like "if (condtions);"
which make the complier thinks the if part already ended.


Oh yeah! I did not see that! after the getLocation...