Need help please!

  • Welcome to skUnity!

    Welcome to skUnity! This is a forum where members of the Skript community can communicate and interact. Skript Resource Creators can post their Resources for all to see and use.

    If you haven't done so already, feel free to join our official Discord server to expand your level of interaction with the comminuty!

    Now, what are you waiting for? Join the community now!

  • LOOKING FOR A VERSION OF SKRIPT?

    You can always check out skUnity Downloads for downloads and any other information about Skript!

Status
Not open for further replies.

Viiral

New Member
Apr 26, 2019
9
0
0
19
England
Layout:

Skript Version (do not put latest): Skript 2.2 (dev25)
Skript Author: Bensku
Minecraft Version: 1.8
---
I basically just want to know how you put a lore on a item where the ' if player's held item is a chest named "&d&lRANDOM SPECIAL PEICE '&f&lPHANTOM&d&l'":' line please reply

Code (Skript):

on rightclick:
if player's held item is a chest named "&d&lRANDOM SPECIAL PEICE '&f&lPHANTOM&d&l'":
cancel event
remove 1 chest named "&d&lRANDOM SPECIAL PEICE '&f&lPHANTOM&d&l'" from player
set {_chance} to a random integer between 1 and 200
if {_chance} is between 1 and 50:
make console execute command "/ea givearmor %player% Phantom Helmet"
if {_chance} is between 51 and 100:
make console execute command "/ea givearmor %player% Phantom Chestplate"
if {_chance} is between 101 and 150:
make console execute command "/ea givearmor %player% Phantom Leggings"
if {_chance} is between 151 and 200:
make console execute command "/ea givearmor %player% Phantom Boots"

Errors on Reload:

Code (Skript):
  1. No errors
Console Errors: (if applicable)

Code (Skript):
  1. No console errors
 
If you have SkQuery (version must be below Recode and .2.3 Skript), you can use
Code:
%item% with lore %string%
PS Thanks for the links to Skript, I didn't know what that was
 
Layout:

Skript Version (do not put latest): Skript 2.2 (dev25)
Skript Author: Bensku
Minecraft Version: 1.8
---
I basically just want to know how you put a lore on a item where the ' if player's held item is a chest named "&d&lRANDOM SPECIAL PEICE '&f&lPHANTOM&d&l'":' line please reply

Code (Skript):

on rightclick:
if player's held item is a chest named "&d&lRANDOM SPECIAL PEICE '&f&lPHANTOM&d&l'":
cancel event
remove 1 chest named "&d&lRANDOM SPECIAL PEICE '&f&lPHANTOM&d&l'" from player
set {_chance} to a random integer between 1 and 200
if {_chance} is between 1 and 50:
make console execute command "/ea givearmor %player% Phantom Helmet"
if {_chance} is between 51 and 100:
make console execute command "/ea givearmor %player% Phantom Chestplate"
if {_chance} is between 101 and 150:
make console execute command "/ea givearmor %player% Phantom Leggings"
if {_chance} is between 151 and 200:
make console execute command "/ea givearmor %player% Phantom Boots"

Errors on Reload:

Code (Skript):
  1. No errors
Console Errors: (if applicable)

Code (Skript):
  1. No console errors
I'm not sure but try something like this:
code_language.skript:
on right click:
   set {_chest} to chest
   set line 1 of lore of {_chest} to "&d&lRANDOM SPECIAL PEICE '&f&lPHANTOM&d&l'"
    if event-player's held item is {_chest}:
        cancel event
        remove event-item from event-player's inventory
        set {_chance} to random integer between 1 and 200
        if {_chance} is between 1 and 50:
            execute console command "/ea givearmor %event-player% Phantom Helmet"
        else if {_chance} is between 51 and 100:
            execute console command "/ea givearmor %event-player% Phantom Chestplate"
        else if {_chance} is between 101 and 150:
            execute console command "/ea givearmor %event-player% Phantom Leggings"
        else if {_chance} is between 151 and 200:
            execute console command "/ea givearmor %event-player% Phantom Boots"
(The truth, not understanding your request)
 
PS Thanks for the links to Skript, I didn't know what that was
Its an automated feature on this forum, sometimes when you type Skript automatically creates a link to the wiki.
Its very annoying haha..
Also they copied the help request format, thats why those links are there
 
Status
Not open for further replies.