AllanR's Recent Forum Activity

  • the best option performance wise might be to pre-blur the image in photoshop, and have the blurred version as a second frame that you can switch between.

  • yeah, the first set of code sets the animation to "Play"

    then the second set of code will also see the tap gesture and now that the animation is "Play" it will set it right back to "Pause" all on the same tick.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • I have been a programmer for over 30 years, and I have used a great number of different programming environments.

    I have never seen a guarantee like that from companies big or small.

    C3 uses a lot of industry standard formats. Unzipping a .C3P file is easy, you can open all the assets with a text editor or any image editor, so there is no problem viewing the code. Exported projects will continue to run as long as you have a compatible operating system to run them on.

  • hard to say without seeing more... could be that when you go back to the main layout you are hitting the bell again and going right back to the bonus level.

  • there are two issues with the file you posted,

    first, event 6 was a compare two values statement, and wont actually pick instances. The code sample in the image you posted above will pick instances and would work - if it weren't for the second issue below.

    second, event 6 is a subevent under the "Start of Layout" event, where you spawn the two cards that get rotated. The last one of those is the only instance picked when it gets to event 6. The Wait 0 allows all the new instances to finish creating, but it doesn't undo the picked selection from the last spawn action. So, you need a system - Pick All Cards before you attempt to pick the ones with an index >= 0.

    the "Pick All" is why the previous code you posted worked, where you looped through all instances.

    here is a sample I did for someone last year, that flips cards, makes sure matches exits, shuffles, allows for different layouts, match 2,3 or 4 cards to remove them...

    https://www.rieperts.com/games/forum/MemoryGame.capx

  • I put the NPCs into a family called NPC, so you just have to check if the player is overlapping an "NPC"

    I gave the NPC family an instance variable to tell what line in the array their conversation is, and an instance variable that tells what position the conversation is at.

    every time you press the space bar it advances the conversation by one step, until the next step is "END".

    when the player is no longer overlapping the NPC, the conversation is hidden, and all positions reset to 0.

    if you want multiple conversations for NPCs, then you would have to add a list of array positions, and a variable to indicate what the next one is.

    if you plan on having a lot of NPCs, and a lot of conversations, this will eventually get hard to manage. There are lots of other ways this can be done...

    https://www.rieperts.com/games/forum/FoodCourtConvo.c3p

  • obviously, within the function you have to check whether some condition is met before you call itself again. When that is met, it will pop back up through however many times it called itself.

    if the function is creating instances of an object, those objects wont finish being created until the next top level event, and they wont be pickable until then. So there are a number of potential ways you can get yourself into trouble.

  • I have used recursive functions before with no problem...

    I just made a new test file, added a function, and it showed up fine for me when I went to add a function call within it.

  • it depends on how those events are structured and what they are doing...

    having thousands of events can work just fine, but you should use the debugger to see how it is running (cpu usage, memory, fps).

    Having that many global variables sounds like it would be very difficult to manage... there are probably much more efficient ways to store the data you need by using instance variables, arrays, and other techniques. If you describe what your goals are, we can make more specific suggestions.

  • yeah, I remember that happening... but I don't remember if we got far enough to do much about it.

  • (loopindex%2=0 ? dir : -dir)*loopindex

    the % means modulo, or the remainder after dividing, so loopindex % 2 will be either 1 (if loopindex is odd) or 0 (if even)

    the rest is an "if then else" statement

    if the statement "loopindex%2=0" is true, then return what is in "dir"

    if it is not true, it will return -dir

    then the result is multiplied by loopindex

    I haven't looked at Dop's sample yet, but was just starting to have fun with yours! :)

  • sounds like you are mixing up the inputs, which I remember was hard to get straight. I have done very little with multiplayer, but was helping my son with a game he wanted to make a couple years ago. We lost the source capx file in a hard drive crash, but you can still run one of the tests here:

    https://www.rieperts.com/games/Ocean9

    You are a fish, and it follows your mouse around the screen. When you click it will eat the little white planktons, which makes you grow. I think the goal was to get bigger than other players and eat them.

    So, this wont help much, but shows that it is possible.

AllanR's avatar

AllanR

Member since 21 Nov, 2013

Twitter
AllanR has 23 followers

Trophy Case

  • 10-Year Club
  • Forum Contributor Made 100 posts in the forums
  • Forum Patron Made 500 posts in the forums
  • Forum Hero Made 1,000 posts in the forums
  • Popular Game One of your games has over 1,000 players
  • x2
    Coach One of your tutorials has over 1,000 readers
  • Regular Visitor Visited Construct.net 7 days in a row
  • Steady Visitor Visited Construct.net 30 days in a row
  • RTFM Read the fabulous manual
  • Email Verified

Progress

19/44
How to earn trophies