How to set custom activation text and tooltip for scene props?

Users who are viewing this thread

media_evil

Recruit
What exactly I want to know: how exactly you add custom description (white) and custom activation (orange) tooltip for scene props (see example).
images


I know that in module_scripts.py there is a use_item script, but it is not apparent to me how if affects either of these strings. I have also seen some familiar strings in module_strings.py, but still it is not apparent from where those strings are referenced. When I add new weapons, there is no need to configure scene props for dropped weapons, so...

I am trying to enhance the deployable pavise thing so that deployed shields have activators and can be collected in a standard way rather than via yet another dedicated key.
 
Last edited:
Brilliant! It worked. If I got it right, the desired string must be stored in reg0, as everything else in game_get_use_string.

Adding the following commands allows to render custom text for my scene object instance:
Python:
(eq, ":scene_prop_id", "spr_deployable_pavise_player"),
(str_store_string, s0, "@Equip"),

The game_get_item_extra_text callback, seems to kick in when player is browsing some food and book items in his inventory. Or am I missing something?
 
Upvote 0
Did I describe the effect of game_get_item_extra_text correctly?
What about doors? Are they scene props? They have similar tooltips to those of agents...

Or are you saying that game_get_use_string is all that we have got for scene props' tooltips?
 
Upvote 0
Items are everything which is defined in module_items.py, scene props everything in module_scene_props.py. game_get_item_extra_text gets called everytime an item description is shown, so inventory, loot menu, merchants, custom presentations, etc.
game_get_use_string is getting called everytime an agent comes close to a scene prop which has the flag spr_use_time(x) at its entry.
 
Upvote 0
If I am right, dialog windows for items and scene props can be changed, as Earendil mentioned. For agents, it may be hardcoded and not subject to modification (to change the only option look into ui.csv in languages/<your language> in your module).
 
Upvote 0
Back
Top Bottom