ExpireNoMore

一款 Minecraft 模组,用于延长 Minecraft 服务器 usercache.json 文件中的用户名过期时间。
更具体地说,该模组会在每次服务器启动或有人加入服务器时更新服务器的 usercache.json 文件,使得任何 expireson(过期日期)距离当前不足 50 年的用户记录,其过期时间都会增加 100 年。
如果你需要让用户名正常过期,请不要使用此模组。
警告:在运行此模组之前,请备份你的 usercache.json 文件
注意:此模组无法恢复已移除/过期的用户缓存数据,它只能保护当前已存在的数据。
制作此模组的原因:
我想查看并比较服务器上玩家的游戏统计数据,并找到了一个非常棒的项目来实现这一功能:
该项目运行良好,除了一个问题:它没有显示所有玩家的统计数据。
经过搜索,我发现这是因为玩家统计数据是以玩家的 UUID 作为文件名存储的。
通常这没有问题,因为如果是在在线模式下,玩家的 UUID 可以很容易地转换回他们的用户名。
然而,我的服务器处于“离线”模式。因此,UUID 无法逆向转换为用户名。
通常情况下,用户名和 UUID 会存储在一个名为 usercache.json 的文件中。但不知何故,该缓存中的每条记录都有一个过期时间。
恰好,一些服务器成员很长时间没有登录,导致他们的用户名没有被缓存在该文件中。因此,统计项目无法显示这些玩家的名称。
为了解决这个问题,我决定制作这个模组。我不确定是否有理由让这些名字在文件中过期。如果你确实需要让名字过期,请勿使用此模组。
关于模组
模组的 1.1.0 版本应适用于大多数 Fabric 版本(从 1.14.4 到 1.21.8),而 1.2.0 版本适用于 1.21.9-1.21.11,且至少需要 Fabric 加载器版本高于 0.15.1。
最低 Java 要求是 Java 8,不过更高版本的 Java 也可以正常工作。
当你首次运行此模组时,每个用户名的过期时间都将增加 100 年(只要其剩余时间不超过 50 年)。
ExpireNoMore

A Minecraft mod that increases the expiration time in a Minecraft server's usercache.json file.
More specifically, this mod makes it so that, every time the server is started or someone joins the server, the usercache.json file of the server is updated, so that whichever user's expireson date is less than 50 years away, will have their value increase by another 100 years.
Don't use the mod if you need the name to expire for whatever reason.
Warning: Make a backup of your usercache.json before running this mod
Note: This mod cannot recover previously removed/expired usercache. It can only save what currently exists.
Reason for this mod:
I wanted to see and compare the player statistics of the players on my server, and found a great project to do just that:
It worked well, except for one part. It didn't show all the players stats.
Searching around, I found that this was because the player statistics are stored with the player's uuid as the filename.
Now, this would usually be fine, as the player's uuid can be easily converted into their username if it were an online server.
However, my server was in "offline" mode. So therefore, the uuid's could not be reversed.
Now usually, the names and uuids are stored in a file called usercache.json. Except, for some reason, every cache has an expiry time on it.
It had so happened that a few server members had not logged in for a long while, so their names weren't cached in that file. So the stats project could not display their names.
So to finally fix that, I decided to make this mod. I don't know if there is any reason for the expiration of names in the file. If you have a need for the expiry, do not use this mod.
About the mod
The 1.1.0 version of the mod should work on most fabric version(from 1.14.4 to the 1.21.8), and the 1.2.0 version working for 1.21.9-1.21.11, with atleast the fabric loader version being above 0.15.1
The minimum java requirement is java 8, although any higher version will work.
When you run the mod the first time, every username's expire time will increase by 100 years (as long as its not already more than 50 years away).
评论 0
登录后参与评分
还没有评论,来抢沙发吧