Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - MattHutchings

Pages: 1 2 3 ... 15
1
Ask a Question / Get Size of Line Drawn?
« on: April 03, 2019, 06:49:18 am »
Hi guys,

Fairly straight forward question I'm trying to get the size of a line that's been drawn. How would I go about achieving this, I have the startX and the startY, with the endX and the endY?

2
[RESOLVED]
Set it up  using the atan2(y:mouseDownY-mouseReleaseY, x:mouseDownX-mouseReleaseX)as degrees


3
Hi guys,
I'm trying to create a mechanic to shoot a ball using the mouse press X and Y with the mouse release X and Y coordinates. I've managed to get it rigged up to draw the line from start point to end point and moves the ball depending on where the start point is. But my question is how can I get the direction of the line that's drawn in order to set up the velocity to make the ball move?

I'm using a couple of variables:
[Dx] & [Dy] = Mouse Down Coordinates
[Rx] & [Ry] = Mouse Release Coordinates
[Mx] & [My] = Mouse Coordinates
[Bx] & [By] = Ball Coordinates

This is my current output:
http://www.stencyl.com/game/play/40188

4
Ask a Question / Re: My Actor Shifts Position Upon Running The Game!
« on: December 21, 2016, 06:22:17 am »
Hi there,
I've came across this issue in the past. I resolved it by simply deleting the actor and recreating it again then reassigning its behavior. Might have been an issue with changing the image size when editing and just re-importing without recreating the whole actor.

Hope this helps,
Matt.

5
Ask a Question / Re: Build haxe 1 issue
« on: December 20, 2016, 05:32:29 pm »
Hi there,
What are you doing when you get this error, and can you post your log so your issue can be further investigated?

It sounds like your Haxe or OpenFL is out of date or corrupt maybe, might be worth doing a clean reinstall.

Matt.

6
Ask a Question / Re: What am I doing wrong?
« on: December 20, 2016, 05:24:49 pm »
Hi there,
Could you go into a little detail as to how your game works, (or is meant to work)?

Matt.

7
Ask a Question / Writing document to web server?
« on: December 20, 2016, 05:19:03 pm »
Hi guys,
I'm looking for a method where I can send data out to a web server that can then host the data for me and can then be used for online features in my game. I created a method a while back now where I used an isset with a PHP document to do this which all in all did work but was "laggy" due to the 1 second PHP load time. So I wanted to know if there was another way that anyone knows of to send an attribute value to a web server. (Maybe connect to the server before game loads via custom code, then using somethings like java.io to create a text document on the server with the attribute value.) I don't know would something like this be possible?

Thanks guys,
Matt.

8
Ask a Question / Re: Make Arrow Get Stuck In Wall?
« on: November 20, 2016, 01:17:32 pm »
Unfortunately, still got the same result. Thanks for all your help by the way.

9
Ask a Question / Re: Make Arrow Get Stuck In Wall?
« on: November 20, 2016, 10:34:11 am »
This has worked to a degree, however there is a slight "judder" when the arrow hits the block. Any ideas whys this is? I've updated the link as well so you can see what I'm talking about.

10
Ask a Question / Re: Make Arrow Get Stuck In Wall?
« on: November 20, 2016, 09:29:42 am »
Sorry I should have clarified the wall is an actor. I've tried this but no joy:

11
Ask a Question / Make Arrow Get Stuck In Wall?
« on: November 20, 2016, 08:56:24 am »
Hi guys, I'm looking for a method where my arrow will get stuck in the wall, rather than bouncing off. Is this possible, couldn't think of a way to do this? I posted a link to show you an example of what is currently happening. Any ideas?

http://www.stencyl.com/game/play/35604

12
Ask a Question / Bow and Arrow Mechanics
« on: November 19, 2016, 08:54:51 am »
Hi guys, I'm looking for a method to create a bow and arrow mechanism. So ie when the users finger touches the screen the arrow rotates to point in the opposite direction of the users touch motion. Then on release of their finger set the direction of the arrow in the direction it is pointing. Any ideas?

Thanks,
Matt.

13
Ask a Question / Re: Actor on tile detection?
« on: October 18, 2016, 06:01:25 am »
Okay so I've created an example game for you to mess about with and see how the method i'm explaining works. I've attached a game export to this post so that you can import it. Is this what you're looking for?
http://www.stencyl.com/game/play/35423

Hope this helps,
Matt.

14
Ask a Question / Re: Actor on tile detection?
« on: October 18, 2016, 04:10:18 am »
Try this instead,
1. Create a new actor called SpeedTile.
2. Add your animation that you had on it when it was a tile.
3. Navigate to your new actor's collisions tab and set it to sensor.
3. Place your new SpeedTile actor on your scene (make a note of the X and Y positions, from either the bottom left corner or the Inspector next to the palette).
4. Create a new actor behavior and call it SpeedTile Properties. Then attach it to your new actor.
5. Go to your Player behavior and create the same as the image.
6. Go to your SpeedTile Properties behavior and create the same as that image.

Note: The 100 and the 200 are an example of the X and Y of the SpeedTile this will need to be set to where you've got yours placed in your scene, also the SpeedTileWidth and SpeedTileHeight is a game boolean which is optional if you already know this then you can simply ignore the SpeedTile Properties behavior all in all, I just find it cleaner to have things labeled. Then if you want to do this for a second and so on use a otherwise if after your first if in the Player behavoir.

Let me know how you get on. Worst case PM me an i'll help your sort this.
Matt.

15
Ask a Question / Re: Actor on tile detection?
« on: October 18, 2016, 03:20:44 am »
Hi there,
On your player behaviour maybe try something like this. First of all find your tile you want the behaviour to effect get its X and Y coordinates.
If (X of Player is > Tile X) and (X of Player is < Tile X + Width of Tile) and (Y of Player is > Tile Y)  and (Y of Player is < Tile Y + Height of Tile).
Then perform actions...
Maybe a boolean that is set when this is true then just use that boolean to say the player is on that tile.

Hope this helps, if you get stuck let me know.
Matt.

Pages: 1 2 3 ... 15