Jump to content
  • 0

Question

Posted

Hi friends, i add voicecommand with custom locations and i want to know what line i need for Noblesse can teleport in zone? I try with activeChat.isNoble() but doesn't work. 

 

6 answers to this question

Recommended Posts

  • 0
Posted (edited)

Try this one.

 

            if (command.startsWith("easy"))
            {
                if (!activeChar.isNoble())
                {
                    activeChar.sendMessage("Only Noblesse players can teleport.");
                    return;
                }
                else
                {
                    activeChar.destroyItemByItemId("consume", 57, 50000, activeChar, true);
                    activeChar.teleToLocation(89006, 27373, -15691);
                    activeChar.sendMessage("You have teleported to easy farm zone");
                    _reuse.put(activeChar.getObjectId(), System.currentTimeMillis() + delay);
                }
            }

Edited by 'Baggos'
  • Upvote 1
  • 0
Posted
1 hour ago, InFocus said:

Hi friends, i add voicecommand with custom locations and i want to know what line i need for Noblesse can teleport in zone? I try with activeChat.isNoble() but doesn't work. 

 

Before the code for teleport put a check

        if (command.equals("teleportTo"))
        {

                if (!activeChar.isNoble())
                    activeChar.sendMessage("Only Noblesse players can teleport.");
            activeChar.teleToLocation(list, 0);

            activeChar.sendMessage("You have been teleported to " + list + ".");

        }

  • 0
Posted

Good job 'Baggos' i have a bit complicated code. Every zone is independent. I must add isNoble for each other. Or i don't know if i can make it for all. 

This is for 1 zone

if (command.startsWith("easy"))
			{
				activeChar.destroyItemByItemId("consume", 57, 50000, activeChar, true);
				activeChar.teleToLocation(89006, 27373, -15691);
				activeChar.sendMessage("You have teleported to easy farm zone");
				_reuse.put(activeChar.getObjectId(), System.currentTimeMillis() + delay);
			}

This is one. I have 3 more this config with 3 different zones. So i need the parameters for all in one

  • 0
Posted

I did now like that

if (command.startsWith("easy"))
			{
				if (!activeChar.isNoble())
				{
					activeChar.sendMessage("Only Noblesse players can teleport.");
				}
				activeChar.destroyItemByItemId("consume", 57, 50000, activeChar, true);
				activeChar.teleToLocation(89006, 27373, -15691);
				activeChar.sendMessage("You have teleported to easy farm zone");
				_reuse.put(activeChar.getObjectId(), System.currentTimeMillis() + delay);
			}

and i no have Noble status and work teleport. I want without noblesse, do not teleport :)

  • 0
Posted
11 hours ago, InFocus said:

nd i no have Noble status and work teleport. I want without noblesse, do not teleport

Then code with open eyes and active brain. If you check your code, you ONLY added a message. Why it's still processing the code? Bcs you did NOT add the return.

Guest
This topic is now closed to further replies.


  • Posts

    • Hello. WTS Adena on Reborn signature x1 and Items: have: DC robe set/Som+3 Acumen.   
    • Αν σε ενδιαφέρει ο κόσμος των κρυπτονομισμάτων και θέλεις να συζητάς, να μαθαίνεις, αλλά και να μοιράζεσαι γνώσεις με άλλους Έλληνες χρήστες, τότε σε προσκαλούμε στο νέο μας Telegram forum αποκλειστικά για την ελληνική crypto κοινότητα!   Συζητάμε για Bitcoin, altcoins, DeFi, trading, νέες τάσεις, NFTs, τεχνική ανάλυση και ό,τι άλλο αφορά τον κόσμο των crypto. Είτε είσαι αρχάριος είτε προχωρημένος, θα βρεις κάτι που σε ενδιαφέρει και μια παρέα που μιλάει τη γλώσσα σου – κυριολεκτικά!     Σύνδεσμος πρόσβασης:    https://t.me/investfuture_crypto_gr    ή   Scan QR Code:       Έλα να γίνουμε η πιο ενεργή ελληνική κοινότητα στο χώρο των crypto!
    • Αν σε ενδιαφέρει ο κόσμος των κρυπτονομισμάτων και θέλεις να συζητάς, να μαθαίνεις, αλλά και να μοιράζεσαι γνώσεις με άλλους Έλληνες χρήστες, τότε σε προσκαλούμε στο νέο μας Telegram forum αποκλειστικά για την ελληνική crypto κοινότητα!   Συζητάμε για Bitcoin, altcoins, DeFi, trading, νέες τάσεις, NFTs, τεχνική ανάλυση και ό,τι άλλο αφορά τον κόσμο των crypto. Είτε είσαι αρχάριος είτε προχωρημένος, θα βρεις κάτι που σε ενδιαφέρει και μια παρέα που μιλάει τη γλώσσα σου – κυριολεκτικά!     Σύνδεσμος πρόσβασης:    https://t.me/investfuture_crypto_gr    ή   Scan QR Code:       Έλα να γίνουμε η πιο ενεργή ελληνική κοινότητα στο χώρο των crypto!
    • ➡ Discount for your purchase: APRIL (10% discount) ➡ Our Online Shop: https://socnet.store  ➡ Our SMM-Boosting Panel: https://socnet.pro  ➡ Telegram Shop Bot: https://socnet.shop  ➡ Telegram Support: https://t.me/solomon_bog  ➡ Telegram Channel: https://t.me/accsforyou_shop  ➡ Discord Support: @AllSocialNetworksShop  ➡ Discord Server: https://discord.gg/y9AStFFsrh  ➡ WhatsApp Support: https://wa.me/79051904467 ➡ WhatsApp Channel: https://whatsapp.com/channel/0029Vau0CMX002TGkD4uHa2n  ➡ Email Support: solomonbog@socnet.store 
    • ➡ Discount for your purchase: APRIL (10% discount) ➡ Our Online Shop: https://socnet.store  ➡ Our SMM-Boosting Panel: https://socnet.pro  ➡ Telegram Shop Bot: https://socnet.shop  ➡ Telegram Support: https://t.me/solomon_bog  ➡ Telegram Channel: https://t.me/accsforyou_shop  ➡ Discord Support: @AllSocialNetworksShop  ➡ Discord Server: https://discord.gg/y9AStFFsrh  ➡ WhatsApp Support: https://wa.me/79051904467 ➡ WhatsApp Channel: https://whatsapp.com/channel/0029Vau0CMX002TGkD4uHa2n  ➡ Email Support: solomonbog@socnet.store 
  • Topics

×
×
  • Create New...