Player damage! HELP

Discussion in 'Plugin Development' started by Nicster189, Jul 29, 2013.

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

    Nicster189

    Hello! I am new to making plugins, I have already written a simple plugin but now I'm working on something else! But when I type player.damage(1); It gets a yellow line under it and there is a black line going through it! I would love it if someone could help me. (Maybe tell me how to re write the line as player.damage(1); doesn't want to work) Is there another line for it? Sorry if it has alredy been said but i have been searching for a day now with no luck :( . Thanks for reading.

    -Nicster189
     
  2. Offline

    np98765

    Moved to Plugin Development.
     
  3. Offline

    Vislo

    When 1.6 comes out Bukkit changes the health objects integer to double / float. The yellow thing means is deprecated and in the future that function is going to be remove but still workings in the present.
    To solve this just change the number to a float.
    Example:
    player.damage(1f);
    Or using the Java Cast System
     
    Nicster189 likes this.
  4. Offline

    Nicster189

    Thanks dude!
     
Thread Status:
Not open for further replies.

Share This Page