<npc.name> tag in world script

Mateo_

Member
Feb 11, 2018
6
0
0
Hey guys,
I am trying to make an inventory menu that narrates some stuff after choosing an option.

I've made a format script with <npc.name> tag but it couldn't be filled in that world script (on player clicks TestGUI_menu_yes in TestGUI_menu:).

Is there an option how to determine how the <npc.tag> has to be filled in that world script so that I wouldn't have to write the name manually?

Here is the script for better undestanding:
https://pastebin.com/rDMNxYHH
 

Mateo_

Member
Feb 11, 2018
6
0
0
I came up with this:

https://pastebin.com/DPZYdL8p

Doesn't seem to be very effective... (it works tho)
 

Mateo_

Member
Feb 11, 2018
6
0
0
How exactly? I haven't met with that yet.
I assume I should flag that NPC at the start of the interact script
 

mcmonkey

Administrator
Staff member
Helper
Assign a flag with the value "<npc>" while it's available, however/whenever/wherever needed to track it correctly. Then just use that argument mentioned above on the end of any command that needs it, with npc: and then a tag that will read the flag.
 

Mateo_

Member
Feb 11, 2018
6
0
0
Code:
npc:<server.flag[relevantNPC]>
returns either true or false, so it wouldn't parse that NPCs name, would it?
 

mcmonkey

Administrator
Staff member
Helper
That shouldn't be returning a true/false at all...
It returns whatever value you put in it. In this case you'd be putting an NPC object in it.