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


    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.

    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.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;

    public class 
    TabMenu extends JavaPlugin implements Listener{
    void onEnable(){

    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': '', '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.

    Last edited: Mar 29, 2015
  2. Offline

    timtower Moderator Moderator

    Moved to Bukkit alternatives.
  3. Offline


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


    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


    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