Closed Alex88WH closed 6 years ago
@Alex88WH Wow that looks really cool! π I think a plugin like that could be of great value to the community since creating these kinds of dialogs is very common in many different kinds of games.
For multiline, the good news is that it's quite easy to add support for it. CATextLayer
(which Label
uses for rendering) has a isWrapped
property that if set to true auto-wraps the text within the layer's bounds. So all we really need to do is expose that as part of the Label
API and it should just work. Did a quick hack and here's what it looks like with isWrapped = true
:
As for a typing effect, one way to solve that would be to create an Action
that changes the label's text
property by adding one character at a time after a certain interval. That should generate that type of type-writer effect which is normally seen in RPGs etc.
Let me know what you think of the above π Also if @insidegui, @mattiashagstrand or anyone else have any ideas then feel free to pitch in π
That's awesome!! Working here, thanks! π I'll post more progress later on βοΈ (shouldAutoResize as false!)
Awesome! Added issue #142 to add support for line wrapping to Label
π
Very nice!
To allow for even more text effects we could make Label Rotatable
and Scalable
as well.
Shouldn't be to hard or what do you think @JohnSundell?
@mattiashagstrand Sounds like a plan! π
@mattiashagstrand Created issues #152 & #153 for scaling & rotation for labels, think they can be great starter tasks π
@Alex88WH Do you think you need more engine changes to implement your plugin? It looks like you're good to go, right?
Yep! I'm working on it! Gonna close this issue. Thank you all π€© (I'll post updates and the plugin itself when I finish it (or at least make it viable to use))
Hey there! I'm trying to create a plugin that handles dialogues. I could use some help :D The final goal is a plugin that can be added on any kinda games. Something simple like a sign in a village or even a complex dialogue with characters.
Iβve two games (dialogue system or something like that) in mind:
Fire Emblem Heroes
Undertale
I tried to play with those in mind on a Playground. What I got so far:
(Raven of Fire Emblem. Testing)
Next:
This is it! Iβm a beginner and I donβt know if I can create something like that using clean and elegant code or best practices at all (But Iβm learning. Reading Imagine Engine is helping me a lot). I could use some direction or tips. Thanks and sorry for all English mistake :D