Guizmus's Recent Forum Activity

  • Hey,

    Picking the nearest object in the same family can be confusing, as you have sometimes a hard time finding what element you are currently manipulating.

    I did an example : [attachment=0:fadaxu3a][/attachment:fadaxu3a]

    In this example, I find the nearest element in the same family for each element of the family. To illustrate it, I then make each ball move to this nearest ball.

    You can drag an drop balls to test this, and hit the button to trigger the calculation an movement.

    Events are heavily commented for complete explanation on the method.

    I hope this was what you needed

  • Thanks a lot, that is fantastic news for the forums !

  • It's even simpler then. Just add the Radial blur on the layer itself. With a big enough radius, it's quite all right

    Here is your project modified.

    You'll notice I destroyed the "focus" object, because it wasn't needed. I grow your layout a bit too, and added a sprite with 8 direction movements (move it with the arrows) and a ScrollTo behavior. You'll notice the blur moves with the sprite.

    There is a problem if the sprite isn't in the middle of the screen though, but I didn't find a way to solve this, if anyone has an idea.

  • Is this the end of dropbox here ? Thanks a lot Tom for this. Is there a reputation limit ? (I'm thinking of the new users in the How do I ? section)

  • Yep, just saw it in the help needed section. Nice work from Newt

  • This would in fact be great if the current "Fade" behavior worked on the textbox as it does on everything else. I tried to do a simple capx to explain how I would do it, but the most efficient way to do it would be to call custom javascript on the hosting page, that would handle the change in CSS (as I don't see how to pick an object by its DOM ID in C2)

  • It's not that complicated... Did you try it at least ?

    1/ To know the exact format of the dictionary JSON, manually set your keys v ant t to the wanted value with events, then use the "Download" action on the dictionary, that will download on your computer a JSON file, with the format needed.

    Capx showing this step

    JSON data returned :

    {"c2dictionary":true,"data":{"v":100,"t":"lalalala"}}[/code:1hh3fnv1]
    
    2/ Once you have this format, change your script on ajaxGame.php to fit what you need.
    So in fact, just add :
    [code:1hh3fnv1]{"c2dictionary":true,"data":[/code:1hh3fnv1]
    before your current output, and } after it, in your php script.
    
    Took 5 minutes.
  • Sorry but could you try to explain it more, or you share a simple example describing your problem ? I don't understand a thing you said, but the fact that balls are thrown...

    I could make a joke about having two balls of not-so-natural color, but that wouldn't fit... (or would it ?)

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • You can load from JSON like you do, but your JSON has to be compatible with the JSON that Dictionary wants. To know the exact format of the dictionary JSON, manually set your keys v ant t to the wanted value with events, then use the "Download" action on the dictionary, that will download on your computer a JSON file, with the format needed.

    Once you have this format, change your script on ajaxGame.php to fit what you need.

    We did have some explanation of the same process yesterday, but with an array instead of a dictionary. As the process is the same, here is the link for more details.

  • Hum... so a clone wouldn't work then...

    Is your textbox in front of a static background ? Could you maybe put a sprite in front of the textbox and make it fade in ?

    Or just use an HTML id and make it fade out using CSS opacity directly ? (as the textbox is a native html form element)

  • You could create a textbox clone using 9patch and text/spritefont. This would be classical C2 objects that would support fading in/out. It requires some events to make them behave like a textbox does, but it should solve your problem

  • 1/ Try to explain it anyways, it's always nice and better received than "here is my capx, please fix it"

    2/ Use a file sharing program, like dropbox. It's free. It creates a folder on your computer, where everything you put in is synchronized on their servers, and you can do a right click on a file and use the option "copy dropbox link". This will copy the public url you will want to share here

Guizmus's avatar

Guizmus

Member since 26 Mar, 2013

None one is following Guizmus yet!

Trophy Case

  • 11-Year Club
  • x4
    Coach One of your tutorials has over 1,000 readers
  • Educator One of your tutorials has over 10,000 readers
  • RTFM Read the fabulous manual
  • Email Verified

Progress

15/44
How to earn trophies