Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue: Uses a lot of each server tick. #1

Open
wants to merge 8 commits into
base: master
Choose a base branch
from

Conversation

TheMatt2
Copy link

Meanwhile the problem is not severe, by changing how the randomization is handled, this data pack should use even less time each tick.

This replaces the incrementing counters every tick by using daytime. The scoreboard modulo is then used to make the daytime into a number in the range 0 to n-1 where n is the number of possible kick/sleep messages.

TheGreatKetchup added 8 commits July 10, 2019 13:42
Changed the format label from 1 to 4. 
4 Appears to be the number used in Minecraft by default.

However, this does not actually change anything.
Add a little more explanation and fixed a typo.
This uses the new modulo function to remove the need for a counter 
incrementing every tick.

This also removes the need for the #kick_message and #sleep_message 
players, both being replaced by the already existing #query_time.

This also changes how #sleep_messages ops.sleep and #kick_messages 
ops.sleep so that they should be the number of sleep/kick messages, not 
n-1.
Now this is just two players named #messages and #query_time.

Now #sleep_messages ops.sleep is #messages ops.sleep and #kick_messages 
ops.sleep is #messages ops.kick

Also added #messages to the uninstall.mcfunction and added the old fake 
names to the old_version.mcfunction
The messages are no longer (n-1) but just the number of messages. 
Removed comment refering to this older behavior.
Removed trailing whitespace and makes sure each file ends with a 
newline.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant