help: simple syntax error

Discussion in 'Plugin Development' started by Joager, Jun 9, 2014.

Thread Status:
Not open for further replies.
  1. Offline

    Joager

    I'm trying to create a stamina plugin but I'm stuck on this thing:

    Code:java
    1. {
    2. for (Player player : ) {
    3. if (player.isSprinting()) {
    4. player.setFoodLevel(player.getFoodLevel() - Main.this.getConfig().getInt("Food-subtracted-for-tick"));
    5. }


    it says that for (Player player : ) is wrong and that : has an expression expected after it

    What am I doing wrong?
     
  2. Offline

    MineCrashKoen

    So through what players do you want to iterate exactly?
     
Thread Status:
Not open for further replies.

Share This Page