lionz's Forum Posts

  • Yes you will come across these kind of issues if you choose to make a game that makes use of complex pathfinding. I have a rollercoaster tycoon type game with a ton of data but it's fun to handle. I would be careful of something that appears to be happening in that logic, it looks like the cooldown timer will be 0 when nothing is being built so it looks like the third event is regenerating the obstacle map every tick which is not good, unless you reset it to 3 somewhere. If you set it to 3 only on the start of construction then it seems to be an issue. Another problem I can see is that you don't seem to force the persons to leave, rather you set the building to solid based on the person leaving, so there could be a bug where you are waiting forever for them to leave and the building never becomes an obstacle for other people. Maybe you have an event further down which is if still on construction site then move them which would be useful.

    Edit: Ok I see while I was typing you added a trigger once. Do you have an event that forces the persons to move? At the moment it just checks if they are there.

  • That's correct, it's probably one of two things, you don't have Solids set as obstacles or you haven't regenerated the obstacle path once the buildings were created. If you create any new obstacles during run time the pathfinding objects won't see them unless you regenerate the map.

  • Hiya it's because when you run the function there is no longer a sprite picked, it then applies it to all sprites. You need to pass the picked sprite data through the function as a parameter, you could try something as simple as setting sprite.UID as the parameter in event 44, then in event 39 when you call the function, put in a compare condition if sprite.UID = function.param(0).

  • I've put a fix in where you set a player level based on the colour combinations and an overlap check so that it doesn't keep trying to change the colour while it is overlapping, so you must pull the player away and overlap again.

    https://www.dropbox.com/s/6c4w7k63wxknf ... 2.c3p?dl=0

  • If jump key is down set vector Y to a lower number.

  • Platform behaviour > Set vector Y to a negative value, will produce a kind of sonic the hedgehog spring bounce effect which is probably what you need.

  • You could try something like :

    System compare two values,

    if LayoutName = "Layout 1" > play background music 1

    if LayoutName = "Layout 2" > play background music 2

    etc

  • > The problem or the fix for the problem? Better to take it into a PM with me as this will just spam the thread and I don't know if you are beginner.

    >

    Probably more useful continuing here so other uses can maybe learn from the discussion.

    Your choice, obviously. Just my 2.452144 cents.

    True I can continue it here, I explained the potential fix and will come up with one although i can't always guarantee that my shared files will be around forever.

    > The problem or the fix for the problem? Better to take it into a PM with me as this will just spam the thread and I don't know if you are beginner.

    >

    Unfortunately, I cannot PM you beause of a lack of Rep points. I'm the definition of a beginner; never designed a game before this!

    I understand the problem (I actually figured it out after my last message), but I don't really know how to fix it!

    Have a good day!

    I will look at a fix today for you, I think I know what it will consist of, a variable that decides the tier of colour and only becomes applicable once you stop the overlap.

  • The problem or the fix for the problem? Better to take it into a PM with me as this will just spam the thread and I don't know if you are beginner.

  • Hi no problem I'll try and explain it the best I can. Basically when you are yellow and touch the blue, it changes your colour to green yes, but because you are still overlapping and your colour changed to green it instantly makes true the overlapping blue while green, so changes to b.green. If you disable the events for the tertiary you will see that secondary now works as expected. You will need to add some logic so that it checks one time for the overlap! Or you can do it a number of ways, only change to secondary colour on first overlap, wait for the player to no longer overlap, then change a variable that allows for tertiary combination. If you can't work out something then let me know, I can see what logic could do it if I have the time.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Text box needs to be every tick to update the value of the global variable constantly. On created just shows the global var value at the start of layout when text box is created. The ammo value was always correct though, I checked in debug mode.

    The problem with the guns appears to be that the bullets are firing every tick so fast that when they are fired, ammo is less than 0 in that tick before fixed by event 79, so the ammo=0 (event 80) isn't true at the point the bullet is created. What is happening is that ammo is always less than 0 whenever a bullet is fired on those guns. Change event 80 to less than or equal to 0 and it's fixed.

  • Can't resolve without the capx, or a screenshot of the events could potentially be good enough here, share that and it can be resolved straight away.

  • There's a system condition called 'Pick random instance', you probably want this.

  • Yep that's the idea. The system pick actions are there to pick by certain criteria. The common one is IID because it will be the create order of that object type, of course you are blocked by using the destroy action which starts to change the IID so an instance variable for the object that increments 'on created' will also work as a kind of ID system.

  • I wouldn't keep spamming, it's rare to get a response about app export things. From reviewing the documentation on Game Center it looks like it is probably possible. Show Leaderboard probably shows the default one or one defined by ID. If you've made a set then there will be a way to show the set.