Having Trouble with my Skill Point System

Started by VenusUltimatum on Sat, 08/29/2020 - 19:58

Topic category: Help with modding (Java Edition)

Last seen on 15:07, 3. Oct 2020
Joined Jul 2017
User points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
Having Trouble with my Skill Point System
Sat, 08/29/2020 - 19:58

So I have this procedure that says:
- Upon Trigger
     - If: ((Has [Target Entity] completed achievement [Quick Get Away]) = [false]) AND (get: SkillPoints > 0)
          - Do: Give player achievement: [Quick Get Away]
                   Set [SkillPoints] = [SkillPoints] - 1
          - Else: Set player hunger level to 1 //For tests

So upon pushing a button in a GUI, that triggers this procedure. I've tested this and many other variations, but the result still comes out the same. Even when I have the advancement, the skill points still changes, even though my hunger changes as well. I figured the AND gate would have solved it but even after adding it in, it still changes. I have a video of it in game, just not sure how to upload it to this. Would anyone be able to help with this?

Last seen on 07:56, 26. Oct 2020
Joined Jun 2020
User points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
Can you screenshot your…
Sun, 08/30/2020 - 05:48

Can you screenshot your procedures from now on, rather than typing it out? Lol, it's a bit harder to understand in text, but it's use-able for now. But we need a bit more information. What's this "SkillPoints" variable, and what format is it? What type is it? Also, you don't need to check if the completed achievement is false. It returns that on it's own. If they have it, it will return true. If not, it will return false. And an if statement cannot run both the "do" and the "else", so both functions should not be running. Please just give the information I asked for, and any extra you can, and we'll do what we can to help.

Last seen on 15:07, 3. Oct 2020
Joined Jul 2017
User points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
I do have a screenshot of…
Sun, 08/30/2020 - 17:39

I do have a screenshot of the procedure, though when I go to upload it to a post, all it asks for is a url so I don't know how I would go about uploading it from my computer. If you could help me with that, it would be greatly appreciated.// SkillPoints is just a playerbound global number variable.// I thought it would return properly, though when I tested it, it would continue to change so I though maybe I had to specify it because sometimes that happens.// For the if statement, I understand that it shouldn't run both but it's happening and I don't know how to fix it.

I'll get the screen shot uploaded, and possibly the video as well once I figure out how to do so. I appreciate the help.

Last seen on 15:07, 3. Oct 2020
Joined Jul 2017
User points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
(No subject)
Sun, 08/30/2020 - 17:44

This is my skill point procedure

Last seen on 15:07, 3. Oct 2020
Joined Jul 2017
User points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
Rip, that didn't work. Let…
Sun, 08/30/2020 - 17:48

Rip, that didn't work. Let me try this one.This is my skill point procedure