Tags
Creators
Details
6.1.0-26.1.1
Compatibility
Changes
-
New: A mob can search a path before it walks it:
MobEntity:findPath,MobPathandMobEntity:startPathAlongmob:findPath(target, options)searches the pathstartPathTowould start on and returns it as aMobPath, without moving the mob. It returnsnilif there is no path at all.- A
MobPathhas the read-only fieldslength,nodes,reachableandtarget. So a spell can compare the ways to two targets, or see where a way leads, before the mob takes a step. - Given a list of positions,
findPathsearches a path that comes by each of them in order: a patrol, or a way around a place the mob should avoid. mob:startPathAlong(path, options)starts a task that moves the mob along that path and no other. It doesn't search again: if the mob is held up, the task fails with"unreachable". It doesn't start if the mob isn't on the path ("off_path").local a, b = villager:findPath(well), villager:findPath(farm) local path = a if not (a and a.reachable) or (b and b.reachable and b.length < a.length) then path = b end if path and path.reachable then villager:startPathAlong(path) villager:awaitTask() end
-
New: Hide aspects of a living entity from the players:
LivingEntity:setHiddenandisHiddenentity:setHidden(aspect, hidden)hides one aspect, or a list of them, andentity:isHidden(aspect)tells whether one is hidden.- The aspects are
"equipment"(what the entity holds and wears),"arrows"(the arrows and bee stingers that stick in it),"effectParticles","stepParticles"(the dust of sprinting and landing) and"stepSounds". - Together with
invisible, which hides the body only, nothing gives an entity away any more. - The entity itself is not changed: it keeps its items and its effects. The settings are not saved. A player keeps them through death and respawn, and loses them at logout.
local player = spell.owner player.invisible = true player:setHidden({ "equipment", "arrows", "effectParticles", "stepParticles", "stepSounds" }, true)
-
New: A player can wear another player's skin:
Player:setSkinandPlayer.skinplayer:setSkin(name, timeout)puts on the skin of the player account with that name, also in the middle of a game. The player keeps their own name and UUID. All players see the new skin at once.- The skin is looked up at Mojang, which needs internet access. The function waits for it, usually less than a second, and returns
true, orfalseand the reason:"not_found","unavailable","offline","replaced"or"timeout". player:setSkin(nil)gives the player their own skin back. The read-onlyplayer.skinis the name of the player whose skin they wear.- The skin stays on through death and respawn, and is gone when the player logs out.
local ok, reason = spell.owner:setSkin("jeb_") if not ok then print("No skin: " .. reason) end
-
New:
Player.online- The read-only
player.onlinetells whether the player is still on the server. It isfalseonce the player has left or was kicked; a dead player is still online.
- The read-only
-
Change: A reference to a player follows the player through respawn
- A variable that holds a player, and
spell.owner, now refer to the respawned player after a death. Before, they kept referring to the dead one, whose position and health no longer changed. - In an
AfterPlayerRespawnEvent,spell.ownertherefore equalsevent.newPlayer, no longerevent.oldPlayer. - A reference doesn't follow a player through logout: a player who logs in again is a new player, and an old reference stays offline, as
player.onlinetells.
- A variable that holds a player, and
-
Change:
MobEntity:startPathToreaches targets beyond its search range- A path search looks
searchRangeblocks ahead, so a path to a distant target, or along a long, winding way, may end short of it. The mob now searches again from where such a path ends, as long as that gets it nearer the target. Before, the mob went no further than the end of that first path. task.reachableisfalsewhile the current path stops short of the target; the mob may still get there.
- A path search looks
Supplementary resources
| File | Type | Size | |
|---|---|---|---|
| wizards-of-lua-6.1.0-26.1.1-sources.jar | Sources jar | 410.82 KiB |
Projects on Modrinth are automatically available through a Maven repository for use with JVM build tools such as Gradle. To learn more about the Modrinth Maven API, click here.
Note: When available, you should use the creator's maven repo instead as it will have transitive dependency information that the Modrinth Maven API does not. You may also end up with duplicate dependencies if you use a mix of Modrinth and non-Modrinth Maven repositories for your dependencies, because the group identifier will be different when served through the Modrinth Maven API.
Maven coordinates:
Version ID:
build.gradle:
repositories {
exclusiveContent {
forRepository {
maven {
name = "Modrinth"
url = "https://api.modrinth.com/maven"
}
}
// forRepositories(fg.repository) // Uncomment when using ForgeGradle
filter {
includeGroup "maven.modrinth"
}
}
}
// Standard Gradle dependency
dependencies {
implementation "maven.modrinth:HW3198Ve:FMMd7PSJ"
}
// Legacy Loom dependency
dependencies {
modImplementation "maven.modrinth:HW3198Ve:FMMd7PSJ"
}

