mirror of
https://github.com/GTNewHorizons/ForgeRelocation.git
synced 2026-11-09 15:15:03 +00:00
Compare commits
4
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
0bfcd5cd98 | ||
|
|
7bee6aa9c4 | ||
|
|
21da7aae0e | ||
|
|
eacf6f7dd7 |
No files matched your search
@@ -3,9 +3,9 @@ name: Build and test
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
branches: [ master, main ]
|
||||
branches: [ master, main, release/** ]
|
||||
push:
|
||||
branches: [ master, main ]
|
||||
branches: [ master, main, release/** ]
|
||||
|
||||
jobs:
|
||||
build-and-test:
|
||||
|
||||
+2
-2
@@ -1,4 +1,4 @@
|
||||
dependencies {
|
||||
api('com.github.GTNewHorizons:CodeChickenCore:1.4.3:dev')
|
||||
api 'com.github.GTNewHorizons:MrTJPCore:1.3.6:dev'
|
||||
api('com.github.GTNewHorizons:CodeChickenCore:1.4.17:dev')
|
||||
api 'com.github.GTNewHorizons:MrTJPCore:1.3.7:dev'
|
||||
}
|
||||
@@ -1,12 +1,12 @@
|
||||
#This file is generated by updateDaemonJvm
|
||||
toolchainUrl.FREE_BSD.AARCH64=https\://api.foojay.io/disco/v3.0/ids/1630f7ebef05444cb27a2709ea0249b3/redirect
|
||||
toolchainUrl.FREE_BSD.X86_64=https\://api.foojay.io/disco/v3.0/ids/fa1e318c287360478e3c83a9a3ef1007/redirect
|
||||
toolchainUrl.LINUX.AARCH64=https\://api.foojay.io/disco/v3.0/ids/1630f7ebef05444cb27a2709ea0249b3/redirect
|
||||
toolchainUrl.LINUX.X86_64=https\://api.foojay.io/disco/v3.0/ids/fa1e318c287360478e3c83a9a3ef1007/redirect
|
||||
toolchainUrl.MAC_OS.AARCH64=https\://api.foojay.io/disco/v3.0/ids/c2dd35c9d0aaf0ba6ad0791320f99dfc/redirect
|
||||
toolchainUrl.MAC_OS.X86_64=https\://api.foojay.io/disco/v3.0/ids/e5810bd7fd1f8a586644409d395a7e55/redirect
|
||||
toolchainUrl.UNIX.AARCH64=https\://api.foojay.io/disco/v3.0/ids/1630f7ebef05444cb27a2709ea0249b3/redirect
|
||||
toolchainUrl.UNIX.X86_64=https\://api.foojay.io/disco/v3.0/ids/fa1e318c287360478e3c83a9a3ef1007/redirect
|
||||
toolchainUrl.WINDOWS.AARCH64=https\://api.foojay.io/disco/v3.0/ids/7b3c4877c0749019e6805bb61e421497/redirect
|
||||
toolchainUrl.WINDOWS.X86_64=https\://api.foojay.io/disco/v3.0/ids/8e1d9ee5d0f13e442218f6884a306da1/redirect
|
||||
toolchainUrl.FREE_BSD.AARCH64=https\://api.foojay.io/disco/v3.0/ids/97d46b5ff4df0bf61e95652a190a5567/redirect
|
||||
toolchainUrl.FREE_BSD.X86_64=https\://api.foojay.io/disco/v3.0/ids/9ef54a08e06b0754cee9fc95ed3a3134/redirect
|
||||
toolchainUrl.LINUX.AARCH64=https\://api.foojay.io/disco/v3.0/ids/97d46b5ff4df0bf61e95652a190a5567/redirect
|
||||
toolchainUrl.LINUX.X86_64=https\://api.foojay.io/disco/v3.0/ids/9ef54a08e06b0754cee9fc95ed3a3134/redirect
|
||||
toolchainUrl.MAC_OS.AARCH64=https\://api.foojay.io/disco/v3.0/ids/1df82b76031285ef2e6a4f59ffe9299d/redirect
|
||||
toolchainUrl.MAC_OS.X86_64=https\://api.foojay.io/disco/v3.0/ids/c7d5be6a02945ac2e045048ee54a7d32/redirect
|
||||
toolchainUrl.UNIX.AARCH64=https\://api.foojay.io/disco/v3.0/ids/97d46b5ff4df0bf61e95652a190a5567/redirect
|
||||
toolchainUrl.UNIX.X86_64=https\://api.foojay.io/disco/v3.0/ids/9ef54a08e06b0754cee9fc95ed3a3134/redirect
|
||||
toolchainUrl.WINDOWS.AARCH64=https\://api.foojay.io/disco/v3.0/ids/643f404f769811f5f265fd66f7af5d89/redirect
|
||||
toolchainUrl.WINDOWS.X86_64=https\://api.foojay.io/disco/v3.0/ids/38256085a73e137cb4937ea9c4807fec/redirect
|
||||
toolchainVersion=25
|
||||
+1
-1
@@ -17,7 +17,7 @@ pluginManagement {
|
||||
}
|
||||
|
||||
plugins {
|
||||
id 'com.gtnewhorizons.gtnhsettingsconvention' version '2.0.24'
|
||||
id 'com.gtnewhorizons.gtnhsettingsconvention' version '2.0.27'
|
||||
}
|
||||
|
||||
|
||||
@@ -61,6 +61,13 @@ object StickRegistry {
|
||||
}
|
||||
|
||||
def resolveStick(w: World, pos: BlockCoord, side: Int): Boolean = {
|
||||
val p2 = pos.copy.offset(side)
|
||||
val target = getBlock(w, p2)
|
||||
if (
|
||||
target != null &&
|
||||
target.getBlockHardness(w, p2.x, p2.y, p2.z) < 0
|
||||
) return false
|
||||
|
||||
def getFrame(pos: BlockCoord): IFrame = {
|
||||
val b = getBlock(w, pos)
|
||||
if (b.isInstanceOf[IFrame]) return b.asInstanceOf[IFrame]
|
||||
@@ -68,10 +75,8 @@ object StickRegistry {
|
||||
if (te != null) return te
|
||||
interactionList.find(_.canInteract(w, pos.x, pos.y, pos.z)).orNull
|
||||
}
|
||||
|
||||
val f1 = getFrame(pos)
|
||||
if (f1 != null && f1.stickOut(w, pos.x, pos.y, pos.z, side)) {
|
||||
val p2 = pos.copy.offset(side)
|
||||
val f2 = getFrame(p2)
|
||||
return f2 == null || f2.stickIn(w, p2.x, p2.y, p2.z, side ^ 1)
|
||||
}
|
||||
|
||||
@@ -126,6 +126,12 @@ object MovementManager2 {
|
||||
c: IMovementCallback
|
||||
): Boolean = {
|
||||
if (blocks.size > RelocationConfig.moveLimit) return false
|
||||
if (
|
||||
blocks.exists { b =>
|
||||
val block = w.getBlock(b.x, b.y, b.z)
|
||||
block != null && block.getBlockHardness(w, b.x, b.y, b.z) < 0
|
||||
}
|
||||
) return false
|
||||
|
||||
val map = new MHashMap[(Int, Int), MSet[Int]]
|
||||
with MMultiMap[(Int, Int), Int]
|
||||
@@ -426,10 +432,11 @@ class BlockStruct {
|
||||
|
||||
var progress = 0.0d
|
||||
|
||||
lazy val allBlocks: Set[BlockCoord] = rows.flatMap(_.allBlocks).toSet
|
||||
lazy val preMoveBlocks: Set[BlockCoord] = rows.flatMap(_.preMoveBlocks).toSet
|
||||
lazy val allBlocks: Set[BlockCoord] = rows.iterator.flatMap(_.allBlocks).toSet
|
||||
lazy val preMoveBlocks: Set[BlockCoord] =
|
||||
rows.iterator.flatMap(_.preMoveBlocks).toSet
|
||||
lazy val postMoveBlocks: Set[BlockCoord] =
|
||||
rows.flatMap(_.postMoveBlocks).toSet
|
||||
rows.iterator.flatMap(_.postMoveBlocks).toSet
|
||||
|
||||
def moveDir = rows(0).moveDir
|
||||
|
||||
|
||||
Reference in new issue
Block a user