Jump to content


Ajw1995

Member Since 28 Oct 2011
Offline Last Active Jan 15 2012 04:05 AM

Posts I've Made

In Topic: Slopes problem.

10 January 2012 - 03:43 AM

You need to trace the object's path to the point where it hits the slope. Then, draw an imaginary line at a right angle to the slope and mirror the object's velocity in it.
NB: To draw a right angle, divide negative one by the gradient.

In Topic: function/way of making autotiles?

10 January 2012 - 03:20 AM

Try:

With tle_water
if y - 32 = other.y
other.tex1 = sprite_get_texture(spr_water_grass_top,0)
else if y + 32 = other.y
other.tex1 = sprite_get_texture(spr_water_grass_bttm,0)
else
other.tex1 = sprite_get_texture(spr_water_grass_mid,0)

In Topic: ds_grid functions broken

10 January 2012 - 02:01 AM

I'm having problems with grids as well... Using GM 8.1. Every time I store a value, it reads back as 0. I really don't think it is just me, because I have made a test game with one object whose purpose is only to write to and read from a grid. It read 0 every time - does the ds_grid_set function return a value if it fails?

In Topic: Problem: Making Enemies That Avoid Each Other

01 January 2012 - 04:59 AM

"Posted 07 May 2008 - 02:01 AM"
If he hasn't solved it in more than 3 years, he's probably moved on.
[/quote]

derp. I always forget to look at the dates.

In Topic: Problem: Making Enemies That Avoid Each Other

30 December 2011 - 11:07 PM

Would it help you to break your map up into basic large areas, (i.e. use a navigation mesh), do your pathfinding, and then use a collision avoidance system within each area? It would reduce the amount of pathfinding needed, and your units wouldn't collide. I recommend Paul T's big rant about navigation meshes, at www.ai-blog.net/archives/000152.html and Craig Reynold's papers, which comes with some limited source code examples, at www.red3d.com/cwr/steer/ and www.opensteer.sourceforge.net/