FG Spreadshirt Swag
  1. #1

    User.getCurrentIdentity()

    No matter if I'm logged in as a gm or a client, this funtion returns nil.
    Is it still a valid function, or am I just being a bit dim?

    Cheers, Steve.

  2. #2
    This will only return a value on the client after the player has activated an identity (i.e. PC).

    There are a couple places this is used in the CoreRPG ruleset code.

    Regards,
    JPG

  3. #3
    Thanks MW.
    I must be having a bad night, 'cos even when I log in as a client, select a character, it still seems to return nil.
    Think I'll come back to it tomorrow

    Cheers, Steve

    *edit*
    OK, sorted that one after all. Turns out I was being a bit dim. Thanks for the pointer Moon.
    Last edited by Stv; February 24th, 2020 at 21:32.

  4. #4
    Just looked at the code to make sure.

    If you're calling on GM client, then it requires a parameter with the user name that you are requesting the current identity for. If no parameter is specified, it will return nil. If the user does not have an identity activated, it will return nil.

    If you're calling on the player client, then it returns the active identity (if any PC active), otherwise returns nil (if no PCs activated).

    Regards,
    JPG

  5. #5
    Thanks for taking a deeper look into it

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
5E Product Walkthrough Playlist

Log in

Log in