GideonG's Recent Forum Activity

  • The problem with using that method though is that I'm using the browser to allow the user to choose an image from their storage, which is then opened as a sprite.

    Although the way you solution reads, it may still work, actually. Thanks for your help all!

  • Hey all,

    Sorry to be pestering with multiple posts, but I was wondering if there is a way to dynamically change where an origin point is during run time. My sprite object changes size and dimensions a lot, and I need to somehow keep the origin point at the centre of the image during all of these changes, so that the sprite remains correctly possitioned in the layout. The problem is though, I have no idea how to do it! XD

    Thanks in advance for any help you can give!

  • I'm guessing this is probably a really 'noob' question, but for the life of me, I can't get C2 to get it to work. What I basically want to be able to do is choose a file (in my case an image) with 'File Chooser' and then have it show up as an image for a sprite object.

    I've done a bit of research and seen that I should be able to do it with 'Load image from URL' and something about "blob:", but then it calles for a unique ID and I have NO IDEA what to use/do. I'm assuming this is just because I'm a total dunce and rookie with C2, so any help would be greatly appreciated!

    Thanks!

  • Oh no!

    I didn't see that! Thanks so much guys! That's really helpful!

  • Hey everyone,

    I was just wondering if there is a way to set different instances of the same object/sprite to have different graphics?

    Thanks in advance for any help everyone can give!

  • Thanks for all your help guys! That is really helpful!

    TheWyrm unfortunately, I tried to implement what you explained about the factors and setting the new size, but to no avail. I'll have to look into this aspect of things a bit further!

    Anyway, thanks for all of your help!

  • Hey everyone!

    I have a question relating to collisions and instances that is currently confusing me no end, and I was wondering if anyone could help me?

    Basically, my game will have multiple instances of one object, which will differ in size/scale. Ideally, I want to make it so that when various instances of these objects collide, the biggest instance of the object absorbs the smallest/smaller one/s.

    How should I go about this? I was thinking it may be something along the lines of sub-events with triggers relating to 'Pick by Evaluate', but I'm fairly new to Construct 2 and thought I would ask the wisdom of experts.

    Any help anyone can give will be greatly appreciated!

  • I would create a third condition for buying the new screen, which could either be a global or instance variable.

    For example, in order for a player to buy a new screen, I'm assuming the action has 2 conditions, 1) he touches the sprite, 2) he has more more than one coin. What I would suggest doing is creating another action when the screen is bought that sets a variable (for example we'll call it 'bought' to 1) and you give the event a third condition that 'bought' must not be equal to 1.

    Sorry if this doesn't make too much sense, I hope it helps out a bit!

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • hundredfold That's precisely my problem, I need the trail to be affected by all physics that apply to the actual projectile, except I need any objects it hits not to be effected, because otherwise, when aiming the projectile, it will make the other physics based objects react as if they had been struct with the actual projectile. I don't suppose there is a way to 'turn off' collisions with a particular physics based object? (in my case the trail?)

    Katala thanks for the link! Unfortunately, my project uses multiple dynamic gravity sources, so something mathmatically based like that would take incredible calculations simply beyond my ability. Thanks anyway!

    Thanks so much for the help you guys are giving me, it's great!

  • I know this question comes up a lot (I've been looking around before coming here), but usually in relation to the bullet behaviour rather than the physics behaviour which is what I'm using.

    Basically, I want to implement a prediction of where an object will travel after it is 'launched' from a point (A little like the aiming thing in the 'Peggle' games and such). Because the object will be effected by the gravity of other masses, I *think* I have to do this also using the physics behaviour, which opens up a few problems. By my logic, I could create a second object that has the same physical properties (parameters of the physics behaviour) that is automatically launched every few ticks when aiming the actual object to be launched, and then fades until deleted. This however spawns the problem that the aiming objects interact with other physics enabled objects, for example, sending any moveable object flying.

    I was wondering if there is a way I can turn off an objects ability to move a physics enabled object without changing any parameters, or rendering the object they bounce off immovable. Alternatively, is there any other way I can set up a 'guide' of where the launched object will travel?

    Any help will be greatly appreciated!

  • So sorry it took me so long to reply! I wanted to implement all your help and get it working before getting back to you! Thank you SO MUCH for all your help guys!

    hundredfold, I agree, my first project was exactly that, a setup where you could alter variables and then see how it effected the orbit, but for this one I needed 'perfect' orbit.

    R0J0hound, I can't tell you how much you helped me what I needed to do! Thank you so much man! Incidentally, I noticed in the thread you linked, you said that you had to find a conversion factor of 48.8, I THINK (and only think, because I'm new to the physics plugin) that that may be needed because impulse 'force' (or rather how fast it travels once the impulse has been applied) follows the algorithm that 'Velocity = Impulse/Mass (2500)', which would mean that different levels of 'force' for an impulse can lead to some crazy velocity (in pixels per second).

    Anyway, I have everything working as it should now, thanks again!

  • Hi everyone!

    This is my first post on the forums, but I would love some help with setting up a dynamic orbiting system with the 'physics' behaviour. I've looked at a heap of different topics on the forums relating to orbit, but alas, as yet I am yet to fix my problem. Basically, I want the user to be able to drag and drop (using the plugin) a 'planet' and have it automatically fall into a perfect circular orbit of a 'sun' (both objects).

    As my project currently stands, I am using events to specify that as soon as the planet is 'dropped' onto the layout, a force is enacted upon it pushing it towards the sun (to simulate gravity) using a relative formula that says force = distance(planet.X,planet.Y,Sun.X,Sun.Y)/100. This works fine, because the further away the object is, the weaker the 'gravity' is.

    I also have it set up so that when the planet is dropped, there is a physics impulse striking it at angle(Planet.x,planet.Y,Sun.X,Sun.Y), which means that wherever the planet is placed, it begins an anti-clockwise rotation. Again, this works as planned.

    My issue lies entirely with the force of impulse itself. At the moment I get irregular elliptical orbits depending on how far the planet is from the sun, which makes me assume that the 'force' of the impulse will need to be relative to the distance between the planet and the sun, however as to the formula for the force, I am clueless.

    Thank you so much in advance for any help anyone can give!

GideonG's avatar

GideonG

Member since 18 Nov, 2014

Twitter
GideonG has 1 followers

Trophy Case

  • 10-Year Club
  • x2
    Great Comment One of your comments gets 3 upvotes
  • Email Verified

Progress

12/44
How to earn trophies