diff --git a/src/game.cpp b/src/game.cpp index 0beae4b..237f9c8 100644 --- a/src/game.cpp +++ b/src/game.cpp @@ -1826,6 +1826,33 @@ void the_game( client.playSound(sound,0); } client.setFormState(true); + }else{ + MapNode nn = client.getNode(nodepos); + v3s16 aa = content_features(nn).onact_also_affects; + if (aa != v3s16(0,0,0)) { + v3s16 npos = nodepos+nn.getEffectedRotation(); + NodeMetadata *ameta = client.getNodeMetadata(npos); + if (ameta && ameta->getDrawSpecString(client.getLocalPlayer()) != "") { + infostream<<"Launching custom inventory view"<setFormSpec(ameta->getDrawSpecString(client.getLocalPlayer()), inventoryloc); + menu->setFormIO(new NodeMetadataFormIO(npos, &client)); + menu->drop(); + { + std::string sound = content_features(nn.getContent()).sound_access; + if (sound == "") + sound = "open-menu"; + client.playSound(sound,0); + } + client.setFormState(true); + } + } } } if (input->getRightClicked()) {