pmurph's Recent Forum Activity

  • Hey blacksmith, thanks that cleared things up a hell of a lot. When you say to add the player and enemy values , do you mean to add them as parameters for the distance part of the equation? In the parenthesis i mean?

    I tried to add them after but it didn't work, so i added them in place of the (presumably) stockholder x1/y1 parts. I managed to get that part working and hooked up to a variable in text form on the screen just to test it, but the number shoots up at lightning speed so i still need to work that out. I figured a wait action would work but i think i'm placing it somewhere where it's doing nothing.

    Thanks again for your help.

    Paul.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Is it something to do with variables? Also if anybody can think of any particular tutorials on this subject, not to mention any decent general help websites for this kind of mathematics, As i'm not particularly well-versed in it(although eager to learn)

  • Thanks for such a fast reply, i'm a beginner so i guess i'm just not following too well at this point. I think i understand how such a condition would actually work, but i'm not at all sure how to add this condition.

    What i mean is i know to click add condition, then a list of possible conditions to add will appear , but which of these should i choose in order to enter the enemy.x/y coordinates and the tower ones. I thought it would have something to do with the whole compare x and compare y thing, but i can't seem to use either that or the compare width and height. It simply won't take those values, i assume i'm doing it wrong?

    Thanks for your patience.

  • Hi, I'm working on a tower defense game(Just for fun, i'm not particularly knowledgeable or in love with the genre but it seemed like a managable task for a change) and i'm trying to make it so that when an enemy get's to my main tower(The one you are protecting) , the tower's health(An instance variable) will go down over a period of X seconds.

    Now i know how to do the whole remove X damage every X seconds thing, but i can't think of a way of testing if the enemy is within say 2 pixels of my tower.

    Another question i have is how can i easily control how many turrets my player can create? I have it so they appear when the

    left mouse is clicked but as it stands you could create a

    thousand if you like and the on screen counter just keeps going up.....

    This is pretty inconvenient as is , especially when i consider adding more than one type of turret and some kind of points system to allow you to spend points to create them in the first place.

    If anybody out there has made a tower defense game(and i'm sure some of you must have at some point or another) , i would really like your help,

    Thanks, Paul.

  • Thanks I'll give it a try, that clears things up a bit. Sorry i wasn't too concise there haha!

    Paul

  • Yeah i used the physics behaviour entirely through trial and error in getting it working. Mainly because i couldn't figure out how to use the bullet behaviour to do what i wanted.

    At the moment i would much prefer to use Bullet because i know i can set the speed i want it to go at, i just can't figure out a way of getting the ball to shoot in the direction of my mouse cursor. Also the bounce off solids part, Would i be able to toggle the objects collisions with the ball object depending on what Key I've pressed?

    I've been trying to do it all morning with Boolean's and variables but to no avail, I'm not too clued up on all of this yet! As it stands I've managed to make it collide when i want it to, then toggle it so that the object in question no longer has collisions enabled ,but it's like when i disable the collisions the first time i can't toggle it back. Which isn't what i want.

    I need it to collide when the ball is fired at it using the left mouse button, but to not collide and allow the ball to pass over whenever it is fired using the right.

    I hope I'm being clear enough, My thoughts are a little muddled trying to figure this out.

    Thanks for the swift reply.

    Paul

  • I have a game where you can launch a ball from the player to wherever the mouse is pointing(Using physics behaviour). I noticed that depending on how fast the player is moving when he launches the ball , the ball will differ in speed. I want the ball to always go at the same speed unless i otherwise specify(a powerup for example).

    I was thinking that Bullet might work this way, but does bullet support more than 8 directions? Also how would i go able making it so that when i click the left mouse button,

    the ball is shot in the direction of my mouse cursor the same way i would with the physics behaviour(Apply Physics impulse 1 towards Mouse.X , Mouse.Y)?

    If anybody sees this and has the answer, thanks!

    Paul

  • I have a feeling the answer is going to be very obvious, but i've even tried googling words like mousex and viewport left, in different combinations and the only relevant search results are this thread.

  • I still can't seem to find any Mouse events that allow me to set the mouse x or y to anything, nor can i find anything about viewport left/right/top or down. I'm fairly new to this, I'm running the unlicensed , free version of construct 2 if that's the reason? I'm fairly new to this and i just can't seem to find any of these things in the event list. Am i clicking Add event>Mouse, and then these events should be there? That's what I've been trying to no avail so far.

    Paul.

  • Thanks for the reply again pixel, I managed to fix this by going and re-doing my whole event list more coherently. It all just sort of fell into place and i have it working now.

    Paul.

  • I'm sorry , i don't follow. Is this in the events/actions list? I can only seem to find the options to set the mouse cursor to something else...

    Paul.

  • Thanks, i can't seem to get the plugin working but i'll keep trying!

    Paul.

pmurph's avatar

pmurph

Member since 21 Apr, 2013

None one is following pmurph yet!

Trophy Case

  • 11-Year Club
  • Email Verified

Progress

12/44
How to earn trophies