dop2000's Forum Posts

  • Global variables are not reset when you change layouts. They can be reset either with "Reset global variables" or "Load" action, or maybe another value gets assigned to this variable somewhere in your code when the game exits from the cutscene.

  • No.. You can use "begin_function" attribute in the XML file to change avatar animation. Simply create a function that changes animation.

    Or a better solution would be adding another attribute: "animation_name". Make a sprite with different animations for everyone, who has dialogue lines in your game, and when each line of dialogue starts set animation to "animation_name".

    So your xml can look like this:

    <TextLine id="1" id_next="2" animation_name="guard">Stop right there!</TextLine>
    <TextLine id="2" id_next="3" animation_name="character">What happened here?</TextLine>
    ...
    [/code:2vcgh4gz]
  • Have you seen this dialogue system?

    I imagine you can easily add an avatar or "mugshot" of a person speaking to it.

  • Any program can glitch and corrupt your file if you save it to one location and don't make backup copies. You have nobody to blame in this situation but yourself.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Probably some issues with your browser then. Have you tried clearing cache?

  • It's hard to understand what's going on in your screenshots.

    I made a little demo:

    https://www.dropbox.com/s/7wb796s7gbco9 ... .capx?dl=0

  • The easiest way is to define 5 imagepoints on the table sprite. And then simply place cards on these imagepoints.

    Card #1 goes to "CardPoint1", card #2 goes to "CardPoint2" and so on.

    Card set position to (Table.ImagePointX("CardPoint" & cardNumber) , Table.ImagePointY("CardPoint" & cardNumber))

  • Your code is too complex..

    If you have the same emotions in the same frames in Faces and EmotionWords sprites, you can do something like this:

    variable clickedFace=-1
    variable clickedWord=-1
    
    On clicked Faces        -> Set clickedFace=Faces.animationFrame
                           -> Call Function "SeeIfCorrect"
    
    On clicked emotionWords -> Set clickedWord=emotionWords.animationFrame
                            -> Call Function "SeeIfCorrect"
    
    On Function "SeeIfCorrect"
       clickedFace not equal -1
       clickedWord not equal -1
    
            clickedFace=clickedWord  -> Set text to "Correct"
            
            Else                     -> Set clickedFace =-1
                                     -> Set clickedWord =-1
                                     -> Set text to "Incorrect"
    [/code:hc0lxzcr]
  • This is quite a big and complex task.

    Check the FAQ and Tutorials, there are a few examples of inventory.

  • Ajbael

    You found a very old post. There are a few addons your can use, I recommend LiteTween:

  • Have you tried Browser -> On Resumed?

  • Which part of the video are you referring to?

    Also, what do you mean by "when you play a card" - is this when you remove a card from your hand and place in onto the table?

    Or is this when you receive a card from the deck and it's added to your hand?

    I'm struggling to understand how is this question different from your previous post?

  • Pinning the weapon is one way to do this.

    But probably a better solution would be to define an image point on the tip of the weapon (say, sword) and check if this point is overlapping an enemy:

    System-> Pick Enemy overlapping point (character.imagePointX("weapon"), character.imagePointY("weapon"))

  • Thanks, OddConfection , kriand

    Sine looks nice, but the movement is predictable. Turned out that Sine random settings (magnitude, period, offset) are not randomized after each cycle. If I change them with events, it's better, but still the sprite moves in elliptical trajectory most of the time.

    The example with Custom Movement looks more chaotic and natural, I'll probably use it.

    Thanks again!

  • OddConfection

    Thanks! I think I tried Sine, but it looked kind of repetitive.. Do you change random values after every cycle?