Otázky na script

Technická podpora k herním serverům Minecraft a Tekkit
Message
Autor
Uživatelský avatar
Ritchy
Příspěvky: 219
Registrován: 07 čer 2016, 17:14
Reputation: 2

Otázky na script

#1 Příspěvekod Ritchy » 24 bře 2018, 18:15

Zdravím,
Používám tento skript:

Kód: Vybrat vše


#  ___                _               
# |_ _|  _ __     __| |   ___  __  __
#  | |  | '_ \   / _` |  / _ \ \ \/ /
#  | |  | | | | | (_| | |  __/  >  <
# |___| |_| |_|  \__,_|  \___| /_/\_\
#
#

options:
   prefix: &a&lVotePoins&r &7»&r
   version: 1.1
   
on first join:
   set {coins::%player%} to 0
   
#  ___  _____  ____  _  _  ___
# / __)(  _  )(_  _)( \( )/ __)
#( (__  )(_)(  _)(_  )  ( \__ \
# \___)(_____)(____)(_)\_)(___/
#

command /vp [<text>] [<player>] [<int>]:
   description: Help for skCoins.
   usage: /coins (add:remove:set:reset) (player) (value)
   executable by: players and console
   trigger:
      if arg-1 is not set:
         send ""
         send " &a&lVotePointy"
         send ""
         send " &8● &7/vp add (player) (value) &a- Add player's coins"
         send " &8● &7/vp remove (player) (value) &a- Remove player's coins"
         send " &8● &7/vp set (player) (value) &a- Set player's coins"
         send " &8● &7/vp reset (player) &a- Reset player's coins"
         send ""
      if arg-1 is set:
         if player has permission "coins.admin":
            if arg-1 is "add":
               if arg-2 is not set:
                  send " &aCorrect Usage: &7/coins add (player) (value)"
               if arg-2 is set:
                  if arg-3 is not set:
                     send " &aCorrect Usage: &7/coins add (player) (value)"
                  if arg-3 is set:
                     add arg-3 to {coins::%arg-2%}
                     send " {@prefix} &7Operation completed successfully!"
                     send " {@prefix} &7You have recived &a%arg-3%&7 coins." to arg-2
            if arg-1 is "remove":
               if arg-2 is not set:
                  send " &aCorrect Usage: &7/coins remove (player) (value)"
               if arg-2 is set:
                  if arg-3 is not set:
                     send " &aCorrect Usage: &7/coins remove (player) (value)"
                  if arg-3 is set:
                     remove arg-3 from {coins::%arg-2%}
                     send " {@prefix} &7Operation completed successfully!"
                     send " {@prefix} &7You have lost &a%arg-3%&7 coins." to arg-2
            if arg-1 is "set":
               if arg-2 is not set:
                  send " &aCorrect Usage: &7/coins set (player) (value)"
               if arg-2 is set:
                  if arg-3 is not set:
                     send " &aCorrect Usage: &7/coins set (player) (value)"
                  if arg-3 is set:
                     set {coins::%arg-2%} to arg-3
                     send " {@prefix} &7Operation completed successfully!"
                     send " {@prefix} &7You have now &a%arg-3%&7 coins." to arg-2
            if arg-1 is "reset":
               if arg-2 is not set:
                  send " &aCorrect Usage: &7/coins reset (player)"
               if arg-2 is set:
                  set {coins::%arg-2%} to 0
                  send " {@prefix} &7You reset &a%arg-2%&7's coins!"
                  send " {@prefix} &7Your coins have been reset." to arg-2
         if player does not have permission "coins.admin":
            send " &cNemas prava."
                  
command /votepoints [<offlineplayer>]:
   description: Ukaze hracuv balanc.
   usage: /vp <player>
   executable by: players and console
   trigger:
      if arg-1 is not set:
         send " {@prefix} &7Mas na uctu: &a%{coins::%player%}%&7."
      if arg-1 is set:
         send " {@prefix} &a%arg-1%&7 ma na uctu: &a%{coins::%arg-1%}%&7."

A mám 2 otázky:
1. Lze nějak udělat abych měl placeholder ve FeatherBoardu kolik má hráč počet votepoints?
2. Lze nějak skript napojit na MySQL? Vím že ano, ale nenašel jsem jak. NAPOJENO

(Pokud někdo má blbé odpovědi jako že se mám naučit Javu, ať ani nepíše :))
Nezapomeň mi dát K+, pokud jsem ti pomohl! :)

Uživatelský avatar
TopCz
Příspěvky: 667
Věk: 26
Registrován: 15 led 2014, 21:00
Reputation: 11
Kontaktovat uživatele:

Re: Otázky na script

#2 Příspěvekod TopCz » 25 bře 2018, 13:16

Pohybuji, script placeholders neumí ...
Obrázek

Uživatelský avatar
Ritchy
Příspěvky: 219
Registrován: 07 čer 2016, 17:14
Reputation: 2

Re: Otázky na script

#3 Příspěvekod Ritchy » 25 bře 2018, 17:34

Nějaký addon podle mě určitě existuje, ale dík za odpověď :)
Nezapomeň mi dát K+, pokud jsem ti pomohl! :)

ZiDyPL
Příspěvky: 295
Registrován: 13 dub 2015, 22:01
Reputation: 17

Re: Otázky na script

#4 Příspěvekod ZiDyPL » 30 bře 2018, 18:14

Myslím že PlaceholderAPI má možnost skript proměnných - takže asi {coins::%player%} (možná to není %player% - najdi si to na googlu jak to je, mně se teď nechce).


Zpět na „Minecraft, Tekkit“

Kdo je online

Uživatelé prohlížející si toto fórum: Žádní registrovaní uživatelé a 119 hostů