GithubHelp home page GithubHelp logo

phase / gameapi Goto Github PK

View Code? Open in Web Editor NEW
16.0 16.0 9.0 164 KB

:video_game: A minigame API that combines the Overcast Network & Mineplex game systems.

Home Page: http://jadonfowler.xyz/GameAPI

License: Other

Java 100.00%

gameapi's People

Contributors

phase avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

gameapi's Issues

Hey! It's not really issue but this is question

Hey!

I saw that you are actually doing on GameAPI. So, I want to ask you if you will release games like SuperPaintball, Death Tag, Snake,... to your github's account? I'll be happy to see you coding ๐Ÿ‘ !

Thanks for answer and enjoy in programming!

And my issue:

Ok :) I wrote down code into my eclipse and I have some errors :/

First error is .getVersion() in GameAPI.java:

public static boolean is1_8(Player p){
    return ((CraftPlayer) p).getHandle().playerConnection.networkManager.getVersion() >= 47;
}

The error sends me message "The method getVersion() is undefined for the type NetworkManager"
and I can only Add cast to method receiver, but it sends me bigger errors.

And second problem is connection.sendPacket in MessageManager.java:

public static void sendTitle(Player player, int fadeIn, int stay, int fadeOut, String title, String subtitle) {
    CraftPlayer craftPlayer = (CraftPlayer) player;

    if (!GameAPI.is1_8(player))
        return;

    IChatBaseComponent serializedTitle = ChatSerializer.a(TextConverter.convert(title));
    IChatBaseComponent serializedSubTitle = ChatSerializer.a(TextConverter.convert(subtitle));

            PlayerConnection connection = craftPlayer.getHandle().playerConnection;

    connection.sendPacket(new ProtocolInjector.PacketTitle(
            ProtocolInjector.PacketTitle.Action.TIMES, fadeIn, stay, fadeOut));
    connection.sendPacket(new ProtocolInjector.PacketTitle(
            ProtocolInjector.PacketTitle.Action.TITLE, (net.minecraft.server.v1_7_R4.IChatBaseComponent) serializedTitle));
    connection.sendPacket(new ProtocolInjector.PacketTitle(
            ProtocolInjector.PacketTitle.Action.SUBTITLE, (net.minecraft.server.v1_7_R4.IChatBaseComponent) serializedSubTitle));
}

The problems sends me a message "The method sendPacket(Packet) in the type PlayerConnection is not applicable for the arguments (ProtocolInjector.PacketTitle)"

I also have problem here:

public static void sendTabTitle(Player player, String header, String footer) {
    CraftPlayer craftPlayer = (CraftPlayer) player;
    if(!GameAPI.is1_8(player)) return;
    PlayerConnection connection = craftPlayer.getHandle().playerConnection;

    IChatBaseComponent header2 = ChatSerializer.a(new StringBuilder().append("{'text': '")
            .append(header).append("'}").toString());
    IChatBaseComponent footer2 = ChatSerializer.a(new StringBuilder().append("{'text': '")
            .append(footer).append("'}").toString());
    connection.sendPacket(new ProtocolInjector.PacketTabHeader());
}

This problem sends me a message "The method sendPacket(Packet) in the type PlayerConnection is not applicable for the arguments (ProtocolInjector.PacketTabHeader)"

Can you help please? Thanks!

Spectators

We need to add Spectators to games. I'd like to have them on the same NMS Team, so they can see each other as ghosts.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.