#(marcus) Shop NPC with fresh items every day
31 messages · Page 1 of 1 (latest)
(marcus) Shop NPC with fresh items every day
Hi I'm AutoThreadBot! Don't mind me, I'll just be adding the helper team to this thread so they can see it. A human will get to you soon.
!chatgpt
No, ChatGPT cannot write working scripts.
ChatGPT is known to often be "confidently wrong", meaning- It will try, it will output something that looks like a script, it will assure you it works, and it will not work.
ChatGPT is a cool tool, and it can do a lot of cool things, but it is not sufficiently intelligent enough to write working code as of yet, especially not in smaller languages like Denizen script (as opposed to huge languages like C or Python).
(GitHub Copilot, which supplies single lines at a time based on the surrounding code you've already written, can sometimes be accurate and helpful).
View the Denizen Beginner's Guide at https://guide.denizenscript.com/
Forgot the command 💔
But yeah if you explain what you're trying to do we'd be glad to help you
Also please use the paste site to share scripts
!haste
Help us help you by pasting your script to https://paste.denizenscript.com/New/Script and linking it back here.
so i want to make an npc shop which gives you 5 blueprints every day then after a day it gives you another 5. like a fortnite item shop, so the trades cycle
one script works as far as i know, the plugin loads that one
Script working != optimal code/performance
here's the script https://paste.denizenscript.com/View/133429
Content of YAML Paste #133429: Unnamed YAML Paste... pasted 2025/05/18 04:34:26 UTC-07:00, Paste length: 5361 characters across 128 lines, Content: black_market_setup: type: task script: - define rare_items li@
The way I'd set this up would probably be with a server flag map (ie you'd store all the possible items you want to populate the shop and the data you need about them (eg quantity, price etc))
Then just pull 5 random keys from that map daily, store it in a separate flag and have the npc shop display those
If you want item rarity etc you could use chances/weight system
Unfortunately I'm on phone so I can't go into much detail or give you an example but if you provide a detailed explanation of how you want the shop to work someone will help you eventually :)
Ok, thank you. So I have a mohist 1.20.1 server. I configurated the loot on my server, so powerful gun blueprints (eg, epic, legendary) doesn't spawn that often. So I came up with an idea, that an NPC could sell these blueprints i excluded from the lootpool. You could buy 2 rare, 1 epic, 1 legendary and 1 container (container is a deployable cannon, anti air etc), so five alltogether. The shop would refresh every day with new blueprints in each category.
Our plugins (Citizens, Sentinel, and Denizen) officially support both Spigot and Paper.
Any other forks of the Bukkit project are not supported, but may or may not work in practice.
-
Lower forks, like CraftBukkit, do not function. You must upgrade to a higher fork (Spigot or Paper).
-
Hard forks and cross-forks, like Cauldron/Magma/Mohist/Any other Forge-integration fork, or Cardboard/any other Fabric-integration fork, will not work. Some unofficial custom builds of Citizens are made to support these servers, but we cannot provide any support for them here.
-
Higher forks above Spigot/Paper, such as Purpur, Airplane, etc. are compatible with Citizens only as much as they are compatible with Spigot/Paper. They are generally expected to work in most cases, but we cannot make any guarantees. We will still offer support to users running such forks, but be aware that if you encounter bugs while running such a fork, we may ask you to replicate them on Spigot/Paper to confirm they aren't caused by changes the fork made.
Has your issue been resolved, or your question been answered?
If so, please use the </resolved:1028673926114594866> command to close your thread.
Or </invalid:1028673926898909185> if it's not possible to resolve.
If not yet resolved, please reply below to tell us what you still need.
(Note that if there is no reply for a few days, this thread will eventually close itself.)
@astral hill