Login / Registrieren
DE EN FR ES IT CZ
Zurück Nach oben

npc display text

  • #1, by ygmantell 11 years ago Zitieren
    I make an action, where an npc says something via the display text action, and when I run the game, the text appears in the top left corner. How do I make it appear above the NPC?
    Thanks
  • #2, by afrlme 11 years ago Zitieren
    The NPC is a character or a scene object? You are definitely using the display text action part linked to the NPC character? You have defined the correct animation center for each of the NPC characters animations?
  • #3, by ygmantell 11 years ago Zitieren
    The NPC is a character, and I am using the display text action that is linked to the NPC. I also made sure all of the animation centers are correct.
  • #4, by afrlme 11 years ago Zitieren
    The width / height of the character animations aren't too big are they? Are you using a registerHookFunction() to reposition the text?
  • #5, by ygmantell 11 years ago Zitieren
    No, I am using a re-skinned version of the main character. And I am not using any hooks, or scripts.
  • #6, by sebastian 11 years ago Zitieren
    I think Lee means if the size of the sprite is very big in width and height. THe text will be placed above the sprite, so when there is a lot of transparent space between head and the real top of the sprite it could be possible that the text gets pushed to the side.
  • #7, by afrlme 11 years ago Zitieren
    I think Lee means if the size of the sprite is very big in width and height. THe text will be placed above the sprite, so when there is a lot of transparent space between head and the real top of the sprite it could be possible that the text gets pushed to the side.


    Yep, exactly what I meant. wink

    Quick note: image / animation sprite positions are based on the top left pixel of each image / animation frame. Text above characters is placed based on the center position of the animation normally & above the top most pixel of the animation minus the font size (more or less).
  • #8, by ygmantell 11 years ago Zitieren
    I understand, the NPC animations, are the same as the main character animations regarding size. So, i dont think that is the issue.
  • #9, by sebastian 11 years ago Zitieren
    can you post a screenshot which shows what happens and also the name the size of the character sprite and the game resolution?
  • #10, by afrlme 11 years ago Zitieren
    If you don't manage to sort it out in the near future then feel free (if you want) to send me your ved & resources as it would make it much easier for me to pinpoint the issue, whether it's user error or editor related.
  • #11, by ygmantell 11 years ago Zitieren
    The size of the character sprite is 250x250, and the game resolution is 1280x720. There isnt really much to show on a screenshot. The talking animation is playing, while the text appears on the top left corner. Thats it.