ArmonPlan's Forum Posts

  • You do not have permission to view this post

  • > just an idea but maybe on planet creation you could pick all others instances and check if distance is odd or not ?

    >

    > If it's not odd, move the planet 1 pixel away or sthing like this ?

    > this wont be very elegant but maybe could work ?

    >

    > this should avoid the player to be in equal distance from both

    ArmonPlan You still have the possibility of the players position being halfway between because the position is stored as a decimal.

    BaconSwagg If you add a condition like Pick Top or something to force just a single instance of the planet, you won't have 2 planets gravity grab the object. The weird thing happening when the character changes gravity is caused by the residual momentum from the original jump. If you sent the VectorY to 0, it should take care of it. I modified your project: This may give you what you need.

    https://drive.google.com/file/d/1sEG5lyml57XqE-BMxLYOElvJ29L3d_UY/view?usp=sharing

    yeah sorry, i did tried and realized that in the pick nearest action, the distance is not rounded ^^

    by my side, i tried to add a global var to it's project to store the last landed planet and add some filtering when jumping and searching the target with pick nearest x)

    hope it's not too ugly xD

  • sorry i did try and it wasnt a good idea, seems pick nearest is not rounding distances values,

    BUT, i think this should do the job ?

    https://www.dropbox.com/s/jbtmqpnmzux7cou/gravity%20shift%20%28edited%29.c3p?dl=0

    ps: of course you'll need to add some kind of filtering, maybe with "jump is pointing to this planet or not" and distance between player and planet while jumping < limitAttractDistance" or whatever you want :)

  • just an idea but maybe on planet creation you could pick all others instances and check if distance is odd or not ?

    If it's not odd, move the planet 1 pixel away or sthing like this ?

    this wont be very elegant but maybe could work ?

    this should avoid the player to be in equal distance from both

  • hi!

    it's hard to help you in this without the project file i guess :)

  • hi !

    i think you can use this tutorial https://www.construct.net/en/tutorials/multiple-colored-shadow-casting-lights-1107, just use a light sprite with kind of a cone shape and skip the shadows part if you dont need it,

    After that define the light position to the light source position and the angle to mouse.X, mouse.Y position every tick,

    hope it helps :D

  • holy crap that's a great find and a badass gif. :).

    I dont know if it's sarcastic or not xD

    Please find the source url of this GIF in case you had some showing issues

    https://www.construct.net/en/forum/construct-3/general-discussion-7/liquidfun-javascript-lfjs-145950#forumPost983585

    I'm using the plugin now, and seriously it's a really great work :D

    anyway thank you so much for your help on this issue sir !! :D

  • last idea for me ^^

    maybe you could add a black sprite on the moon light layer to "hide" the light when needed ?

    but you'll need a dedicated moon light layer for that i guess, to avoir the hiding of the others lights

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • eventually this plugin may help i guess !

    https://www.construct.net/en/make-games/addons/353/touch-plus

    description: Changes the built-in Touch plugin's behavior adding additional settings: ignore invisible objects, don't click/touch through objects and others

  • Hi,

    I think you should take a look on the construct3 documentation; sounds like the native orbit behaviour is what you're looking for :)

    construct.net/en/make-games/manuals/construct-3/behavior-reference/orbit

  • It is all nice but there is no more light/shadow "thing" I mean light that "light-up" shadows like here:

    I thing there must be that thing with "baking-into layer, set multiply effect" but it seems it is possible to "bake-in" only into 1 layer :( or I do not know

    You only leave there additive blend mode on lights so it glows above all layers under it but no shadow/light effect.

    huuuum yeah i didnt noticed that sorry x)

    i hope someone else can help on this but so far i have no more clues :/ i would try tomorrow with a fresh view on this if nobody else give you a solution :)

  • What u think ? is this what you need ?

    just add a "moon" on the layer 0

    and add light for this moon on layer 50

    and defined layer 0 and 50 with the same paralax values

    Also i deleted a background on "main" layer (defined as transparent) and i removed the multiply effect on some layers

    https://www.dropbox.com/s/1618db2eujmyiaa/testLight.c3p?dl=0

    as you can see if you jump near the "moon", the light of the character is in front of the light of the moon

    also, i've added a "cloud" in layer80 as a proof of concept

    didnt do all of you need but it's a good start to continue like that i guess, no ?

  • Well, i dont know if it's what you want, i'm not even sure to understand your issue xD

    To keep your initial capture from kingdom new lands as an example,

    It's not working if you have this layer order ? (from back to front)

    1/ Moon + stars etc

    2/ moon light

    3/ Clouds

    4/ Rocks

    etc

    my guess is, as long as the moon light layer is not in front of the cloud layer, the moon light should appear like it's far from the clouds isnt it ?

    ps: bcs u're using a beta release of construct i cant open your c3p sorry

    ps2: sorry if it's not relevant, i'm not sure to understand your issue :/

  • Okay well, i think the final solution resides in this plugin:

    https://colludium.itch.io/liquidfun-for-construct-3

    As you can see in this gif example, you can "fix" some objects to behave like one big physical object

    https://construct-static.com/images/v842/uploads/articleuploadobject/0/images/30700/lfjs02.png

    Thanks to dop2000 for giving me the way x)

    and all others for help :D

  • Hi!

    Maybe you can transform the for each to a for loop (from 0 to object.count-1), and test on a subevent if the index is equal to OBJECT.count -1 ?

    something like that

    Hope it helps !