apathy
Level 0
|
|
« on: April 23, 2011, 06:36:59 PM » |
|
I've got a 5 day weekend, so I decided to make a game from scratch. I've never made an isometric or heavily pixellated game before, so this is more of a technical exercise that a serious attempt at making a game (for now). Anyway, a screenshot at the end of day 2: the 'wise-man' player character firing off some fireball/nova style thing. Its actually day 3 but I spent the morning reading Griftopia instead. Anyway, the plan for the day is monsters/AI of some description. Maybe some meaningless stats and a 'ui', who knows? Some other details I guess, its written from scratch in opengl/c++ (i've only got access to osx at the moment, but i'll provide a download on day 5). The map is procedurally generated, including a big path-finding network that i need to smooth out at some point but im lazy (so you can run around the map and whatever). The map is actually a lit 3d mesh so I can rotate it in real time (but that gives some weird but excellent pixel swimming ). One other cool thing about the map is because its actually 3d, projectiles are blocked by hills, which I never planned on. The sprites are from the this tileset, though I'll probably substitute it with my own at some point (maybe (not an artist)). s.
|
|
« Last Edit: April 25, 2011, 11:30:08 PM by apathy »
|
Logged
|
|
|
|
BomberTREE
|
|
« Reply #1 on: April 23, 2011, 07:57:01 PM » |
|
I Love that screenshot so much.
|
|
|
Logged
|
|
|
|
DementedChicken
|
|
« Reply #2 on: April 24, 2011, 03:20:52 AM » |
|
Cool! Pixelated goodness! A 5-day weekend, ay? By any chance are you from New Zealand or Australia? (ANZAC day + weekend + easter)
|
|
|
Logged
|
|
|
|
apathy
Level 0
|
|
« Reply #3 on: April 24, 2011, 04:38:44 AM » |
|
Pharaoh!! *shakes fist*Lots of enemies chasing me around, I can kill them, they cant kill me. Yet. So much work for so little results. Should have programmed things the old fashioned way and chucked everything into a monolith base class, but no, I had to try new things out. I'm currently fueled by red wine and happy hardcore and think I'm going to rewrite the pathfinding so the search space is smaller, and so diagonals are allowed. Spot on about the Australia/New Zealand thing, by the way (Australia).
|
|
|
Logged
|
|
|
|
DementedChicken
|
|
« Reply #4 on: April 24, 2011, 04:11:53 PM » |
|
Aha! I knew it! I am from that small island country to the south-east of you with the brown flightless bird. Anyway, good luck! I better get cracking too ...
|
|
|
Logged
|
|
|
|
apathy
Level 0
|
|
« Reply #5 on: April 24, 2011, 06:42:10 PM » |
|
Path-finding changes done. Literally a game-changer. I dont have fancy screenshots, just debug before and after ones. The before shot shows the old path-finding system where every grid tile was its own node, and there where only connections along the x and y axes. So movement was constrained to really awkward L-shapes. Which was total rubbish because the player isnt a knight. The new one does some hack bullshit which attempts to group nodes together (the yellow rectangles). So now, when you click on the screen, it path-finds to the nearest group, cutting corners where its able to. Within a group, the player is completely free to move around in any direction, which is much more sensible and makes running away from Pharaoh much easier. The final little fix (that i'll do next) is kind of hard to explain, but given the groupings, its actually possible to figure out where impassable 'walls' are. So then at every pathfinding node, you cast rays through the map to the node after the node after this node (e.g. if you have a path A -> B -> C, you cast a ray from A -> C), and if no walls were hit, its safe to remove the middle node (e.g. node B), which will smooth out the path even further. This is totally no longer a 5 day game. I'm having way too much fun and cask wine edit: oh yeah, here is some screens of the retarded (in a good way) rotation effect in action: first, second
|
|
« Last Edit: April 24, 2011, 06:49:00 PM by apathy »
|
Logged
|
|
|
|
apathy
Level 0
|
|
« Reply #6 on: April 24, 2011, 11:18:54 PM » |
|
path-finding is way hard, but the chucking in walls to trim down and smooth out the path totally works. I feel like i need to write an old school rogue-like dungeon generator to see if it handes it sensibly.
|
|
|
Logged
|
|
|
|
apathy
Level 0
|
|
« Reply #7 on: April 25, 2011, 11:33:53 PM » |
|
so dragging the mouse around was hideously slow due to mouse picking the terrain. so i wrote a basic quad tree and literally got a 20x speed-up. which is good because im planning on massively extending the play area 'soon'. also i added pickups.
|
|
|
Logged
|
|
|
|
eclectocrat
|
|
« Reply #8 on: April 25, 2011, 11:44:26 PM » |
|
Damn that looks amazing. I feel so stupid when I read how people get things working so nicely and so fast, when I struggle for days to achieve a less technically impressive result. Some people just 'got it', and you sir, are one of 'em.
Can't wait to play!
|
|
|
Logged
|
|
|
|
apathy
Level 0
|
|
« Reply #9 on: April 30, 2011, 01:34:30 AM » |
|
all next gen games need shadow mapping right? i also removed all the degenerate tris from the generated mesh, which dropped the polygon count by 85%, which is both horrifying and hilarious.
|
|
|
Logged
|
|
|
|
|
agersant
|
|
« Reply #11 on: April 30, 2011, 03:57:41 AM » |
|
These new shadows don't make much sense to me ? Are they projected shadows from clouds in the sky ?
Also, rofl at the twindow title. Keep up the good work !
|
|
|
Logged
|
|
|
|
apathy
Level 0
|
|
« Reply #12 on: April 30, 2011, 10:22:09 PM » |
|
yeah, they were pretty broken in that screenshot. lots of light bleeding at the base of hills, and the 25 sample pcf filter i was using was overkill. anyway, i rewrote it to use rgba float textures for extra precision and hardware filtering, and switched to using variance shadow mapping which helped. then i added some hacks to fit the lights view frustrum to the main cameras frustum and that fixed all the weird shimmering and flickering around the edges of the map. hooray. still need to add a slop bias, but im lazy. oh and switched to layered variance mapping to get rid of any remaining light bleeding, though i dont think my scenes suffer from it (yet). here is some comparison screens with the earlier images i posted, i think they look tonnes better now. before and afterbefore and afteralso, added animation support. productive.
|
|
|
Logged
|
|
|
|
BomberTREE
|
|
« Reply #13 on: May 02, 2011, 12:45:14 AM » |
|
The shadows kinda kill the look, possibly tune down the opacity?
|
|
|
Logged
|
|
|
|
|