tarek2's Forum Posts

  • I tried to add a reverse flipping

    https://cdn.discordapp.com/attachments/225550155531812865/1101091792222429204/PageFlip4.c3p

    Nice addition!

    There is an issue when you flip it, you see a thin and long line appearing at the BBoxRight of the Book.

  • Really Cool dop2000 good job!

    Looks quite realistic, I love it.

    Looks perfect fit for digital school books)

    (Hiearachy & Mesh) are the best additions they added to construct.

  • > Hmm, I think some of the content links are dead... but if you use the left navigation it works, which takes you here: https://www.construct.net/en/construct-2/manuals/construct-2/system-object-reference/system-expressions

    I ask for your patience for a little longer, but I have an awkward question to ask. Have conditions flipped in construct 2?

    I have some code and I can't help but feel its not working right.

    it runs along the lines of:

    If Global Variable "Apple" is NOT equal to "Hold", then start Timer "Fall".

    The Global Variable "Apple" starts off as equal to "Hold". This means, the above code should not work. However, once I change it to say "Snap", the code should then proc.

    The thing is, I don't know if its a bug or what but right now construct 2 is not working that way. Right now, the variable is "Hold" and it procs but when i flip the script, it does not work.

    I'm not a pro, but again, I can't help but feel its not right.

    Here's a picture to better illustrate.

    https://snipboard.io/Jlftxk.jpg

    I think the issue is with your event 4:

    As long as that condition is true it will keep starting the Timers so it will never trigger because you keep resetting both Timers.

    One way to avoid that is to add to that condition a System "Trigger Once" so it only runs once when is true.

    Also, are you sure that you need that timer to run Regularly? As it will never stop, it will keep triggering every "Your Target" second. Though if you need it that way then is all good, but if not then change it to "Type = Once".

  • Are you spawning the target on the same layer as the Player?

    If not then when you scale the layer you will need to translate the coordinates from Layer to layer, otherways they will not match as the coordinates will be different from layer to layer.

    Or an easier solution if you dont want to translate the coordinates you can spawn the target at the same layer as the player.

    If that is not the issue then it will be better to share a minimum example so someone can have a look.

  • > To simplify yourself use "Timers" instead as they use already dt internally.

    >

    >

    >

    > > On Timer "Increase Speed": 
    > ------------ad 1 to "Paddlespeed"
    > ------------Start Timer "Paddlespeed" for 1.5 sec 
    > 

    I've been looking into timers, but I'm not sure it would fix what I'm after. Question, in that code; does it add 1 to "Paddlespeed" every 1.5 secs? Or, would I end up with 1 and a half?

    Sorry, I misspelt that you should start the timer with the same tag "Increase Speed" not the name of the variable.

    On Timer "Increase Speed": 
    ------------ad 1 to "Paddlespeed"
    ------------Start Timer "Increase Speed" for 1.5 sec 
    

    Yes, it will add 1 to "Paddlespeed" every 1.5 second

    The best and quickest way to find out is to test it:

    https://www.dropbox.com/s/afhw6d3smk3xizs/Timers2.capx?dl=0

    Test Both the "Every X Seconds" and the "Timers" and see which one you like more is the same, I prefer the Timer just because has that trigger and its easier to visualize that you running a timer because of the icon, but if you prefer "Every X Seconds" then that is a good option too as its the same, it's all by preference.

  • thank you for your effort!

    I have followed your recommendations step by step. and it already does quite a lot of what i want :)

    I don't understand everything yet, but i'm working on it. I'll try to work on it from there. Maybe I'll get back to you with a question or two. If I may.

    thanks for the help so far, appreciate it!

    Np Glad was helpful

    Here is a quick pic of what I meant just in case:

  • Perfect. It's simple and clear. I can use it. Thank you a lot ^^

    I have a specific need. I want to control the "wait time" of each platform separately. In your example we have a global "wait time".

    Do you know if I can use a variable on the platform object?

    For example, I want to have a variable called "waitTime". And for each platform, I want to configure my wait action using this variable.

    So, if Platform1 "waitTime" is "1", so my wait will be "1" for the Platform1

    Glad it was helpful

    Sure, you can use the instance variable "waitTime"

    Then for the events you will do:

    Instead of "For Each Ordered" use "For Each"

  • Can you make a screenshot of your code so I can try to understand it?

    Visit this link:

    editor.construct.net/r339

    Open the project there and copy the events or just check how is done so you can replicate it in your project.

  • I think to resolve it quicker I make a quick example to see if it helps:

    They start moving with a 1-second delay

    https://www.dropbox.com/s/ry6ueutxvdu7kbo/Move%20Platforms%20Delay.c3p?dl=0

  • Unfortunately it didn't work. :/

    I probably did something wrong. Could you help me, more ?

    Yep that is the same problem I explained in my last comment, is calling every tick the Function, give me a second I need to check properly your events as I think we are talking about two different things, I thought that you just need to start moving the platform but now from your last events it looks like you actually move the platforms with that function so is not gonna work.

  • Thank your tarek2, I will try with the "for each". It seems a good idea. ^^

    Sorry it's in french you're right.

    Yes I know how to do it with sinus, but I wanted to have a fully custom movement with no behavior.

    Np Good luck, if you have any problems just post back.

    Just a quick note:

    To start the platform's movement and use the For each, make sure you call once as for me it looks like it calls the Function every tick when Timer is zero or less. if so you can add a "Trigger Once"

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Thank you.

    But how can I make it for a specific platform.

    If I use wait, it will affect all of them ?

    You need to pick each one independently, not sure how you pick, but by the looks of your events I think you call once the function so if you have more than one platform you will need a:

    System "For Each" Platform -------------------Action: Wait (DelayTime * LoopIndex)

    The first one will move right away:

    The "For Each" needs to be on the Top Event and move all that code inside the function on a subevent of the For each as you have some picking going on there.

    Note:

    You have the Sine Behaviour swell that can move platforms nicely with patterns.

    I dont understand the language but I dont see how you move the Platforms.

  • For delaying the second platform you can use "System Wait" 0.5 or so then move

  • Is not very clear what you trying to do:

    Do you have a problem stopping the objects?

    Or

    Do you have problems with picking which all objects move at the same time?

    Can you explain a bit more?

    Normally to stop the platform you can just use (Enable/Disable)

  • thank you for your reply i think one of the guys seling the games here is trying to make me pay more than his seling price.

    Do you mean the free version? if is that then he is right you need a paid licence to export to the app stores.