R0J0hound's Forum Posts

  • I can’t open the capx right now, but Here’s another idea. I looked a your first capx briefly when I was at my computer.

    Give the grid sprite a number instance variable and call it n. You’ll also want the origin of the sprite to be centered.

    Also create another sprite and call it detector. Make it’s origin to the left and make it’s size 32,4. I’m assuming the grids are 32,32.

    Global n=1
    
    On click
    —set n to 0
    —set grid.n to 0
    —if mouse is over grid
    ——add 1 to n
    ——set grid.n to n
    
    On click
    Repeat 50 times
    —If grid.n=loopindex+1
    ——set grid.opacity to 50
    ——set detector position to grid
    —Repeat 4 times
    ——Set detector.angle to 90*loopindex
    ——if detector not overlapping wall
    ——if grid overlapping detector
    ——if grid.n=0
    ———add 1 to n
    ———set grid.n to n[/code:3d5uzgqz]
    
    Change the repeat to the number of grids to highlight. Also I used opacity to do the highlighting but you can use anything.
  • Since they did it with the next penalope they have the base of making a C2 game run on the switch. You could always try to see if you could hire them to get your game on switch too. No idea what the cost would be.

  • The limit was added as a spam fighting measure. There are still spam accounts that get through registration and blocking the links is the best way to stop them until a mod can recognize it as spam.

    Anyways, that doesn’t preclude new users from posting links. You can put the link inside code tags or add spaces in a few spots in the link. Or as a different user you can see the blocked link by just looking at the page source if you feel so inclined.

    At any rate, a new user will get enough rep in a short time anyway.

  • one possible solution is by using qarp() to do the curve.

    Objects:

    A, B, dot

    Every tick

    —- destroy dot

    Repeat 10 times

    —- create dot at lerp(A.x, B.x, (loopindex+1)/11), qarp(A.y, (A.y+B.y)/2-abs(A.x-B.x)/4, B.y, (loopindex+1)/11)

    Dot.x > touch.x

    —- destroy dot

  • Changing the playback rate changes the pitch.

  • Isn't there a create by name action?

  • From what I read most browsers already do this internally with JavaScript. Are you having performance issues?

  • If it says the file isn’t compatible then it probably is corrupted unfortunately. If you open the file in a hex editor I’d guess it’s all zeros so there is nothing to recover.

  • You could always just move around the layout a screen at a time, capture a screenshot of each and merge then together.

    https://www.dropbox.com/s/rth2r0p44qex6 ... .capx?dl=1

  • Instead of using "set at (loopindex, 1)", use (array.width-1, 1). The first loop pushes stuff to the end and loopindex ends up being at the end of the array. In the second loop, loopindex is not the end of array. You could also use loopindex+TileFloor.count instead of loopindex in the second loop.

    You can offset the grid using this.

    grid_position = round((x-offset)/gridsize)*gridsize+offset

    For example when the walls are vertical.

    x = round((Mouse.X-24)/48)*48+24

    y = round((Mouse.Y)/48)*48

  • If the object origin is at the center you can do warping with two events:

    sprite: x < -self.width/2

    --- sprite: set x to self.x+640+self.width

    sprite: x > 640+self.width/2

    --- sprite: set x to self.x-640-self.width

  • That dropbox change broke all the links, just TAG the authors in a reply and if they're around they can fix those links.

  • Use this equation for x and y. Solving for scrollx1 and scrolly1 should do it

    (X-scrollx0)/scale0 = (x-scrollx1)/scale1

  • So i had another pass at my event based pathfinding. It works by the user placing node sprites all over the map in whatever configuration, and then modifying the "pick neighbors" function to pick the connected nodes from any given node. So then you call "astar" with the start and end node uids, and the function returns a comma separated string of the node uids that make up the path. I also added some events to then move along that path, but there may be cleaner ways to handle that.

    Anyways here's it with thin walls.

    https://www.dropbox.com/s/jkxxfiguk1jak ... .capx?dl=1

    And you can also do different kinds of pathfinding by changing up the "pick neighbor" function.

    https://www.dropbox.com/s/zgh79wn62x7og ... .capx?dl=1

    https://www.dropbox.com/s/v4axhrz8stist ... .capx?dl=1

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • irina

    There is an image at every 360/sprite.count degrees on rotY. To rotate one at a time you could just change the value over time.

    Here's one way to change a value over one second from one value to another, but there are other ways.

    global number lerping=0

    global number t=0

    global number start=0

    global number end=0

    global number rot=0

    on click

    lerping=0

    --- set start to rot

    --- set end to rot+45

    --- set t to 0

    --- set lerping to 1

    lerping=1

    --- set t to min(0, t+dt)

    --- set rot to lerp(start, end, t)

    --- if t = 1

    ------ set lerping to 0

    Loading images at runtime would require a different plugin that lets a unique image be used per instance.