celstrider's Forum Posts

  • "So if i understand it correctly i need to use the animation of a single sprite and add frames for each sprite i want to spawn dynamically? So if i want to create i.e. sprite having ID 5 i need to spawn that generic sprite and switch to frame 5? So that could be a solution but would also prevent that those sprites can be animated, right? And also maintaining those sprites would get really nasty. Imagine hundreds of sprites and now you need to add, remove or update some of them."

    yes, that's correct and it can get messy for larger programs. (be sure to set animation speed to 0)

    yes, you can have different animation in a single sprite. if you double click on the sprite to open the sprite editor you will see an animation named default right click to add more animations. you can also use different sprites but if it isn't necessary then extra sprites just clutter things up.

    the 2nd method is just a way to make it work without using arrays.

    As for the 3rd example I'm just saying you can stick the animation's name into your array and then call it with the .at() method. The count value wouldn't affect the sprite in any way. in plain speak im saying to the pc, "switch the sprite's animation to the value at this spot in the array."

    maybe array.at(itemType's x value, itemType's y value + 2) makes more sense?

    the 3rd method is probably the best way to set up larger games.

  • add a new condition

    if you right click on the events you will see an "invert" option.

    on object 1 tapped

    is not overlaping object 2 >>>> action

    else >>>>> action

    on object 2 tapped

    is not overlaping object 1 >>>> action

  • Prep: make sprite fill with frames where index corresponds to type-id

    sprite set frame to itemType

    or

    Prep: add list populate where animation names match list items, and list index corresponds to type-id

    list set selection itemType

    sprite set animation list.selectedText

    or

    "itemType": 1

    "count": 5

    "animationName": "bananas"

    sprite set animation/frame to array.at(x,y) (will be a bit different than this depend how you choose to set up your array)

    you're question is kind broad there are probably dozens of ways to manipulating sprites like this.

  • magnitude negative value

  • You can adapt the code in this tutorial for your cursor.

    https://www.scirra.com/tutorials/9455/h ... rmer-games

  • I'm in the same boat, you just gotta play to your strengths. Make games that don't need as much artwork. top down games are often lighter on the art than side view. puzzle type games are nice because you're just making simple shapes.

    if you want to learn how to make you own assets, I would recommend starting with a vector program like inkscape rather than a raster program like gimp/krita because you can make decent assets without much practice.

    a few other options:

    1. buy or look around for open source assets.

    2. pair up with somebody that can make animations. either pay them or rev share are good options. though some beginners may work for free.

    3. if you're in college make friends with an art student and see if they want to do some game animations. remember aspiring designers are looking to build up a portfolio to show future employers.

    fiverr upwork and the job request forums are all resources that are made for you to use.

    as for the making code at a random rate, just use placeholders then hire an artist when the project coding is done.

  • something like this should work:

    for each troop

    troop is overlapping enemy

    add subevent > enemy > pick nearest/furthest >

    x: troop.x

    y: troop.y

  • add the image you want the background to change to in the files folder, then use the "load image from url" action to switch to it.

  • I'm on mobile so I can't really play around with it atm, but it you would have to make a loop that iterates through the array with a nested loop in a subevent so it will run each time through the main loop. You may need a second array to store the new values

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • The min function returns the smallest value

    Min(7, 4, 3) = 3

  • so you would make your array like this:

  • click action, select array, click 'set at xy', fill out the form.

    the tricky part is figuring out where to put the action, which will just depend on your specific game.

  • maybe I'm backwards, but isn't it more like.

    (7,5) = (x,y) = 58 = (Array.curX, Array.curY)

    so the x value of 58 is 7

  • set the 'default controls' to no

    https://www.scirra.com/manual/100/platform

    check your sprite's origin point(in each frame) it's probably off center.

    https://www.scirra.com/manual/63/image-points

  • not sure if this will work but it's worth a try:

    give the text object an instance variable = "drawbridge"

    make a sub sub event under all that stuff in the picture

    text instance variable = "drawbridge" --> set visible, wait 2 sec, set invisible

    if that doesn't work try using the system pick by comparison