Reference actor by id?
-
- Posts: 7
- Joined: Wed Nov 22, 2017 9:01 am
Reference actor by id?
How can I get the actors name in a dialog by using the actors ID? Right now I am referencing a name like this [lua(Actor["Jimmy"].Name)], which doesn't make sense since I can just write Jimmy inside the text. If I change the name in the database everything would break.
Re: Reference actor by id?
In the Dialogue Editor, you can tick Use Display Name. This will add a Display Name field to the actor, which you can set to something different such as "Big Jimmy the Snake" and even change at runtime. Then you can do this:
- Dialogue Text: "I heard from [lua(Actor["Jimmy"].Display_Name)] that you offed the Capelli gang."
-
- Posts: 7
- Joined: Wed Nov 22, 2017 9:01 am
Re: Reference actor by id?
Thanks! I knew about display names but somehow haven't thought of this.