7,188 reputation
1136
bio website
location
age
visits member for 2 years, 7 months
seen 2 days ago

Jan
6
comment How can I make A* finish faster when the destination is impassable?
@Desty It doesn't precisely have a name. I described it's implementation in an edit to my answer bellow.
Jan
6
revised How can I make A* finish faster when the destination is impassable?
added 1306 characters in body
Jan
6
comment How can I make A* finish faster when the destination is impassable?
@KromStern Assuming you use the vanilla implementation of A* for a tile based game, you get V * logV complexity, V being the number of tiles, for a grid of 32 by 32 it's 1024. logV, being well approximately the number of bits needed to represent 1024 which is 10. So you end up running for a longer time needlessly. Of course, if you specialize the implementation to take advantage of the fact you are running on a grid of tiles, you overcome this limitation which is exactly what I was referring to
Jan
6
comment How can I make A* finish faster when the destination is impassable?
@congusbongus This is exactly what I mean. Do not use a vanilla implementation of A*
Jan
3
comment How can I make A* finish faster when the destination is impassable?
@MSalters Well, yeah, you can compute the maximum distance but that is not the longest path problem. And the longest path program isn't NP in "path length" and not node count... NP is not like O(). NP is simply a group of all problems that cannot be computed in polynomial time so saying NP in nodes or path length is incorrect.
Jan
3
answered How can I make A* finish faster when the destination is impassable?
Jan
3
comment How can I make A* finish faster when the destination is impassable?
Flood fill or BFS each area.
Jan
3
comment How can I make A* finish faster when the destination is impassable?
@Desty You can't, it's not directed and it's not acyclic. I've never played a game where you couldn't walk back and could never go in circles. The O(n) comment was just wrong. The correct thing is that the longest distance! Not path, DISTANCE, can be computed in O(n) so if you see the shortest, (again not longest), is longer than the longest distance, than the shortest path doesn't exist.
Jan
3
comment Which server platform to choose
@drxzcl Is right. Google App engine is great for turn based games for scalability reasons.
Jan
2
answered How can I check if a player-drawn line follows a path?
Dec
31
revised Basic Connections Through Socket Server
added 1007 characters in body
Dec
31
answered Basic Connections Through Socket Server
Dec
30
revised Implementing line-of-sight in 3D?
added 330 characters in body
Dec
30
comment Implementing line-of-sight in 3D?
+1 for studying this well before asking a question
Dec
30
answered Implementing line-of-sight in 3D?
Dec
29
comment procedural generation - deterministic or not? (No man's sky)
I agree. I simply think it may be wrong in their case to store the results cause it seems like they are going to revert most things most of the time, I don't know. Space is not much of an issue nowadays as it was only 20 years ago. I +1ed your answer either way.
Dec
29
revised procedural generation - deterministic or not? (No man's sky)
added 853 characters in body
Dec
29
answered procedural generation - deterministic or not? (No man's sky)
Dec
29
comment procedural generation - deterministic or not? (No man's sky)
"you have to store (the results of) this change" That is wrong :) But this is right: "and then apply any deltas that players have created at that point in time/space", you don't store the result, you store the actions the player preforms.
Dec
28
comment Decoupling AI from game logic
Design patterns are often overused. I would suggest simply implementing a coherent and working AI, breaking it down to relatively short meaningful functions. Over-designing is a pitfall for indie developers.