Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
MythicMobs MythicMobs
  • Project overview
    • Project overview
    • Details
    • Activity
  • Issues 144
    • Issues 144
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Operations
    • Operations
    • Incidents
  • Analytics
    • Analytics
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • Members
    • Members
  • Activity
  • Create a new issue
  • Issue Boards
Collapse sidebar
  • MythicCraft
  • MythicMobsMythicMobs
  • Wiki
    • Skills
  • Math

Math · Changes

Page history
added clamp authored Nov 10, 2024 by Lxlp's avatar Lxlp
Hide whitespace changes
Inline Side-by-side
Showing with 8 additions and 8 deletions
+8 -8
  • Skills/Math.md Skills/Math.md +8 -8
  • No files found.
Skills/Math.md
View page @ d79309e3
Lets you make simple or advanced calculations. Any placeholders that returns a number is supported.
You can use math in most places that supports placeholders.
Operators
-----------
[[_TOC_]]
## Operators
Most of these operators can be found here https://www.objecthunter.net/exp4j/#Built-in_operators
#### Math Operators
### Math Operators
| Operator | Description | Example |
|:--------:|:----------------:|:---------:|
......@@ -15,7 +16,7 @@ Most of these operators can be found here https://www.objecthunter.net/exp4j/#Bu
| ^ | Power | 2 ^ 2 |
| % | Remainder | 2 % 2 |
#### Boolean Operators
### Boolean Operators
| Operators | Description | Example |
|:---------:|:------------------------:|:-------:|
| \< | Less than | 2<5 |
......@@ -27,8 +28,7 @@ Most of these operators can be found here https://www.objecthunter.net/exp4j/#Bu
*Boolean operators will return `1` if the expression is true and `0` if it's false.*
Functions
---------
## Functions
Most of these functions can be found here https://www.objecthunter.net/exp4j/#Built-in_functions
| Function | Description |
......@@ -61,12 +61,12 @@ Most of these functions can be found here https://www.objecthunter.net/exp4j/#Bu
| max(x, y) | maximum |
| atan2(y, x) | principal value of the arc tangent of y/x, expressed in radians |
| random(min, max) | random with limits |
| clamp(value, min, max) | Clamps a number between a given minimum and maximum. If the number you provide is less than the minimum, it will return the minimum. If it's greater than the maximum, it returns the maximum. If it's between the minimum and maximum, it returns the number unchanged |
NOTE: You can request to add more operators and functions by making a suggestion ticket in our [issues page](https://git.mythiccraft.io/mythiccraft/MythicMobs/-/issues)
Example Usage
------------
## Example Usage
```yml
MyCoolMob:
Type: HUSK
......
Clone repository
Home
Changelogs
Premium Features
Commands and Permissions
Mythic Add-ons
Compatible Plugins
API Information

MythicScribe MythicScribe
Guides
  • Troubleshooting
  • FAQ / Common Issues
  • Examples
Packs

Mobs
  • Mob Options
    • Display Options
  • Mob Levels
  • Mob Factions
  • Power Scaling
  • Damage Modifiers
  • Equipment
  • BossBar
  • Custom AI
  • Custom Kill Messages
  • Threat Tables
  • Immunity Tables
  • Templates
  • Vanilla Overrides
  • Extra: Disguises
  • Extra: ModelEngine
Skills
  • Mechanics
  • Targeters
    • Filters
  • Triggers
  • Conditions
    • In-line conditions
  • Metaskills
  • Placeholders
  • Variables
Items
  • Options
  • Attributes
  • Enchantments
  • Potions
  • Banner Layers
  • Firework
Drops & DropTables
  • Drops
  • DropTables
  • FancyDrops
Spawning
  • Spawners
  • Random Spawns

Stats
  • Custom Stat Options
  • Modifiers
  • Built in Stats
Other
  • Particles Types
  • Audience
  • Equipment Slots
  • Pins
Technical
  • Math
  • Operations
    • Attribute Operations
    • Stats Modifiers
  • SkillTree
  • Advanced User Guides and Techniques