Posts by Minotorious

    glad you like it and find it useful :)


    That is true maybe I should add a small comment about the chat because many people seem to make that mistake with almost every plugin :D I hadn't so far because for me who knows how the game works is intuitive that all plugin commands go through the chat and the console is only for game commands :D


    Edit: added comment in the 1st post to inform people on using the chat for the plugin commands.

    Could you please post a screenshot of your filesystem for me to see what is going on in there? :)
    The filesystem should look like this:

    Code
    RisingWorld
    |___plugins
    | |___Portals
    | |___Portals.jar

    Also what do you mean by not working? Did you type for instance "/portal select" in the chat (not the console) and nothing happened?


    Also can you check in the Portals directory if an "assets" folder containing a database (named portals_worldName.db) has been created or not?

    can you post a screenshot of the full errors or better upload the server log from when they were caused?


    Red java errors in the chat are almost always plugin errors so maybe I can help with them or point you to the plugin creator to help with them :)

    I did some more testing and it appears that the .getItem() method returns the item that the item I am placing in the chest will be exchanged with.


    For instance:


    1) When I place a tomato in a chest's empty slot I get null from the .getItem() method.


    2) When I place a tomato in a chest's slot that already contains a plank then it returns the name of the plank.


    So it appears that the method returns the wrong item i.e. the one already in the chest and not the one being placed.


    I did some more testing now and it appears the .getExchangeItem() method returns the item that is being placed so the two methods (.getItem() and .getExchangeItem()) seem to be written the other way around. :/

    Diese Liste, glaube ich, ist aus der definitions.db Datenbank


    Pflanzen IDs aus der Datenbank:


    1fern1
    2flower1_s
    3flower1_m
    4flower1_l
    5flower2_s
    6flower2_m
    7flower2_l
    8flower3_s
    9flower3_m
    10flower3_l
    11flower4_s
    12flower4_m
    13flower4_l
    14flower5_s
    15flower5_m
    16flower5_l
    17flower6_s
    18flower6_m
    19flower6_l
    20scrub1
    21scrub1b
    22scrub2
    23scrub2b
    24seaplant_s
    25seaplant_m
    26seaplant_l
    27seaplant2
    28tubesponge
    30spruce1
    31spruce2
    32forestspruce1
    33forestspruce2
    34forestsprucedead
    35birch1
    36birch2
    37birch3
    38willow1
    39_willow2
    40_oak1
    41_oak2
    43_oakbig
    44maple1
    45maple2
    46appletree
    47cherrytree
    48lemontree1
    49_lemontree2
    50poplar
    51acacia1
    52acacia2
    53palm1
    56cactus1
    57cactus2
    58_cacao
    59mapledead
    60appletreedead1
    61appletreedead2
    62willowdead
    63mapleswamp1
    64mapleswamp2
    65mapleswamp3
    70_coffeetree
    71rowan1
    72rowan2
    73rowandead
    74_blueberry1
    75_blueberry2
    100tomato
    101tomato_sapling
    102tomato_s0
    103tomato_s1
    104tomato_s2
    105tomato_s3
    106carrot
    107carrot_sapling
    108carrot_s0
    110lettuce
    111lettuce_sapling
    112lettuce_s0
    113lettuce_s1
    114broccoli
    115broccoli_sapling
    116broccoli_s0
    117broccoli_s1
    118potato
    119potato_sapling
    120potato_s0
    121potato_s1
    122strawberry
    123strawberry_sapling
    124strawberry_s0
    125strawberry_s1
    126strawberry_s2
    127watermelon
    128watermelon_sapling
    129watermelon_s0
    130watermelon_s1
    131watermelon_s2
    132pumpkin
    133pumpkin_sapling
    134pumpkin_s0
    135pumpkin_s1
    136pumpkin_s2
    137welwitschia
    140hemp
    141hemp_sapling
    142hemp_s0
    143hemp_s1
    145cotton
    146cotton_sapling
    147cotton_s0
    148cotton_s1
    149cotton_s2
    150cotton_s3
    151corn
    152corn_sapling
    153corn_s0
    154corn_s1
    155corn_s2
    156corn_s3
    157corn_s4
    158sugarbeet
    159sugarbeet_sapling
    160sugarbeet_s0
    161sugarbeet_s1
    162hogweed1
    170nettle1
    171nettle2
    176chili
    177chili_sapling
    178chili_s0
    179chili_s1
    180chili_s2
    181chili_s3
    500spruce_sapling
    501spruce_s0
    504birch_sapling
    505birch_s0
    506willow_sapling
    507willow_s0
    510maple_sapling
    511maple_s0
    512appletree_sapling
    513appletree_s0
    514appletree_s1
    518lemontree_sapling
    519lemontree_s0
    520lemontree_s1
    521acacia_sapling
    522_acacia_s0
    523cactus_sapling
    524cactus_s0
    525palm_sapling
    526palm_s0
    527poplar_sapling
    528poplar_s0
    529cherrytree_sapling
    530cherrytree_s0
    531cherrytree_s1
    532cherrytree_s2

    hey @red51


    I tried to use the PlayerInventoryToChestEvent and I always get null when using the .getItem() method.


    This is how I tested it:


    This code snippet always prints "item is null"


    Edit: also just noticed there is a small mistake in the description of the getExchangeItem() method in the same event. Where it says: "Returns null if there is no exchange item (i.e. when the player moves the item to an empty slot in his inventory)." I think it should say: "Returns null if there is no exchange item (i.e. when the player moves the item to an empty slot in the chest)."

    du kannst getServer().broadcastTextMessage(sign.getLineText(1)) und getServer().broadcastTextMessage(sign.getLineText(1).toString) probieren und schau was es im chat gibt, dann nutz das "Ergebnis" für sign.getLineText(1).equals("Ergebnis") :P