[LIB] Fanciful: pleasant chat message formatting

Discussion in 'Resources' started by mkremins, Nov 15, 2013.

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

    nverdier

  2. Offline

    jebbo

    Thanks, I already know such stuff. But I can't find a jar to use in Eclipse, I only read of Maven stuff.
     
  3. Offline

    jeroenhero123

    Looks like your domain name expired :C Any chance on adding the repo again?
    Really need it!
     
  4. Offline

    imaboy321

    Hey there. I was wondering if I should have Maven shade in the library since I don't see a download to put in the server plugins folder.
     
  5. Offline

    GamersForOne

    I imported the 2 packages mkremins.fanciful and net.amoebaman.util into my src folder. but I got a bunch of errors. I opened the files and saw that you import com.google.xxx.xxx.xxx but com.google doesn't exist. Have I missed a library or something? I use up-to-date Java 1.8 and Eclipse. Thanks in advance.

    EDIT: Solved it, craftbukkit.jar somehow got removed from the build path even though I added it. weird, but anyway, not a problem anymore :)
     
    Last edited: Jun 2, 2015
  6. Offline

    MiniDigger

    @GamersForOne use maven and never have such problems again <3
     
    nverdier likes this.
  7. Offline

    Scullyking

    @MiniDigger
    I'm able to import this library using Maven into my project (IntelliJ IDEA), and I'm able to use it fine. When I build my project, it's still all fine.

    However when the code executes in-game I get a ClassNotFoundException. This is really strange to me. Other maven dependancies (such as the Vault API) work fine. It's just this one!

    Any ideas?
     
  8. Offline

    crolemol

    @Scullyking
    include the sources into your jar using the maven shade plugin, it's recommend to relocate them.
     
  9. How Would I Do A Multi-Lined Hover Over? I'm Trying To Do It But Can't!
     
  10. Offline

    Eggspurt

    Is there a jar I can use rather then Maven? My Project is not setup for Maven...
     
  11. Offline

    matzefratze123

  12. Offline

    dznSpencer

    I'm getting errors using Fanciful.


     
  13. Offline

    MiniDigger

    @dznSpencer you don't have Gson. Either use the latest spigot build or include it yourselfes
     
  14. Offline

    Ricecutter0

    I've looked over the lastest messages, and I saw the latest version of 0.3.1 (I think)... And it still isn't registering..

    Code:
    <repositories>
            <repository>
                <id>bukkit-repo</id>
                <url>http://repo.bukkit.org/content/groups/public</url>
            </repository>
            <repository>
                <id>fanciful-mvn-repo</id>
                <url>http://repo.franga2000.com/artifactory/public</url>
            </repository>
        </repositories>
    
        <dependencies>
            <dependency>
                <groupId>org.bukkit</groupId>
                <artifactId>bukkit</artifactId>
                <version>1.7.2-R0.3</version>
            </dependency>
            <dependency>
                <groupId>mkremins</groupId>
                <artifactId>fanciful</artifactId>
                <version>0.3.1</version>
            </dependency>
        </dependencies>
    
        <build>
            <resources>
                <resource>
                    <directory>src/main/resources</directory>
                    <filtering>true</filtering>
                </resource>
            </resources>
        </build>
     
  15. Offline

    MiniDigger

    @Ricecutter0 that repo you are using seems to be down (or locked)
     
  16. Offline

    Ricecutter0

    @MiniDigger I'm using the one in the post. Which one works?
     
  17. Offline

    timmaker

    @mkremins The repo you are using seems to be locked or something
     
  18. Offline

    dznSpencer

    @MiniDigger I'm using maven to get the latest version. I've also added GSON as a dependecy but it's still not working. (I'm new to maven)
     
  19. Offline

    MiniDigger

    @Ricecutter0 there doesn't seem to be an updates repo around. I would suggest just downloading it and shading it into yourpackage.lib or something like this

    @dznSpencer if you want help from me you need to provide me with more informations: What are you trying to do? What did you do? What do you see now?
     
  20. Offline

    jmuirhead

    How do I broadcast a message to everyone? Here the code that i have so far.
    Code:
    Bukkit.getServer().getScheduler().scheduleSyncRepeatingTask(this, new Runnable() {
                            public void run() {
                             
                                new FancyMessage("Check out my website")
                                .color(ChatColor.GOLD)
                                .then("Click here.")
                                .style(ChatColor.UNDERLINE)
                                .color(ChatColor.BLUE)
                                .link("http://mywebsite.com!")
                                .tooltip("Got to my website!");                          
                               
                           
                            }
                    }, 3000, 12000);
    
     
  21. Offline

    bwfcwalshy Retired Staff

    @jmuirhead I haven't used Fanciful so I thought I'd just give you the json. Just use tellraw to send it to people.

    {text:"Check out my website ", color:"gold", extra:[{text:"click here!", underline:"true", color:"blue", hoverEvent:{action:"show_text", value:"Go to my website"}, clickEvent:{action:"open_url", value:"http://mywebsite.com"}}]}
     
  22. Offline

    megamichiel

    @jmuirhead
    If you're using an IDE, you could've checked what methods there are, and if not, you could've checked their source code. There is a method send(CommandSender) and a method send(Iterable<? extends CommandSender>)
     
  23. Offline

    Andavin

    So how do we use Fanciful with a Cauldron server? I wrote a plugin that uses Fanciful, but it errors in the Reflection class every time I use it on a Cauldron server. Is there a way to cut out the methods I don't use so that I don't have to use Reflection?
     
  24. Offline

    FabioZumbi12

    I using this LIB but i need to use the messages inline, like this result:
    [​IMG]

    Where on hover on a region name, open a tooltip and on click a name execute the command for that region.

    Or a way to send various FancyMessages in one message, separated by "," to get the resulto of the image?
     
  25. Offline

    TheOddPuff

    Hey,

    Does anyone know how the translationReplacements method works?
     
  26. Offline

    gal0511Dev

    Hello, i am having a problem with people clicking links
    this is my code:
    Code:
    new FancyMessage("[YT] " + p.getName()).color(ChatColor.RED).link(link).tooltip("Go to my YouTube channel.")
                                            .then(": " + e.getMessage()).color(ChatColor.WHITE).send(all);
    [​IMG]

    The clicking on the name works fine but if someone posts a link in chat it is unclickable.
     
  27. Offline

    phil14052

Thread Status:
Not open for further replies.

Share This Page