Jump to content
Sign in to follow this  
serena

Interior Objects Interaction Script

Recommended Posts

Script allow you to put weapons and ammunition on the interior objects, move these objects and stack them to build a compositions for various tasks. Compact, efficient in terms of performance, single file with about 100 lines.

 

Technically, script does not need to run anything other than the original game. But to take full advantage of its capabilities you need to be able to climb on objects and free your hands from weapons. Any mod or script provides such abilities can be used. I use Enhanced Movement from Bad Benson.

 

Version 2.1

  • New choosing the place algorithm for putting items. It allows to more precisely place objects, even in hard to reach places. The body direction determines items direction, while the camera direction relative to the body determines the location where items will be placed.
  • Added optional marker indicating position and direction at which items will be put. Whiteboard in demo mission has an menu action to control, show marker or not.

 

Version 2.0.Beta:

  • Interaction logic changed to make usability more intuitive and clear. Appearance of command menu option is now guarantee that the corresponding action can be initiated without any additional conventions.
  • Added ability to move simple objects like camping lanterns, whiteboards and different decorative objects.
  • Added continuous control of carry process. Now at any moment player can elevate object by change stance or drop when got damage or ran out of stamina.
  • Weight of held object affects stamina. Lightweight object can be held indefinitely long, while heavy object will exhaust you very quickly.
  • Now player able to move objects with weapon in hands, but it also increases exhaustion speed of stamina.
  • Added function to batch override mass of objects to predefined values.
  • Now it is possible to specify height of the upper surface individually for each object class. This allows to correct positioning of items on a complex shape objects like chairs or benches.
  • Support of multi-surface objects like shelves and racks.

 

Known issues (not caused by script, but influencing it):

  • Some of objects have unrealistic default weight. For example plastic table weighs 99 kg, camp lantern - 10 kg, small plastic ammo crate - 500 kg, and so on. This should be remedied by the mission designer. Fortunately we have the setMass command. Also script contains special function to fix it in batch manner.
  • Sometimes player stuck in weapon holstering animation when puts weapon to the ground from a kneeling position. Take weapon back solves the problem.
  • Sometimes, due to properties of game physics, military crates attached to the player, can throw him up.

 

Script, usage sample and demo mission with detailed tutorial here. Have fun!

 

Collage1024.png

 

Interactives.jpg

 

Marker.png

 

  • Like 5
  • Thanks 1

Share this post


Link to post
Share on other sites

wow! i was just randomly browsing and look what i found.

 

it is such a nice coincident that you mentioned EM as inspiration because initially i was planning to have something like this as a feature in EM to allow exactly the half-life 2 type climbing you have it set up for. but people complained already about the fluid interaction stuff being inthere with the movement stuff. needless to say i'm really happy i found this :xmas:

 

i love the nice presentation mission and the way you are able to pick things up higher just using you stance. i love organic intuitive implementations like that. first i was confused by the "Put Items" options but what an awesome feature that is. this will allow some nice immersive interaction with other players without having to learn a whole new UI.

 

keep it up! this is awesome.

  • Like 1

Share this post


Link to post
Share on other sites

Are there any videos of this script working? I want to see what it really does

Share this post


Link to post
Share on other sites

i didn't have time to take a look at the code yet so i'm curious why there needs to be an extra action to put items onto tables etc. since it seems to open the default inventory. i'd be interested, if this is a limitation or a decision to avoid some kind of conflict and if there's maybe the possibility to have this functionality in the inventory by default.

Share this post


Link to post
Share on other sites

diesel tech jcfoxhound, thank you!

 

kerozen, sorry, I'm not a guru in the movie making. Perhaps sometime later... : )

 

bad benson, wow! Thank you for your kind words and interest in the topic, and sorry for the delayed response.

 

Weapon holders do not give us ability to control position and direction of each contained item. To get realistic layout we need to have individual holder for each gun we place. Also, we need to give player choice - open existing weapon holder or create new, with corresponding position between object and player. Simple binding action to object does not work, because, when we have number of holders, they overlapping and screening each other and even underlying object. In this case player can't get access to object to activate actions, and can't control which of weapon holders be accessed by inventory command. Such initial conditions are left not too rich variety of ways to implement the interaction logic.

 

Little announce: version 2.0 is coming... From delicious:
Simplified, more intuitive and clear interaction logic. Ability to move simple objects like camping lanterns. Improved elevation mechanic. Stamina consumption, based on object weight, weapon in hands, etc. Correct positioning of items on a complex shape objects like chairs or benches. Aaaand... Full support of multi-surface objects like shelves and racks! That's all : )

  • Like 2

Share this post


Link to post
Share on other sites

Interior Objects Interaction Script 2.0.Beta

  • Interaction logic changed to make usability more intuitive and clear. Appearance of command menu option is now guarantee that the corresponding action can be initiated without any additional conventions.
  • Added ability to move simple objects like camping lanterns, whiteboards and different decorative objects.
  • Added continuous control of carry process. Now at any moment player can elevate object by change stance or drop when got damage or ran out of stamina.
  • Weight of held object affects stamina. Lightweight object can be held indefinitely long, while heavy object will exhaust you very quickly.
  • Now player able to move objects with weapon in hands, but it also increases exhaustion speed of stamina.
  • Added function to batch override mass of objects to predefined values.
  • Now it is possible to specify height of the upper surface individually for each object class. This allows to correct positioning of items on a complex shape objects like chairs or benches.
  • Support of multi-surface objects like shelves and racks.

 

 

Known issues (not caused by script, but influencing it):

  • Some of objects have unrealistic default weight. For example gardening plastic table weighs 99 kg, camp lantern - 10 kg, small plastic ammo crate - 500 kg, and so on. This should be remedied by the mission designer. Fortunately we have the setMass command. Also script contains special function to fix it in batch manner.
  • Sometimes player stuck in weapon holstering animation when puts weapon to the ground from a kneeling position. Take weapon back solves the problem.
  • Sometimes, due to properties of game physics, military crates attached to the player, can throw him up.

Script, usage sample and demo mission download link.

 

Interactives.jpg

  • Like 3

Share this post


Link to post
Share on other sites

Version 2.1

  • New choosing the place algorithm for putting items. It allows to more precisely place objects, even in hard to reach places. The body direction determines items direction, while the camera direction relative to the body determines the location where items will be placed.
  • Added optional marker indicating position and direction at which items will be put. Whiteboard in demo mission has an menu action to control, show a marker or not.

Marker.png

  • Like 2

Share this post


Link to post
Share on other sites

This is excellent, thank you. In some scenarios immersion is poor due to the utter lack of objects one would normally expect to see in an interior.

 

BTW, have you seen that the latest version of TPW mods has a script for furnishing interiors?

 

Cheers

 

Orc

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×