Git Product home page Git Product logo

Comments (6)

lunafromthemoon avatar lunafromthemoon commented on June 18, 2024 1

So, since the looks and portraits are different, I think there would be a better way to do this. We already have support for changing expressions during dialog, like:

   - deuzi says happy: Asdf qwer

What this currently does is simply show the character with the new look. Now, what I'm thinking is using this same syntax for the portraits (and trying to keep the original behaviour too, since it's still quite useful):
Now you can define a list of looks for a character, that's just a list with look key and the path to the file. We can do something similar to define portraits, so, like this:

characters:
  deuzi:
    displayName: Deuzilene
    looks:
      normal: assets/characters/Char3NormalSchool.png
      happy: assets/characters/Char3HappySchool.png
      angry: assets/characters/Char3AngrySchool.png
    portraits:
      normal: assets/characters/DeuziPortrait.png
      happy: etc

So now when we do a 'say' action with a named look, if the character has portraits defined, then it will show them as portraits. And if you want to show the characters as usual, you can use the show action.
To give a bit more flexibility, we could have a property in character that will define if you want to use the portraits or not. Let's imagine you want to use portraits only for the "protagonist" and want to change protagonist during game, and also encounter them as normal. You'd have to setup both looks and portraits for all characters and then go around changing this property to set who you want to use portraits and who you don't want to. (probably with a plugin)

Finally, to setup where the portrait is going to be shown, and since this is related very closely with the message box, I guess the best would be to define a portrait position directly in the message box, in the GUI file. Since you can now have different message boxes, you'll be able to set where the portrait is in each one.

What do you think about this way of handling the portraits?

from renjs-v2.

lunafromthemoon avatar lunafromthemoon commented on June 18, 2024

I think this is more or less the same as this feature (#11) that I've been meaning to implement. The more I think about this feature the more complex and convoluted it gets:

My main questions now are:

  • Are these portaits/side images associated to the message box and they show and disappear along with it?
  • What syntax can be used to show this side images without contaminating to much the say action
  • Are the side images something different from a look? Let's say, can a character appear on screen and on side image as well?

from renjs-v2.

JohanForngren avatar JohanForngren commented on June 18, 2024

I think this is more or less the same as this feature (#11) that I've been meaning to implement. The more I think about this feature the more complex and convoluted it gets:

Yes, you can probably merge theese 2 issues.

My main questions now are:

* Are these portaits/side images associated to the message box and they show and disappear along with it?

Yes,, I think so.

* What syntax can be used to show this side images without contaminating to much the say action

It's not pretty, but one way without refactoring to much of the code be something like this:

- portrait deuzi: frowning # from this point deuzi's portrait is frowning
- deuzi says: I'm very mad at you!
- portrait RESET: # resets all portraits for all character to the default one
* Are the side images something different from a look? Let's say, can a character appear on screen and on side image as well?

Yes.

from renjs-v2.

JohanForngren avatar JohanForngren commented on June 18, 2024

Sounds really good!

So now when we do a 'say' action with a named look, if the character has portraits defined, then it will show them as portraits. And if you want to show the characters as usual, you can use the show action.

What should we do with - deuzi says angry: if the angry portrait does not exist? I think we should show normal.

To give a bit more flexibility, we could have a property in character that will define if you want to use the portraits or not. Let's imagine you want to use portraits only for the "protagonist" and want to change protagonist during game, and also encounter them as normal. You'd have to setup both looks and portraits for all characters and then go around changing this property to set who you want to use portraits and who you don't want to. (probably with a plugin)

We could also do this by only showing portraits for characters that has a portraits: property. That would also make it completely no breaking for old stories.

Finally, to setup where the portrait is going to be shown, and since this is related very closely with the message box, I guess the best would be to define a portrait position directly in the message box, in the GUI file.

I think it would be better if we just did like ctc:

     portrait:
        x: 2800
        y: 118
        asset: asset14 # optional background that is showing behind the portrait when it's visible

Since you can now have different message boxes, you'll be able to set where the portrait is in each one.

Nice, didn't know that. I really need to learn the new UI.

from renjs-v2.

lunafromthemoon avatar lunafromthemoon commented on June 18, 2024

Hey, just to let you know this feature is pretty much implemented already (I need to test a few things but it works like a charm) and will be probably included in the next version (that will come out soon, maybe next week)

from renjs-v2.

lunafromthemoon avatar lunafromthemoon commented on June 18, 2024

The features is now implemented and release as of version 2.3.0!

from renjs-v2.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.