Forum rules - please read before posting.

Arranging Puzzle slots set as an "initial slot" will prevent pieces being placed there

I've noticed that if any piece lists a certain slot as its "initial slot", no pieces (including this one) will be allowed to snap to that slot anymore. Is this how it is intended to work?

I would like to have my antlers start snapped to a slot and be moved between slots freely. I can take the antler's "initial slot" field away and just place the piece there pre-puzzle, but then it does not snap to the slot, it just sits on it un-snapped, and a player must pick it up and put it back down again to snap it to the slot.

https://imgur.com/a/u9JNf1v
AC version 1.81.3

Comments

  • Shouldn't be the case. I'll take a look, thanks.

  • I'm not able to recreate this with the package's example game.

    If you assign the Example managers and open the Example scene, one of the balls at the top should have an initial slot - is the behaviour the same for you here? If it works here, what if you then run the Example scene with your own game's Settings Manager?

  • I'm not really sure how, but I managed to replicate it in the example scene with the example settings. I think it happened when I was swapping back and forth between the two settings, but I am having trouble recreating this consistently.

    https://imgur.com/a/GuFHEnf

    I've noticed that this behavior is not consistent. In my own scene (with my own settings), the first time I play the puzzle it works correctly, and the second time it does not.

    https://imgur.com/a/a9GGryq

    When I interact with the hotspot to look at the puzzle, all it is running the following and then a camera change:

    public void MouseOver()
    {
    KickStarter.settingsManager.hotspotDetection = HotspotDetection.MouseOver;
    KickStarter.settingsManager.defaultMouseClicks = true;
    KickStarter.stateHandler.SetMovementSystem(false);
    }

    Letting me go from moving with WASD to point and click for puzzles.

    When I click that arrow to exit, it is just doing the opposite, moving the camera back and running:

    public void PlayerVicinity()
    {
    KickStarter.settingsManager.hotspotDetection = HotspotDetection.PlayerVicinity;
    KickStarter.settingsManager.defaultMouseClicks = false; // don't allow mouse clicks to progress dialogue or activate hotspots (happened while navigating menus)
    KickStarter.stateHandler.SetMovementSystem(true);
    }

    Not sure if this is relevant, but that's all that's happening between it working properly and not. In both the imgur links above, a change in the settings (during play, without pause) happened between it working and not working, either by swapping the managers during active play or those lines of code during active play.

  • Hold off with any custom code for the moment - we need to rule out it being a factor in this.

    I'm not really sure how, but I managed to replicate it in the example scene with the example settings. I think it happened when I was swapping back and forth between the two settings, but I am having trouble recreating this consistently.

    By default, the Green ball starts in the Blue slot - not Red. What are the full changes you made to the scene that caused the issue to begin occuring?

  • I didn't make any changes to the scene, it looks to start on red there because I was playing with it and then realized I had recreated it with the balls, and started recording. Ball just happened to be on red at the time.

  • I can't recreate the behaviour, but it looks like the blue slot (not the ball) has its Hotspot turned off.

    A slot Hotspot should turn off automatically once a piece is assigned to it (i.e. a ball is placed over it), and turn on again once the piece is taken from it. Can you check if this is the case? A box will appear at the top of the Hotspot component if it is currently turned off.

  • Yes, it looks like that is the issue. The hotspot is turned off while the piece is on it. Then I remove the piece and the hotspot stays "off". For whatever reason, swapping the hotspot detection method during game makes it so that whatever hotspots slots are set to OFF can no longer turn back on.

    I cannot recreate it this way using the demo scene only consistently in my scene, but for my scene if while I'm playing the puzzle I go into the AC Game Editor and toggle the hotspots>Hotspot detection method from mouse over to direct and back, then go back to playing the puzzle, whatever hotspots had a piece in them will now be stuck as OFF. This recreates the issue without my code snippets running since I am not going in and out of the puzzle anymore, just changing the value in the editor.

  • Once you use Player Vicinity detection, Hotspots are no longer interactive if they're not within the Player's Hotspot Detector.

    Make sure that Place distant Hotspots on different layer? is unchecked when this mode is active, but you should avoid altering the detection mode mid-puzzle.

  • Looks like Place distant Hotspots on different layer made the difference. Don't know when that pesky box got checked again.

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Welcome to the official forum for Adventure Creator.