File tree Expand file tree Collapse file tree 4 files changed +4
-4
lines changed
Common/src/main/java/at/petrak/hexcasting/common/casting/actions/spells/sentinel Expand file tree Collapse file tree 4 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -20,7 +20,7 @@ class OpCreateSentinel(val extendsRange: Boolean) : SpellAction {
2020 args : List <Iota >,
2121 env : CastingEnvironment
2222 ): SpellAction .Result {
23- if (env.castingEntity == null )
23+ if (env.castingEntity !is ServerPlayer )
2424 throw MishapBadCaster ()
2525
2626 val target = args.getVec3(0 , argc)
Original file line number Diff line number Diff line change @@ -17,7 +17,7 @@ object OpDestroySentinel : SpellAction {
1717 args : List <Iota >,
1818 env : CastingEnvironment
1919 ): SpellAction .Result {
20- if (env.castingEntity == null )
20+ if (env.castingEntity !is ServerPlayer )
2121 throw MishapBadCaster ()
2222
2323 val sentinel = IXplatAbstractions .INSTANCE .getSentinel(env.castingEntity as ? ServerPlayer )
Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ object OpGetSentinelPos : ConstMediaAction {
1515 override val argc = 0
1616 override val mediaCost: Long = MediaConstants .DUST_UNIT / 10
1717 override fun execute (args : List <Iota >, env : CastingEnvironment ): List <Iota > {
18- if (env.castingEntity == null )
18+ if (env.castingEntity !is ServerPlayer )
1919 throw MishapBadCaster ()
2020
2121 val sentinel = IXplatAbstractions .INSTANCE .getSentinel(env.castingEntity as ? ServerPlayer ) ? : return listOf (NullIota ())
Original file line number Diff line number Diff line change @@ -18,7 +18,7 @@ object OpGetSentinelWayfind : ConstMediaAction {
1818 override val argc = 1
1919 override val mediaCost: Long = MediaConstants .DUST_UNIT / 10
2020 override fun execute (args : List <Iota >, env : CastingEnvironment ): List <Iota > {
21- if (env.castingEntity == null )
21+ if (env.castingEntity !is ServerPlayer )
2222 throw MishapBadCaster ()
2323
2424 val from = args.getVec3(0 , argc)
You can’t perform that action at this time.
0 commit comments