我非常喜欢 CartJump 这个插件,本想对其进行一些修改和改进,但作者并未开源。因此我重新实现了其基本功能,并进行了现代化改造与优化,同时一并实现了配套模组 CartArmor 的功能。
链接
功能特性
- 使用较新的 config.yml 进行配置
- 可选:在矿车中时防止摔落伤害
- 经过高度性能调优(飞行时无额外 CPU 占用)
- 无需重启服务器,可通过游戏内 /flyingtub 命令直接更改重力参数
工作原理
当矿车沿轨道行驶至边缘(同一高度没有实体方块支撑)时,它将开始自由落体。在默认的 Minecraft 服务器中,矿车会迅速下落且速度急剧下降。本插件允许你调整速度衰减率和下落速率,这样你就可以让矿车在飞行过程中保持全速前进,并以更慢的速度下落,从而实现发射器、过山车,甚至跨越海洋的长途旅行。
配置说明
首次运行服务器以生成 config.yml 文件。
速度调制通过水平和垂直参数进行配置,它们分别控制减速率和下落率。
水平方向 (Horizontal):
- 将水平值设置为 1 将使你在飞行过程中的速度大致保持在发射时的状态。
- 将水平值设置为 1.1(或更高)会使矿车持续加速(每个 tick 乘以 1.1),直到达到 8m/s 的速度上限。
- 将水平值设置为 0.999999(或更低)会使矿车逐渐减速。
垂直方向 (Vertical):
- 将垂直值设置为 0.95 可保持与默认 Minecraft 大致相同的下落速率(需进一步测试验证)
- 垂直值 大于 0.95 会导致极快的下落速率。我不知道你为什么想要这样,除非你是个受虐狂。
- 垂直值 在 0.4 到 0.95 之间 是建造过山车的理想设置,矿车下落幅度较小,但不会显得过于荒谬。
- 垂直值 在 0 到 0.4 之间 非常适合长途旅行和低重力世界。
- 垂直值 -1 到 0 是一种超低重力设置,但不如其他值经过充分测试。
- 使用 小于 -1 的值会导致矿车剧烈振荡并行为异常,不推荐这样做。
具体示例
- horizontal: 0.95, vertical: 0.95 模拟了 Minecraft 的默认行为。矿车会迅速减速并快速下落。在 4 个方块的落差中,矿车大约向前移动 2.4 个方块;由于矿车减速较快,在更长的落差中也不会前进太多。
- horizontal: 1.1, vertical: 0.8 让你比默认 Minecraft 飞得更远一些。在 4 个方块的落差中,矿车将向前移动 7 个方块,并保持相同的速度继续前进。
- horzontal: 1.1, vertical: 0.5 是一个不错的发射器设置。矿车将保持全速前进,每 4 个方块的落差可向前移动 20 个方块。
- horizontal: 1.1, vertical: 0 是一种非常低的重力设置。矿车将保持全速前进,每 4 个方块的落差可向前移动 40 个方块。
- horizontal: 1.1, vertical: -1 是极低重力设置,主要用于娱乐。不,矿车不会向上飞行,但它会以非常非常慢的速度下落,预计会出现大量失控的矿车。不过,如果你从塔上发射,这是快速探索数千个方块的好方法。矿车每 4 个方块的落差可移动 80 个方块。
示例图片:
I really love the CartJump plugin, and wanted to make some changes/improvements, but the author has not open-sourced it. So I re-implemented the basic features, but with some modernization and improvements, also implementing the functionality of the companion mod CartArmor at the same time.
Links
Features
- Configurable using newer config.yml setup
- Has optional fall damage prevention while in a minecart
- Highly performance tuned (uses no additional CPU while flying)
- Change gravity values without a reload using ingame /flyingtub command
How it Works
When a cart rides down a track and off an edge (there's no solid blocks at the same height) it will begin free-fall. In the default Minecraft server, the cart falls very quickly and loses speed very quickly. What this plugin does is let you change how quickly you lose speed and the fall rate, so you can have a cart continue along at full speed if you want, and fall much slower, to implement launchers, rollercoasters, or even long-distance travel over oceans
Configuration
Run the server once to let config.yml be generated.
The velocity mod is configured via the horizontal and vertical parameters, these control the rate of slowdown and the rate of fall.
Horizontal:
- Setting the horizontal to 1 will keep the velocity roughly the same as when you launched during your flight.
- Setting the horizontal to 1.1 (or higher) will keep speeding up the cart (multiplying it by 1.1 every tick) until it reaches the 8m/s limit.
- Setting the horizontal to 0.999999 (or lower) will gradually slow down the cart.
Vertical:
- Setting the vertical to 0.95 maintains roughly the same fall rate as default minecraft (needs testing)
- A vertical of greater than 0.95 allows for very fast fall rate. I don't know why you'd want this, unless you're a masochist.
- A vertical of between 0.4 and 0.95 is a nice setup for rollercoasters, the cart will fall less, but not so much as to seem ridiculous.
- A vertical of 0 to 0.4 is great for long-distance travel and low gravity worlds
- A vertical of -1 to 0 is a super-low gravity setup, but not as well tested as the other values.
- Using less than -1 will cause the cart to oscillate violently and behave erratically, not recommended.
Some concrete examples
- horizontal: 0.95, vertical: 0.95 emulates the default behavior of minecraft. Carts will slow down very quickly and go down quickly as well. In 4 blocks of fall, goes forward 2.4 blocks or so, and won't go much further over a longer fall because the cart slows down.
- horizontal: 1.1, vertical: 0.8 Lets you go slightly farther then the default minecraft. Will go forward 7 blocks in 4 blocks of fall, and keep going at the same rate.
- horzontal: 1.1, vertical: 0.5 is a decent launcher setup. The cart will keep going at full speed, and will go forward 20 blocks for every 4 blocks of fall.
- horizontal: 1.1, vertical: 0 is a very low-gravity setup. The cart will keep going at full speed, and will go forward 40 blocks for every 4 blocks of fall.
- horizontal: 1.1, vertical: -1 Is an EXTREMELY low gravity setup, mostly for giggles. No, the cart will not go upwards, but it will fall very very slowly, expect runaway carts galore. This is a great way if launched from a tower to quickly explore thousands of blocks though. Cart will travel 80 blocks for every 4 blocks of fall.
Example images:
评论 0
登录后参与评分
还没有评论,来抢沙发吧