Development Assistance Importing problem SCREENSHOT

Discussion in 'Plugin Help/Development/Requests' started by Thunderbolt_316, Mar 29, 2015.

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

    Thunderbolt_316

    Ok so I am making a TABLIST plugin & at the very bottom I try to import ProtocolInjector but it says "ProtocolInjector cannot be resolved to a type"
    I'm using Spigot-1.8.
    PHP:
    package plugin.tab.menu;

    import net.minecraft.server.v1_8_R1.ChatSerializer;
    import net.minecraft.server.v1_8_R1.IChatBaseComponent;
    import net.minecraft.server.v1_8_R1.PlayerConnection;

    import org.apache.logging.log4j.core.net.Protocol;
    import org.bukkit.Bukkit;
    import org.bukkit.craftbukkit.v1_8_R1.entity.CraftPlayer;
    import org.bukkit.entity.Player;
    import org.bukkit.event.EventHandler;
    import org.bukkit.event.Listener;
    import org.bukkit.event.player.PlayerJoinEvent;
    import org.bukkit.plugin.java.JavaPlugin;

    public class 
    TabMenu extends JavaPlugin implements Listener{
      
        public 
    void onEnable(){
            
    Bukkit.getPluginManager().registerEvents(thisthis);
        }

        @
    EventHandler
        
    public void onPlayerConnect(PlayerJoinEvent e){
            
    Player p e.getPlayer();
          
            
    PlayerConnection connection = ((CraftPlayerp).getHandle().playerConnection;
            
    IChatBaseComponent top ChatSerializer.a("{'extra': [{text: 'Gaming', color: 'red', bold: 'true'}],'color': 'purple', 'bold': 'true', 'text': 'Eclipse'}");
            
    IChatBaseComponent bottom ChatSerializer.a("{'extra': [{'color': 'orange', 'text': 'eclipse-mc-gaming.enjin.com', 'underlined': 'true'}], 'color': 'aqua', 'text': 'Sign up on the website - '}");
          
            
    connection.sendPacket(new ProtocolInjector.PacketTabHeader(top,bottom));
        }
    }
    That's the only problem then I export & it just gives errors & doesn't work.

    [​IMG]
     
    Last edited: Mar 29, 2015
  2. Offline

    timtower Moderator Moderator

    Moved to Bukkit alternatives.
     
  3. Offline

    Thunderbolt_316

    Ok thank you kind of new to the website.
     
  4. Offline

    Kainzo

    Which version of 1.8 are you using?

    import net.minecraft.server.v1_8_R1.ChatSerializer <<<< if you're on 1.8.3 - this wont work.

    It looks like this is the new function, but you'll have to look around a bit.
    import net.minecraft.server.v1_8_R2.IChatBaseComponent;
     
    Last edited: Mar 29, 2015
  5. Offline

    Thunderbolt_316



    Spigot 1.8.1
    I did the Buildtools thing from Spigot mc and did 1.8


    I'll add screenshot of the redline & what it says
     
    Last edited by a moderator: Mar 29, 2015
Thread Status:
Not open for further replies.

Share This Page