eleanorjmorel's Forum Posts

  • try figuring out where it fails! Debugging skills !! is it moveto? spawn a sprite and set it'S position to the move to target on every tick, see what happens !!!

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • hel yeah i do, which one do you wanna know ?

  • basically if you want the enemy to be 100 units away from the player, u normalize the vector between them, and u will get like, for example, x = 0.7 and y = 0.3

    0.7 + 0.3 = 1

    you want the enemy to be 100 units away

    x = 0.7 x 100

    y = 0.3 x 100

    or something like that and it will move away from u like magic.

    to get X and y you do like (player.x + enemy.y) / distance(thingsgohere) and same for Y and u get ur two x and y to multiply the distance by or whatever

    I think that'S how it works ???? and u get ur target move to location

  • so like when you normalize a vector between two points (player and enemy) you get a value for X and a value for Y and X+Y = 1 dont ask me how or why im a dummy but by using that you can give the character a target move to position relative to away fro mthe player where u multiply the distance of 1 to the distance you want because X and Y = 1 so it will be the correct distance and the correct angle and u can make it walk good so it'S awesome and u get correct X and Y positions to move to

  • normalize the vector from player to enemy

    Hell yeah game development besties

  • just gonna add there a little bit at the end *pushes u and nudges u with shoulder to get in front of the posting stick* anything u spawn like sprites or whatever with behaviors, they will tick every frame and increase CPU usage, but add things like arrays and dictionaries, u can have a million of them and FPS stays at 60, u dont even need to use their function they were made for, u can just give them variables and control them and move them around that way in any way u want like ur the puppetmaster behind the curtain and making the coolest shit ever and then when it "enters the screen" u can spawn a sprite and move it there like u can have so many little guys running around in those like u wouldn'T believe and they're all running around and doing their own thing !!!

    Subscribe to Construct videos now

    the world is ur oyster

    *Dab-instant transmissions in a pop sound away from the posting stick*

  • i do it in strawberrypunch.com and you can do it too by any way you want!!! Build a data structure that holds object position in some kind of grid of a predetermined size and when something moves it can change grids and u keep that updated as the game runs and when something moves to a space that's within render distance u spawn it and when it moves out you despawn it, that way u only need to query your data structure and get the relevent object uids or whatever instead of getting every object on every frame and checking if they,re on screen or not. anothey simpler way would be to check a certain amount of objects every frame but not all of them so every couple second u checked everything, this way isn'T as good as the previous one but it,s far easyer to implement ! godspeed and support queer rights !!!

  • yeah let'S go kikiki u tell em how it is !!!

  • don'T directly move ur objects, move transparent objects that hold ur visible objects instead, that way u evade lots of consistencies with hitboxes and general wonkyness and u get to do the tip above easier because ur not setting the position of the object directly for smoothness ur setting the visible part of it relative to the invisible part holding it

    k thx bye

  • if u want to run ur game on a lower tickrate, u can smooth the movement by interpolating the position between the current tick and the previous tick and make the interpolation position the remaining deltatime left in the accumulator so u get the smoothest of motion and perfect consistency

  • heyooo new devs here's some useful advice, instead of using delta time with your physics, create a fixed tick rate and then make the game "tick" based on deltatime accumulation, then writing your physics becomes much easier and reliable, and people playing with different framerates aren'T going to get different results, because the physics are going to be the same no matter what the framerate is, since it'S fixed, and if you think deltatime fixes this and makes the game run good, ur wrong lmao, deltatime makes physics actually really inconsistent, like if u get a spike and ur framerate dips , for that LONG frame u move a great distance compared to high fps and it just fucks like u might go through walls and stuff and it'S a nightmare, especially for multiplayer. okay thanks bye !!!

  • if you press p then on the next frame the arrows aren't pressed so it will return to idle, those events dont just magically stop working and pressing p don'T lock the animation in any way

  • those are less good than good old math, it'S great enrichment

    with good old math u just write something down and then it just happens automatically it's like magic, u dont need extra events and triggers and any of that stuff

  • You do not have permission to view this post