mongoose665's Recent Forum Activity

  • You could use the "On animation ended" condition for that.

    Thank you, I ended up going with a Timer. On this specific example, animation ended would have worked too, but I thought there may be a more generalized way to loop things that I could learn for good practice. For example, creating a moving platform so that it moves left for 1 second, then moves right for 1 second, then repeats. Would a timer be best there?

  • Hi guys, really dumb question. I'm trying to loop a series of events over and over, so that when it gets to the end, it just goes again.

    https://imgur.com/WwGgVzt

    Pretty much just trying to loop something like this over and over in a simple way.

    Thanks guys and girls!

  • Hi everyone, not sure how active this forum is but thought I'd give it a shot.

    I'm the solo dev of Steam game Archimedes, looking to make my next game. Unfortunately, I'm awful at Construct 2, and I'm trying to create a super simple and non-messy dialogue system. I've checked out a few examples sent to me, but they're so complicated I can't get my head around them.

    I'd need something that when made, can have all the complicated coding pushed to the side and manipulated through some super simple commands, as well as obviously someone who can talk me through it and answer any questions I might have, even for a few days after, while I get used to it.

    I understand that there are a load of dialogue systems out there, so I'm sure you can adapt one of those, meaning it could be done very quickly. You'd just have to make one that's very easy for me to use, fits into my pre-existing construct 2 document, replacing my old one, and has the features I want e.g. has multiple choices, can activate events easily, include variables in the text etc.

    Probably something most of you could do without much thought, but I'm an idiot

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • You didn't mention anything about setting a position, you said you had an issue where set scale wasnt working. You can have an event on family created > set scale to x. For the position, you could use a function and pass a parameter through it for location. For your game it sounds like you need to use a container though, where you create an object made up of smaller objects that is premade.

    You know, I've just done a different method, where upon Creating an object, it creates another object. But, again, that secondary object's animation cannot be changed unless there's a wait before! I have no idea why this is happening on such a large scale on my project now, I literally have no idea what to do because if I create anything it needs a Wait before anything is repositioned, changed size, changed animation etc...

  • [quote:eygdpm07]There must be some easy way to change a family's properties after creation without some kind of break for the code to register it?

    It's on family created. What do you mean by 'every scenario'? This one event covers every creation scenario.

    So if I use On Family Created> set position to X, then every time I create the family, it will be at that position. But I want to be able to change the position, it won't always be X, it will vary every time I create the family, I want that control. I'm finding it very hard to explain.

    Let me put it another way, I've got a set of sprites that are all individual parts, but are parts of the same object, how would you go about spawning that object, along with all the parts in the right positions, and then scaling and positioning that object in its entirety once it's created? As you can see on that image, I made a function that creates all the individual parts and scales them. But if I call that function and then try and re-position it without a Wait in between the calling and re-positioning, it just stays in the original position.

    So if I did On Family Created > set at this position, every time I create it it's going to be there, when in reality I want to be able to change the position afterwards to whatever I want, not just the same one every time it's created. Hopefully this somewhat makes sense.

  • Why do you need a pause? Why isn't the scale working? Try on family created > set scale.

    I'm not sure, it won't let me reposition the family or rescale it unless I leave a gap of some kind, it just defaults to the normal one. And I want to be able to change the scale on the fly in the same event sheet, so making a "on family created" for every scenario would be hell.

    There must be some easy way to change a family's properties after creation without some kind of break for the code to register it?

  • Hi everybody, my problem lies in the fact that I've made a Family, which is basically making a sprite visible, but if I create the family and then set the family scale to say 2, the scaling doesn't work, the only way I can get it to work is to make a wait time of 0.001 seconds between creating the family and scaling the family for the scaling to take effect. Unfortunately this leaves a single frame where the family is scaled wrong and it's glaringly obvious.

    https://imgur.com/PX1LbVY

    Any workaround to this? I've tried putting the scale family as a sub-event to make a break without using the Wait, but it doesn't work, I can only get the scaling to work when I use a Wait event in between.

  • There are lots of ways to optimize your code.

    You can add TextChoice1 and TextChoice2 to a family and bam - you already can combine those 2 conditions into one.

    > Mouse On clicked on TextChoicesFamily
    Rubix is visible
    Text is not visible
    TextChoicesFamily is clickable
       TextChoicesFamily text is "Sure..."
       or 
       TextChoicesFamily text is "Uhm..."
    [/code:2ho3ykzk]
    
    I'm sure you it's possible to compress all this even further with functions, but I need more examples of your code.
    Could you share the capx?
    
    Also, you might want to check the FAQ on this forum - there are a few good examples of how to build a dialogue system in games.
    

    Hi there, thanks for responding. My problem is basically I don't want to be making hundreds of families for each dialogue branch. And I have actually looked at (and bought a plugin) for dialogue choices but, my coding knowledge is super limited, and this works best for me right now unfortunately Can't seem to find any simple enough for me.

  • Hi everyone, so basically I'm trying to find an easier way to do this than just making a unique function to call every single time.

    I basically have 2 groups of conditions I want to do the same set of actions, so as an example: (click object 1 + sprite visible) and (click object 2 + sprite visible) both lead to (object 3 visible). The only way I can think is to make it so when Function "X" is called, object 3 becomes visible, and then put call Function X as the only action for both sets of conditions. But I am doing this on a huge scale, so as opposed to making an entirely new function every time, is there an easier way to do this?

    I mean, right now, I'm just copying and pasting the same thing twice for both, because it feels less messy than having a thousand functions, somehow:

    https://imgur.com/9wwpEOM

    Many thanks in return!

    Josh

  • mongoose665

    Function can return a value:

    Thank you! I'll look into implementing this. Appreciate it.

  • The conditions will go inside the function. If you share a capx or tell me exactly what you need to be done, I can help you better.

    https://drive.google.com/open?id=0Bxak1NjIAUQEVjRyRFVEcHh3RE0

    Okay so here's an example I made, I want to basically amalgamate the conditions "Sprite 2 is visible" AND "Sprite 3 is visible" into one function, so I wouldn't have to copy and paste both of those, just one thing, into every event I wanted doing the same thing,

  • Yes. Just add the Function object to your capx file. You do that the same way you add a Sprite or any other object, just go and select the Function one...

    I understand how to use a Function to call event actions, but not conditions. I can do call function > make sprite visible. But I have no idea how to make a function that says "Is sprite visible", like a condition, not an action.

mongoose665's avatar

mongoose665

Member since 12 Jun, 2015

None one is following mongoose665 yet!

Trophy Case

  • 9-Year Club
  • Email Verified

Progress

10/44
How to earn trophies