pj4ever's Recent Forum Activity

  • Maybe the "several frames" method is the best solution. Thanks for the fast reply!

  • I've stamble upon this issue: i've pinned 2 cannons and an engine to a space ship so i can change the graphics when the ship will be upgrade. No matter what type of controll i use (in this moment i still use the "drag controll" on a touch screen), when i drag the ship to the edge of the layout, these objects go through it. Everything is set with the behaviour "bound to layout by edge" but only the ship stay.

    How can i solve this?

  • Really? I thogth the events works simultaneously. But there is another issues for the enemy ships, the same thing happen. So the problem is that? That's weird. I'm lost now

  • Indeed, when change order of event sheets, only the first two on the top works. An example, when i move the event sheet "enemies_meteor" putting it below the second event sheet added, just don'work, the meteors never get destroyed, don't flash in white and the family variables doesn't change at all. Now i'm tring to create a new project and start again coping all the codes and see what happen.

  • If you move the included event sheets, the three on the bottom doesn't work for me. Before the comments i used groups instead, thinking that was the problem. I'm going crazy...

  • I don't know how to post a capx, but i've uploaded it on drive.

    Link

    drive.google.com/open

  • I spend a lot of time to figure out what was the problem with my code. I have 5 event sheets included in 1 event, it's ok so far, until I discovered that, moving events by changing order, the two peaks at the top work while the other three do not.

    Is that a bug? Is there a limit of many events can be included?

  • Hello again constructers! I made an inventory sistem based on array thanks to your help. Now it's time to display this inventory, and i think that i haven't figured out at all becouse the code i've made is wrong.

    This one.

    However my reasoning don't sound so bad: loop in the array till find the desire value in CurX,Y3 (not 0 base), than use that value to change the animation frame of the image used to reppresent an inventory slot. I'm serching for knowledge. So where is the mistake?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • something like this...

    ArrayInventory2.capx

    You rock! Absolutely! Thank you soo much! Now it's time to do the visual stuff!

  • You can try this

    You a variable to make when it set within the loop so it won't keep setting.

    This is a loop breaker! Thank you for the tip! It's actually working but the "insert", as name suggest, still add more rooms in the array. It's possible to delete the last index but is not was i looking for. I think i gonna keep working on your break loop solution! Thanks!

    > .. the inventory could have any width, e.g.: a bag contain 10 spaces but i wanna make it bigger, than i buy a new one with 20 spaces..

    >

    I think ....you know how to solve this..but just in case...

    ..Add Variable "Bag(max_slots)"=10

    ................and then compare.....if Variable<Array.Width....then.....Push item in the bag

    ..and when you "buy a new bigger bag"...set Variable to 20...

    I'm afraid you're wrong becouse, i don't really know how to solve this. Anyway, thanks for the tip, i'll give a shoot!

  • > .. in your example the intial array width is 0 and you use push back to create a "slot" and the expression"Set value at (ArrayPicked.Width-1, 1) to 1" to put the value, whic is great but, in my case, i already know how many slot i have in my invetory...

    >

    I use " o width" and "push" because I dont know how meny slots you have in inventory... <img src="{SMILIES_PATH}/icon_e_biggrin.gif" alt=":D" title="Very Happy">

    You're right indeed but, the inventory could have any width, e.g.: a bag contain 10 spaces but i wanna make it bigger, than i buy a new one with 20 spaces. Your solution is pretty cool (i will quote you if my game will see the light!).

    Try this:

    http://www.blackhornettechnologies.com/ ... pdate.capx

    I've try this kind of code early but i think that the "stop loop" doesn't do anything, just as [quote:g5qfubfc]PhoenixNightly

    say.

    Thank you guys for the answers. If i discover something, i will share in the tutorial section <img src="{SMILIES_PATH}/icon_cool.gif" alt="8-)" title="Cool">

  • see.... if this helps you

    Example.capx

    Thank you for the example, it's self-explanatory. It's still not helping me becouse, in your example the intial array width is 0 and you use push back to create a "slot" and the expression"Set value at (ArrayPicked.Width-1, 1) to 1" to put the value, whic is great but, in my case, i already know how many slot i have in my invetory. Any way, it's a great idea.

    The for each command is doing that. That is why it is filling it up your commanding it to put it in each slot. You should check for the first empty slot and place it there.

    So 'for each' then to a check for if the current slot is empty if so break out the loop and place it there.

    How can i break the loop?

pj4ever's avatar

pj4ever

Member since 9 Sep, 2015

None one is following pj4ever yet!

Trophy Case

  • 9-Year Club
  • Email Verified

Progress

10/44
How to earn trophies