HomeSpawnPlus

HomeSpawnPlus

342k Downloads

nearestHomeOrSpawn strategy does not work with death event.

Q2Lummox opened this issue ยท 0 comments

commented

First sorry for my english.

I'm just doing the tests with 3 plugins

  • PermissionsEX
  • HomeSpawnPlus 1.7.8 and 2.0 (tried both)
  • Vault

Im use Cauldron 1.7.2-1.1147.04.196 (For the rest I do not have any kind of problem with this plugin or with others.)

I set the events this way:

onHomeCommand:
- nearestHomeOrSpawn

onDeath:
- nearestHomeOrSpawn

I created my home both with a bed, as with command /sethome (I've tried both ways)
I created two spawn points with /setspawn 1 and /setspawn 2 (type graveyard).

If I stand near of the spawn point 2, I run the command /home, I reappear in the spawn point 2 (as it should, all ok).

The debug, says this:

[17:37:04] [Server thread/INFO]: Q2Lummox issued server command: /home
[17:37:04] [Server thread/INFO]: [HomeSpawnPlus] Strategy evaluation started, type=onhomecommand player={BukkitPlayer:Q2Lummox}
[17:37:04] [Server thread/INFO]: [HomeSpawnPlus](strategy nearestHomeOrSpawn) result is [loc={world,-168,64,267}, home=null, spawn={com.andune.minecraft.hsp.entity.SpawnImpl@18acd021}]
[17:37:04] [Server thread/INFO]: [HomeSpawnPlus] Evaluation chain complete, result = [loc={world,-168,64,267}, home=null, spawn={com.andune.minecraft.hsp.entity.SpawnImpl@18acd021}]
[17:37:04] [Server thread/INFO]: [HomeSpawnPlus] result changed to safeLocation, new result = [loc={world,-168,64,267}, home=null, spawn={com.andune.minecraft.hsp.entity.SpawnImpl@18acd021}]
[17:37:04] [Server thread/INFO]: [HomeSpawnPlus] Strategy evaluation started, type=onteleportobserve player={BukkitPlayer:Q2Lummox}

Well, if I'm near my bed and run the command again /home, reappear in my bed (So far so good).
The debug, say this:

[17:49:04] [Server thread/INFO]: [HomeSpawnPlus] Strategy evaluation started, type=onhomecommand player={BukkitPlayer:Q2Lummox}
[17:49:04] [Server thread/INFO]: [HomeSpawnPlus](strategy nearestHomeOrSpawn) result is [loc={world,-143,64,275}, home={id=2,name=null,playerName=Q2Lummox,world=world,x=-142,04,y=64,z=275,34,yaw=-179,85,pitch=3,bedHome=false,defaultHome=true}, spawn={null}]
[17:49:05] [Server thread/INFO]: [HomeSpawnPlus] Evaluation chain complete, result = [loc={world,-143,64,275}, home={id=2,name=null,playerName=Q2Lummox,world=world,x=-142,04,y=64,z=275,34,yaw=-179,85,pitch=3,bedHome=false,defaultHome=true}, spawn={null}]
[17:49:05] [Server thread/INFO]: [HomeSpawnPlus] result changed to safeLocation, new result = [loc={world,-143,64,275}, home={id=2,name=null,playerName=Q2Lummox,world=world,x=-142,04,y=64,z=275,34,yaw=-179,85,pitch=3,bedHome=false,defaultHome=true}, spawn={null}]
[17:49:05] [Server thread/INFO]: [HomeSpawnPlus] Strategy evaluation started, type=onteleportobserve player={BukkitPlayer:Q2Lummox}

So far, so perfect. The home command event, functioning as it should.

The problem is when the event death starts.

If I die near the spawn point 1 or 2, or near my bed, I always reappear in my bed.

When I die near the spawn point 1 to 2, the debug say this:
[17:52:37] [Server thread/INFO]: Q2Lummox died
[17:52:38] [Server thread/INFO]: [HomeSpawnPlus] Strategy evaluation started, type=ondeath player={BukkitPlayer:Q2Lummox}
[17:52:38] [Server thread/INFO]: [HomeSpawnPlus](strategy nearestHomeOrSpawn) result is [loc={world,-143,64,275}, home={id=2,name=null,playerName=Q2Lummox,world=world,x=-142,04,y=64,z=275,34,yaw=-179,85,pitch=3,bedHome=false,defaultHome=true}, spawn={null}]
[17:52:38] [Server thread/INFO]: [HomeSpawnPlus] Evaluation chain complete, result = [loc={world,-143,64,275}, home={id=2,name=null,playerName=Q2Lummox,world=world,x=-142,04,y=64,z=275,34,yaw=-179,85,pitch=3,bedHome=false,defaultHome=true}, spawn={null}]
[17:52:38] [Server thread/INFO]: [HomeSpawnPlus] result changed to safeLocation, new result = [loc={world,-143,64,275}, home={id=2,name=null,playerName=Q2Lummox,world=world,x=-142,04,y=64,z=275,34,yaw=-179,85,pitch=3,bedHome=false,defaultHome=true}, spawn={null}]

If I die near my bed, says the same.

[17:53:39] [Server thread/INFO]: Q2Lummox died
[17:53:41] [Server thread/INFO]: [HomeSpawnPlus] Strategy evaluation started, type=ondeath player={BukkitPlayer:Q2Lummox}
[17:53:41] [Server thread/INFO]: [HomeSpawnPlus](strategy nearestHomeOrSpawn) result is [loc={world,-143,64,275}, home={id=2,name=null,playerName=Q2Lummox,world=world,x=-142,04,y=64,z=275,34,yaw=-179,85,pitch=3,bedHome=false,defaultHome=true}, spawn={null}]
[17:53:41] [Server thread/INFO]: [HomeSpawnPlus] Evaluation chain complete, result = [loc={world,-143,64,275}, home={id=2,name=null,playerName=Q2Lummox,world=world,x=-142,04,y=64,z=275,34,yaw=-179,85,pitch=3,bedHome=false,defaultHome=true}, spawn={null}]
[17:53:41] [Server thread/INFO]: [HomeSpawnPlus] result changed to safeLocation, new result = [loc={world,-143,64,275}, home={id=2,name=null,playerName=Q2Lummox,world=world,x=-142,04,y=64,z=275,34,yaw=-179,85,pitch=3,bedHome=false,defaultHome=true}, spawn={null}]

It may be that is a problem with the "death" event and the "nearestHomeOrSpawn" strategy?