• Trong thời gian này, bạn không thể tạo bài mới, đăng comment, hay tạo tài nguyên mới để diễn đàn dọn dẹp nội dung.
    Diễn đàn sẽ sớm mở trở lại, chi tiết hãy theo dõi tại Discord
DavidAnh

Chuyển Từ Item Sang Points

  • Người tạo chủ đề Người tạo chủ đề DavidAnh
  • Ngày gửi Ngày gửi
Tôi đang làm đổi từ item sang points mà khi rename thì nó lại ko nhận item config
nè
items:
'1':
material: ghast_tear
slot: 11
display_name: '&f[&e$&f] Đồng &b10&f point [&e$&f]'
data: 0
lore:
- "&8• &fNhận 1 &eĐồng 10 point"
- "&8• &b-10 point &fvào tài khoản"
left_click_requirement:
requirements:
anything_here:
type: '>='
input: '%playerpoints_points%'
output: '10'
deny_commands:
- '[message] &6Shop &8> &fMày cần &c10 Points &fđể mua, OK?'
left_click_commands:
- '[console] points take %player_name% 10'
- '[console] give %player_name% ghast_tear 1 name:&f[&e$&f]_Đồng_&b10&f_point_[&e$&f] lore:&b●&f_Vật_chất_&eleo_thang|&b●_&fGiá_xăng_&ctăng_giá'
right_click_requirement:
requirements:
haveD10P:
type: javascript
expression: '"%checkitem_mat:ghast_tear_amt:1_nameequals:&f[&e$&f]_Đồng_&b10&f_point_[&e$&f]%".equals("yes");'
deny_commands:
- '[close]'
- '[message] &cKhông đủ item.'
right_click_commands:
- '[console] points give %player_name% 10'
- '[console] clear %player_name% ghast_tear 1 name:&f[&e$&f]_Đồng_&b10&f_point_[&e$&f]'
- '[message] &3Đã bán thành công &f[&e$&f]_Đồng_&b10&f_point_[&e$&f] &ex1.'
 
Tôi đang làm đổi từ item sang points mà khi rename thì nó lại ko nhận item config
nè
items:
'1':
material: ghast_tear
slot: 11
display_name: '&f[&e$&f] Đồng &b10&f point [&e$&f]'
data: 0
lore:
- "&8• &fNhận 1 &eĐồng 10 point"
- "&8• &b-10 point &fvào tài khoản"
left_click_requirement:
requirements:
anything_here:
type: '>='
input: '%playerpoints_points%'
output: '10'
deny_commands:
- '[message] &6Shop &8> &fMày cần &c10 Points &fđể mua, OK?'
left_click_commands:
- '[console] points take %player_name% 10'
- '[console] give %player_name% ghast_tear 1 name:&f[&e$&f]_Đồng_&b10&f_point_[&e$&f] lore:&b●&f_Vật_chất_&eleo_thang|&b●_&fGiá_xăng_&ctăng_giá'
right_click_requirement:
requirements:
haveD10P:
type: javascript
expression: '"%checkitem_mat:ghast_tear_amt:1_nameequals:&f[&e$&f]_Đồng_&b10&f_point_[&e$&f]%".equals("yes");'
deny_commands:
- '[close]'
- '[message] &cKhông đủ item.'
right_click_commands:
- '[console] points give %player_name% 10'
- '[console] clear %player_name% ghast_tear 1 name:&f[&e$&f]_Đồng_&b10&f_point_[&e$&f]'
- '[message] &3Đã bán thành công &f[&e$&f]_Đồng_&b10&f_point_[&e$&f] &ex1.'
tại sao dùng javacript để check ? dùng string equals ignorecase
- '[console] clear %player_name% ghast_tear 1 name:&f[&e$&f]_Đồng_&b10&f_point_[&e$&f]'
thành
- '[console] minecraft:clear %player_name% ghast_tear 1 name:&f[&e$&f]_Đồng_&b10&f_point_[&e$&f]'
hoặc dùng placeholder để check
và nhớ /papi ecloud download Javacript
/papi reload
dùng /papi ecloud download checkitem
/papi reload
 
tại sao dùng javacript để check ? dùng string equals ignorecase
- '[console] clear %player_name% ghast_tear 1 name:&f[&e$&f]_Đồng_&b10&f_point_[&e$&f]'
thành
- '[console] minecraft:clear %player_name% ghast_tear 1 name:&f[&e$&f]_Đồng_&b10&f_point_[&e$&f]'
hoặc dùng placeholder để check
và nhớ /papi ecloud download Javacript
/papi reload
dùng /papi ecloud download checkitem
/papi reload
vẫn ko đc khi dùng javacript nó check sai với dùng string equals thì ko remove item
 
Nội dung tương tự Xem nhiều nhất Xem thêm

Thống kê nội dung

Tạo
DavidAnh,
Trả lời lần cuối từ
Huy12345,
Trả lời
5
Lượt xem
558
Quay lại
Trên cùng