lionz's Forum Posts

  • Same time though in terms of your code, the bullets would have to hit within the same tick, that's very close and I'm not sure you can detect bullet A and B as hitting simultaneously unless you add a delay before destroying.

  • I'm still not understanding the concept, how can both bullets hit if the enemy is destroyed on any of the bullets hitting. Also how is the player firing 2 different bullets at once in your game?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • There is a system condition 'trigger once'

  • You limit the number of picked instances with conditions on the left and apply actions to those picked on the right. If you don't pick anything with a condition on the left then it applies the action to all instances. If you used something like on object touched, do an action then it picks the one you touched. If you said where object.var=3, do an action then it does the action to all instances where var=3.

    But that isn't really your issue here, you need to relate A to the B and C that are overlapping and the only way I can think of based on info given is to have instance variable identifier where related A,B and C have the same number and when you pick which B overlaps C, you pick the A which has the same variable number attached.

    If that doesn't help then please share some more information about your game, maybe there is a better way to get the logic you want.

  • Where's the hp check to see if it should be destroyed, it is always after one hit? It might not work if that's the case because you wouldn't hit them with both bullets ever.

  • The last 2 blocks yes but as separate events on their own, not sub events. You wouldn't need on animation hurt finished because as soon as it finishes those other events become true again, probably the idle one if you're not moving.

  • Just an issue with the calculations, I don't really know what's going on there but you can see with test values that medium is never true and if you make it an AND block which it should really be then it's still impossible to get medium because I guess powerlevel/2 is always true and it's either easy or hard. For simplicity you should just use set values enemy power level is between x and y.

  • Remove the every 0.0001 as mentioned. Also a condition on the 'medium' one, player is greater than enemy seems wrong because it overrides all 'easy' so remove that.

  • Is there any way you can remove that plugin CB Hash? I'm using Construct 3.

  • It takes a while to get used to picking instances in Construct. When you say destroy object A, it's not related to the B and C that are overlapping. I can't see the game so I don't know how they should be related but if it's a switch of some kind you can use instance variables on the instances and pick that way to match them.

  • Let's see the new code and tell me the example values you have for player and enemy level.

  • Nice :)

  • Hello, yes if you select the object itself in events there is a condition 'Pick top/bottom' which allows you to pick the one at the very top or bottom of the Z order. Add this to your on touched event to pick the very top one.

  • This event shows the timer starting every tick so it's never going to finish. You just need one timer since the enemies spawn at the same time, so no need to use for each. You should have 'enemyspawner is on screen : start timer (with a trigger once)' but the timer can be on a random object. Then you say 'on timer : for each enemy spawner : spawn enemy'.

  • Yes so run it when the player levels up