Author Topic: Talking to placeables from medium distance and different height  (Read 470 times)

Legacy_CaveGnome

  • Sr. Member
  • ****
  • Posts: 432
  • Karma: +0/-0
Talking to placeables from medium distance and different height
« on: October 03, 2014, 05:08:06 am »


               

Hello,


 


I need to improve the range (angle, height, distance) at witch a placeable can be talked and activated.


 


As everyone probably knows, you need to be on the good side of the placeable (transparent arrow), at more or less the same height, and near touch, to have a successfull talk and not the "busy / fail" icon. Is there a way (editing 2das or the placeable model or...) to mimic creature activating / talking behaviour ?


 


You can speak to a creature in a far higher or lower location than what's possible with placeables, and creatures can be talked to, clicking them from any orientation.


 


I would like to access placeables in the same way, without having to pinpoint height to match the PC or touch the object. Yes, i am trying to use placeables from above and at a distance.


 


Thanks


 


 


CG



               
               

               
            

Legacy_Proleric

  • Hero Member
  • *****
  • Posts: 1750
  • Karma: +0/-0
Talking to placeables from medium distance and different height
« Reply #1 on: October 03, 2014, 07:04:43 am »


               

In the OnClick event, you could create an invisible object at the location of the PC, with the same portrait as the placeable, and start a conversation with it.


 


This also works for NPCs.


 


I use this trick all the time to manage conversations where one or more of the speakers might be out of range.


 


For good housekeeping, delete the invisible object shortly after the conversation ends.



               
               

               
            

Legacy_Zwerkules

  • Hero Member
  • *****
  • Posts: 1997
  • Karma: +0/-0
Talking to placeables from medium distance and different height
« Reply #2 on: October 03, 2014, 10:42:41 am »


               


Hello,


 


I need to improve the range (angle, height, distance) at witch a placeable can be talked and activated.


 


As everyone probably knows, you need to be on the good side of the placeable (transparent arrow), at more or less the same height, and near touch, to have a successfull talk and not the "busy / fail" icon. Is there a way (editing 2das or the placeable model or...) to mimic creature activating / talking behaviour ?


 


You can speak to a creature in a far higher or lower location than what's possible with placeables, and creatures can be talked to, clicking them from any orientation.


 


I would like to access placeables in the same way, without having to pinpoint height to match the PC or touch the object. Yes, i am trying to use placeables from above and at a distance.


 


Thanks


 


 


CG




If you talk to a creature it turns around to face you. It would look quite silly if a table with a drawer would turn around if you tried opening the drawer from the opposite side of the table. Placeables have use nodes which tell the engine where the PC/NPC needs to be to 'operate' the placeable. It makes sense that you can only open a wardrobe standing in front of it and not behind it.


You could move the use nodes of the placeables to a greater distance, but that would also mean that if you opened a container with a use node that is farther away from it, the PC would move away from the container when it is opened. If you lowered the use node of a placeable below ground level (usually z=0) the placeable will probably not work any more.


So while it is possible to adjust the use nodes of a placeable it is not advisable and Proleric's method will work better.


 


As a side note, there is a bug in NWmax that moves some use nodes to 0,0,0 when a placeable is imported, but it is hard to say why this is happening. It only happens if there is more than one use node, but you can have more than one use node and the placeable might still be imported correctly. It seems a bit random, which of course can't be. There has to be a pattern that I haven't found yet.


               
               

               
            

Legacy_MerricksDad

  • Hero Member
  • *****
  • Posts: 2105
  • Karma: +0/-0
Talking to placeables from medium distance and different height
« Reply #3 on: October 03, 2014, 12:21:54 pm »


               

Or you could use creature-placeables, as I did with the gem containers I submitted for the CCC a few months ago. They don't turn to face you when you talk to them, and because they are creatures, you can adjust the point your character looks at (to the exact cm) when interacting with the target. Scripting, and simple ones at that, will allow you to mimic containers, or even apply effects to the object. It can also benefit from the fact it can hold items, or equip gear specifically designed for it. By changing its bounding sizes (appearance 2da), you can specify how far away the player has to be before it can interact with the object. In conjunction with an invisible placeable with a pwk source, you can also determine the exact size and shape of the bounding region, as if it were the placeable, or you can simply use the spherical bounding region created by the creature's personal space markup.



               
               

               
            

Legacy_Frith5

  • Hero Member
  • *****
  • Posts: 595
  • Karma: +0/-0
Talking to placeables from medium distance and different height
« Reply #4 on: October 03, 2014, 02:45:17 pm »


               

My method has always been to use a placed invisible object, named appropriately. Thus, you can have a useable tree object, but the actual tree model often occludes vision and causes click problems. So, a smaller invisible object named "a smooth beech" is useable instead, and placed at the base of the trunk. This way you can also more precisely target parts of an existing model or terrain feature. You can even script these to spawn at appropriate times, so after clicking on a desk, the PC might then see "a loose knob" appear on the knob of one of the drawers, and they can click that for more interaction (and the chance to pull the knob off and find something hidden inside it). Etc. 


 


Good luck!


 


JFK



               
               

               
            

Legacy_henesua

  • Hero Member
  • *****
  • Posts: 6519
  • Karma: +0/-0
Talking to placeables from medium distance and different height
« Reply #5 on: October 03, 2014, 11:48:31 pm »


               

I also use Frith's method when I am doing this, and extend it by hooking up access to them via chat events using my modification of Layonara's Ambiguous Interactive Dungeons.


 


I could dig up this code for you if you want it. My code is nothing special though. Its the idea thats cool.


 


Example: say you have a river running across an area. Typically its just a non-interactive feature of the tileset. But if you lay invsible placeables called "River" along its banks you could code them to respond to *swim across the river*. So when the PC chats something like *swim river* the PC moves to the nearest river placeable and attempts a swim check to get across the river. This can be expanded to all kinds of things.



               
               

               
            

Legacy_Tarot Redhand

  • Hero Member
  • *****
  • Posts: 4165
  • Karma: +0/-0
Talking to placeables from medium distance and different height
« Reply #6 on: October 04, 2014, 01:26:23 am »


               

@ henesua did you ever get around to posting the work you did on that to the new vault? I only ask because the link at the top of that thread is for the old vault only and there are no other links on either page of that thread.


 


TR



               
               

               
            

Legacy_henesua

  • Hero Member
  • *****
  • Posts: 6519
  • Karma: +0/-0
Talking to placeables from medium distance and different height
« Reply #7 on: October 04, 2014, 02:36:27 am »


               

I can post it. Like most of my stuff I don't think its of all that much interest so I don't bother. But I'll post it.


 


edit---


Ambiguous Interactive Dungeons v3 now on the real vault



               
               

               
            

Legacy_CaveGnome

  • Sr. Member
  • ****
  • Posts: 432
  • Karma: +0/-0
Talking to placeables from medium distance and different height
« Reply #8 on: October 04, 2014, 03:26:37 pm »


               

Thanks for your very interesting inputs, Gentlemans...


 


Sorry, if i can't elaborate much for now, but what i search is really an improved (PC -> Placeable) talking interaction with textual menu appearing. The standard PC->Placeable com is'nt enough. I have already tried various systems using invisible creatures disguised as things but they have their own limitations. Crucial points needed here are:


 


- extended height contact range between PC and placeable (at least 4.0 meters height difference)


- talking menu distance action (medium distance, 5.0 or 6.0 meters distance minimum)


- static behaviour (no ship/creature moving away on his own or auto-turning to greet you)


- no need to be in front to interact (side independent)


 


Henesua proposition seems interesting! Will give it a go.


 


 


What i intend to make is a system to dock / undock a ship on water, land and air:


 


Polymorphing to a ship creature form when interacting from high pier to sea surface, talking to a ship placeable.


And returning to human form when interacting from ship creature to pier pole placeable (i am trying to improve the Arcane Space scripts).


 


I need to be able to do similar things when the Spelljammer vessel is floating in air above the PC, when in fact the placeable vessel is positionned on an invisible placeable block.


 


I had faint hopes of setting distance and height detection parameters modifying 2das or models, but perhaps i am wrong and these are hard-wired in the game engine.


 


CG



               
               

               
            

Legacy_Tarot Redhand

  • Hero Member
  • *****
  • Posts: 4165
  • Karma: +0/-0
Talking to placeables from medium distance and different height
« Reply #9 on: October 04, 2014, 03:45:36 pm »


               

@ henesua Thank you posting that. I have snagged it and will take a look when I get a chance (currently banging head on some scripts I'm working on).


 


TR