the_Shit_hawk's Recent Forum Activity

  • so im making a game, think something along the lines of hungry hungry hippos. you click, object rises up, grabs, etc. i have the whole grab thing down to if clicked spawn grabber, if not clicked destroy, and on created set position to (mouse.x,mouse.y), but it only grabs straight up. when i try to angle it from the bottom center of the screen (i have a box there) it goes all over. ive tried angle(mouse.x,mouse.y,box.x,box.y) , and vice versa, but it seems to give me opposites. if i click on the left it spawns on the right, if i click on the right it spawns on the left, and if i click above, it spawns a flat line in the middle. while it makes for some cool designs, im looking for the object to spawn on the mouse, aimed towards the bottom center of the viewport, so that it always starts at the center, and ends at the mouse cursor. any help or suggestions would be appreciated.

  • Did you perhaps forget to make the moving platforms 'solid' ?

    yeah, it was a speed issue. the platform itself was moving above the sprites image point causing it to fall through while moving. slowing down the platform helped.

  • So I'm getting adventurous, and want to have moving platforms. I've noticed theres more than a few ways to do this, such as using platform behavior to go left/right,until hitting a box which toggles the opposite movement; or the same setup with 8directional ; or even just setting an exact pixel amount. I've decided to use Sine Waves. they're easy to randomize and happen to have a lot of potential. my problem, is that while using platformer behavior, i tend to fall through moving platforms. as theres hundreds of ways to do anything, i figured id see if anyone else had similar issues, and if/how they were able to get around the problem.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • ok so ive just done it and it works. you give your player and your ground instance variables,and then if ground layer = sprite layer enable collisions. if layers dont = disable collisions. do the same for your enemies. if they have projectiles, make sure to set on created to set the layer properly to its sources layer. in 6 events i can toggle layers via number keys, and only land on platforms if that layers active. however, all of the platforms look the same. it would take little graphical work to make them look like theyre on different planes, but its all 2d.

  • so i was gonna try to get specific but as i dont know excactly what youre doing i dont want to confuse you, but consider attempting making global variables and calling them layers,using numbers to specify , and then have something along the lines of if #>highest layer set to 1 and then add 1 to each layer so as each object would have its own number, or certain actions could send different objects to the same 'layer' etc. if its just for functionality, this should work. used in conjunction with the "send to top of z order" command, it shouldnt be too hard to rig something up. although i did do a test with 3 blocks, where if sprite.zindex =0 play sound 1, sprite 2 = 0 play sound 2, etc, (with condition trigger once while true so as to stop infinite loops), and clicking sent them to the top of z order, and same blocks would play different sounds, even though every time i clicked them they would visibly be on top, and sometimes switching between 2 without going to the 3rd would cancel the desired action. so for what its worth, i see what youre going through lol.hopefully the variables as layers option works for you

  • i have an answer for you but i do not have time to type it out atm, however, if youre still on in an hour or so ill answer this

  • the sizing is just for the lane effect. to make it look closer or further away. if you need each sprite to be on a specific layer, try instance variables. maybe something along the lines of , On Collision, If Player Layer is not = to Object Layer, turn collision/solid behavior off. its not a one click fix, but it'll do what you're looking for

  • that would be enemy.x and enemy.Y, where as if on collision and Not pressing a direction would cause player.x player.y to change, effectively bumping the player when rammed. you could also try to add a safeguard or sort of check, where enemy speed is attatched to a variable.boolean variable = attacking, If Attacking = False, set Enemy speed to 0, if attacking = true, set enemy speed to 100, every x seconds, Random(Range), toggle boolean. If Attacking = true, on collision, bounce player, if false, bounce enemy, OR, you could use something like the compare speed option, and on collision if enemy speed = >50 bounce player, else bounce enemy. also make sure your enemies are solid.

  • try playing with the line of sight behavior. that would allow the enemy to locate the player. look into the platformer templates, there should be a bit of code that allows you to jump onto an enemies head, and when you land on their head it bounces you up a little bit and damages the character. you can manipulate that code, to say something along the lines of, IF Player Is On Collison with Enemy, AND Player is moving, (or Key Is Down, so it recognizes you're trying to ram them, unless you have a button for a ram attack, as "is moving" takes momentum into account, and you may never actually be still depending on physics and player setup) , set player position player.x +5 player.y+5, with player.x and player.y being the players current position, and the +5 adding 5 pixels to current location, effectively "bumping" said object. now as i said, look into the platformer template, as im not 100% thats the correct code, but it IS the correct wormhole to go down.

  • also, if you need them to be more than just overlapping but overlapping in aspecific spot, put an invisible box named D etc

  • to make this a little bit simpler, maybe avoid the z order? i generally only use z order to enforce a foreground and background, and to save myself from using a second layout/layer for a main menu screen. however, you can do something along the lines of (add event)"If A is overlapping B" (add condition) "If B is overlapping C" (add action) Go To Layout

  • construct is marketed as an engine to create games, applications, and even websites. However, if you're looking to hit the largest possible audience, you advertise that you can make games because it draws in people who are bored and looking to play around with things. even in the templates it shows you how instead of making games you could make apps like skype or chat rooms or maybe even encrypted email services. and yes, while construct may seem like overkill just to make a website, it sure will look professional. this is why you can put things in your project such as apple or android support, etc. in closing, dont let what somethings marketed as limit you. everything can be used for something other than its original intention, thats how we invent inventions.

the_Shit_hawk's avatar

the_Shit_hawk

Member since 2 May, 2017

None one is following the_Shit_hawk yet!

Trophy Case

  • 7-Year Club
  • Popular Game One of your games has over 1,000 players
  • Email Verified

Progress

9/44
How to earn trophies