Jump to content

  • Log In with Google      Sign In   
  • Create Account


Thanamos

Member Since 26 Mar 2008
Offline Last Active Nov 26 2013 06:41 AM
-----

Topics I've Started

Simulating units 'flooding' a door

08 May 2013 - 06:04 AM

Im working on a small Tower Defence kinda game with a little twist, all of the enemy units will be released at once and it's upto the player to constrict their numbers into tunnels. 

 

Of course I started with all the easy parts like towers and stuff but now I have to write the logic for crowd management, and I am abit unsure if there are any good algorithms for this?

 

Quick example...

 

Attached File  queue.png   2.05KB   24 downloads

 

Here is 8 units trying to squeeze though a door which only allows one unit at a time.

 

I have already created a A* grid so I know where they are supposed to go, but it's the queue principle im struggling with.

 

Appretiate all the help.


When to start planning Kickstarter

17 September 2012 - 06:18 AM

Hi guys, open questions here.

When should I, ideally, start planning for a Kickstarter campaign?
I got a game planned, about the same size as FTL (www.ftlgame.com), and I feel this game has real potential, but I know myself, first of all I can't draw, neither can I produce music, so I need to hire someone do to all these things, and that takes money. I have starting developing the framework, as well as some decisions regarding 2D library, sound library.

But seeing all the other great ideas on Kickstarter (FTL, Castle Story, Project Eternity, Dead State just to mention a few) Im afraid I have to be near completion before I can even start considering using Kickstarter.

So it's a balance of what to plan, and what to actually finish before showing the game off to other people.
Also Im thinking a kickstarter campaign would be a greate idea to put pressure on myself to actually finish the game, having other people know, and wait for something Im making is a wonderful thing that shouldnt be underestimated.

So what says the people? How much of an demo, trailer do you need before you would consider pre-ordering a game? Spescially considering how easy I could be to just take the money and not release anything. And of course my name is completely unknown and that is an added liability.

Storing battleship data in a table

14 February 2012 - 08:07 AM

I am writing a small battleship clone in flash with multiplayer functionality and while designing I came across the fact of having to store the whole board for each game.

I need to store every 100 cells (10x10) for state (state includes x, y, ship, hit, miss), but ofc I don't want to have a table with 100 columns.

My first thought was to have a column with char(100), and then just write a long string with 100 values to that column.

That will work, but I wanted to run this issue here and see if there is a better, smarter way to do this...

Thanks in advance guys

Distance to obstacle in flash

27 April 2011 - 03:07 AM

tl;dr;
How can I find the edge of an object in flash when I know the origin and a movement vector?
I am making a sideways scroller in flash and for the first time I am trying to create a tiny bit more advanced physics then usual.

Usually this would be the onTick event:

GetPlayerPositionRectangle();
AdjustRectangleBasedOnKeysPressed(); // eg. If key.LEFT is pressed, decrease rectangle.x by a constant speed
if (WillNewRectangleFitInTheWorld())
MovePlayerToNewPosition


This works fine for having a constant speed, but say that the speed is 4 pixels per frame, if the wall is 3 pixels away this will fail and the players will never be able to get closer to the wall, this looks really bad.

So I want to add another line to the function, and it's there im facing a design question.

I want to write:
GetPlayerPositionRectangle();
GetDirectionVectorBasedOnKeysPressed(); //This will allow me to add gravity and other stuff
AdjustLengthOfVectorBasedOnTimeSinceLastFrame();
ForEveryCornerOfTheRectangleGetDistanceToObstableAccordingToVector();
MoveXYBasedOnDistanceToObstaclesLimitedBySpeed();

This is a better solution for more reasons, I can have a better boundingbox on the moving object.
The moving object can move closer to obstacles,


But the real issue here is getting the distance to the edge of an object based on a direction arrow, here is a small illustration:
Attached File  physics.png   4.31KB   28 downloads

(Black boxes are obstacles, red box is bounding box, grey arrow is the movement vector, green line is where the point I need to find)

I am fairly certain that this has been asked before, but Im not sure what to search for to get answers, so here goes.

What math formula to use?

06 June 2010 - 11:58 PM

Generic question I know :)

Im planning a game where the user can modify his weapon with addons, and I need to calculate the value of the weapon.

Example: The player has a club which has a base damage of 4, but he can add nails to the club.
The first nail he adds increases damage alot, with 50% to a total of 6.
The second nail increases damage too, but not quite as much, say maybe 35%
And every additional nail adds less and less extra damage.

The important thing is that the sum of extra damage should never exceed 100%, but it might be close to it.

I havent done real math since I went to school, but I think I remember 2nd degree algebra had nice graphs that never quite hit a designed value?

Or am I grasping at straws here?

Be gentle :)

PARTNERS