Min and max functions

Started by MatosPoljca on

Topic category: Help with MCreator software

Last seen on 15:46, 18. Jan 2024
Joined Nov 2022

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Min and max functions
Sat, 01/13/2024 - 11:47 (edited)

I'm trying to make a certain variable that will have minimum and maximum values (for example 5 min and 20 max), but I have no idea how to do it. I will use it for damage, increased damage the longer you hold the bow (less hold, less damage, more hold more damage), but with limits (lower limit of 5 and upper limit of 20). I saw "min" and "max" in math blocks, but I don't know how to use them. It's the same block where other operations are (+, -, /, *, ^,...).

Edited by MatosPoljca on Sat, 01/13/2024 - 11:47
MIN and MAX blocks return…
Sun, 01/14/2024 - 16:44

MIN and MAX blocks return the smallest/MIN or biggest/MAX of the inputs

MIN(2, 5) gives 2

MAX(2, 5) gives 5