HeewetSheldon Posted April 18, 2022 Share Posted April 18, 2022 Hello everyone. I am trying a script to display in a box some data of an actor. But I can't find a way to display the name. I tried: playerREF.GetBaseObject().GetName() playerREF.GetLeveledActorBase().GetName() playerREF.GetActorBase().GetName() Papyrus compiler response: GetName is not a function or does not exist I don't know if this is the right place for the question I want to ask. If not, I'll delete the post. With the same format I got GetSex; GetClass and GetRace... Could someone guide me? My script is missing something for GetName to be interpreted... Link to comment Share on other sites More sharing options...
ocloki Posted April 18, 2022 Share Posted April 18, 2022 GetIsID and reference the Actor name I believe is what you need to use. Actually after double checking. GetName is valid. Try something like this. ; Obtain Bob's name and show a message using it. String BobName = Bob.GetBaseObject().GetName() Debug.MessageBox("My name's " + BobName + "!") ; My name's Bob! Link to comment Share on other sites More sharing options...
HeewetSheldon Posted April 18, 2022 Author Share Posted April 18, 2022 (edited) Muy contento de que me hayas respondido. Dudas:"bob" es una variable de qué tipo? Tengo esa misma línea de comando definida con una variable Actor y otra ObjectReference (también probé una variable de tipo ActorBase).Vi ese ejemplo en el Kit de creación Wiki, lo implementé con el mismo resultado: "GetName no es una función..." Mi código: [code]Scriptname LAU_HospedadosScript extends Quest ¿Este extends es correcto? ¿Faltará una entrada? Función Listar(ObjectReference Ref) ;prueba con variable de tipo Actor, ObjectReference, ActorBase Actor myActor = ref como Actor ActorBase myActorBase = myActor.GetBaseObject() as ActorBase ; String theName = myActor.GetBaseObject().GetName() ;GetName no es una función... ; String theName = Ref.GetBaseObject().GetName() ;GetName no es una función... String theName = myActor.GetActorBase().GetName() ;GetName no es una función... String Sex = myActor.GetActorBase().GetSex() ;¡¡Esta bien!!! EndFunction [/code] Edited April 18, 2022 by marcfer3 Link to comment Share on other sites More sharing options...
IsharaMeradin Posted April 18, 2022 Share Posted April 18, 2022 GetName is an SKSE provided function. You will need to ensure that the SKSE source scripts are available to the compiler in order to compile any script utilizing SKSE provided functions or events. Link to comment Share on other sites More sharing options...
HeewetSheldon Posted April 18, 2022 Author Share Posted April 18, 2022 GetName is an SKSE provided function. You will need to ensure that the SKSE source scripts are available to the compiler in order to compile any script utilizing SKSE provided functions or events.Hello!!!!I don't know if the tags are correctly placed. It's my first time adding code.I imagined it! I have SKSE installed and in my game the programs that use it work correctly, is there something I didn't do? Link to comment Share on other sites More sharing options...
IsharaMeradin Posted April 19, 2022 Share Posted April 19, 2022 SKSE places their source files in a directory different than the SSE default for source files. You may need to locate where the SKSE PSC files are and move them to the correct directory. Or use a third party utility (See External Editors section on the right hand side: https://www.creationkit.com/index.php?title=Category:Papyrus) and configure it to read from multiple source folder directories when compiling. SSE defaults:PEX files - Data > ScriptsPSC files - Data > Source > Scripts SKSE defaults:PEX files - Data > ScriptsPSC files - Data > Scripts > Source Link to comment Share on other sites More sharing options...
Recommended Posts