mirror of
https://gitlab.com/2009scape/2009scape.git
synced 2026-08-27 13:25:20 -06:00
forceWalk "clip" moved away from a deprecated function
This commit is contained in:
parent
86c8216ffa
commit
ee0715a940
1 changed files with 3 additions and 1 deletions
|
|
@ -65,6 +65,7 @@ import core.game.world.map.Direction
|
|||
import core.game.world.map.Location
|
||||
import core.game.world.map.RegionManager
|
||||
import core.game.world.map.RegionManager.getRegionChunk
|
||||
import core.game.world.map.path.ClipMaskSupplier
|
||||
import core.game.world.map.path.Pathfinder
|
||||
import core.game.world.map.zone.MapZone
|
||||
import core.game.world.map.zone.ZoneBorders
|
||||
|
|
@ -1438,7 +1439,8 @@ fun reinitVarps (player: Player) {
|
|||
*/
|
||||
fun forceWalk(entity: Entity, dest: Location, type: String) {
|
||||
if (type == "clip") {
|
||||
ForceMovement(entity, dest, 10, 10).run()
|
||||
val NO_CLIP = ClipMaskSupplier { _, _, _ -> 0 }
|
||||
Pathfinder.find(entity.location,entity.size(),dest,true,Pathfinder.SMART,NO_CLIP ).walk(entity)
|
||||
return
|
||||
}
|
||||
val pathfinder = when (type) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue