Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
Tags

The story of my dad

A topic by Eyon created Jul 17, 2020 Views: 397 Replies: 4
Viewing posts 1 to 5

After a mobile game: https://itch.io/t/748830/in-browser-mobile-game-agents-x-monsters

I'm working on a desktop 2D game based on dialogues!


My name is Eyon I'm 29 and I work on games for fun. Until now I only worked on action or strategy games but for this one I want to try  something else.

Challenges:

  •  To make it interesting! I don't know if the dialogues I write are good ^^'
  • I want to work on tiles and lights!

The new setting of the story is a luxurious house. 

All the characters we'll be able to talk to are in this picture.


I'm having a little problem here. I never thought about that because I only worked on side scroller games until now.

How do I do so the camera know when character has to be behind or before objects? I work in unity.

Hop solved! 

There are  2 different sorting layers. One that is behind the PNJ's, and one that is before it. I check the position of the player when I collide with PNJ's. If the player's position in y> to the PNJ's, then the player is behind it. 

It works fine but if 2 PNJ's  are too close to one another it doesn't work fine. So it's not perfect but it 's enough for now.


public SpriteRenderer Ren;
void OnTriggerEnter2D(Collider2D other)
    {
        if (other.CompareTag("PNJ") && other.transform.position.y > transform.position.y)
        {
            Ren.sortingLayerName = "PlayerDevant";
        }
        else
        {
            Ren.sortingLayerName = "PlayerBehind";
        }

I am working  on the dialogue scripts.

Now I can:

- Start a conversation where the player talks first

- Start a conversation where the NPC talks first

And what I want is  to be able to change the sprite of the characters depending on the conversation. For some sentences they should smile, or be upset or be surprised... This one is not easy.