0
votes
1answer
38 views

What is the actual formula to find the vertices of an animation frame in using a BVH file?

I've read this tutorial and tried many formulas to build the skeleton. I am able to build it without the rotations, but those break everything. This, for example, is a simplified code for one of my ...
0
votes
0answers
36 views

Sprite rotation algorithm [duplicate]

I'm making a game where you have to plot a function to hit certain objectives. I already made the plotting function and the animation to display a tiny missile that travels above the function. My ...
2
votes
1answer
363 views

Object detection in bitmap JavaScript canvas

I want to detect clicks on canvas elements which are drawn using paths. So far I have stored element paths in a JavaScript data structure and then check the coordinates of hits which match the ...
15
votes
3answers
1k views

How do history generation algorithms work?

I heard of the game Dwarf Fortress, but only now one of the people I follow on Youtube made a commentary on it... I was more than surprised when I noticed how Dwarf Fortress actually generates a ...
3
votes
4answers
3k views

2D Collision in Canvas - Balls Overlapping When Velocity is High

I am doing a simple experiment in canvas using Javascript in which some balls will be thrown on the screen with some initial velocity and then they will bounce on colliding with each other or with the ...
6
votes
4answers
2k views

Is there a way to increase the collision check efficiency of a system of n objects?

I'm making a game that consists of many onscreen objects, one of which is the player. I need to know which objects are colliding every iteration. I made something like this: for (o in objects) { ...
0
votes
1answer
337 views

throw a 2D ball facing the target to simulate a 3D like effect

How would you update the state of a 2D object that is thrown forward(with an arc) facing a target to simulate a 3D(depth) like effect? var ball; //2D ball from a sprite sheet ball.x = 0; ball.y = 0; ...
3
votes
2answers
348 views

How to place objects/entities randomly in JS?

I'm making a game and I have a script (running it with Node) on the server that currently just randomly places things on the map... I'd like to change that. I saw something about Perlin noise but I'm ...
16
votes
4answers
4k views

Simple noise generation

I'm looking to generate noise that looks like this: (images courtesy of Understanding Perlin Noise) I'm basically looking for noise with lots of small "ripples". The following is undesirable: ...
-2
votes
1answer
530 views

Dungeon map generator not working in javascript

I am trying to convert this dungeon algorithm from java into javascript, however, my script works 70% of the time. When it works, the rooms are missing a wall on one side, and when it does not work, ...