Commit Graph

77 Commits

Author SHA1 Message Date
Linus Probert 2813a571e4 Separate player movement from input event loop.
Wrote a keyboardinput object but decided against using it for the time
being. I'll leave it in if I change my mind.
2018-05-17 23:14:42 +02:00
Linus Probert a7822331f8 Hopefully handle the "event overflow exploit"
There was an exploit where a keyboard would fire events quicker then
they could be consumed. This would lock the main game loop in the
SDL_PollEvent loop and block rendering until the key in this case was
released. Combning this with an attack meant that you could "farm" one
NPC for multiple kills and massive XP gains. Leaving the player at level
8+ on dungeon level 1. This fix should mitigate such shenanigans.
2018-05-16 19:09:01 +02:00
Linus Probert bc0d194dce Additional fall sounds
Wilhelm scream
2018-05-16 15:52:39 +02:00
Linus Probert fa8797a20f Removed a memory leak and MACROD colors 2018-05-15 23:21:28 +02:00
Linus Probert 6d5acc698e Nicer labels in many places. 2018-05-15 14:12:38 +02:00
Linus Probert d6daf7b798 Nicer action texts 2018-05-15 11:16:56 +02:00
Linus Probert 524e10ac8f Adds camera shake.
Removed some old buildfiles that had accidentally made it into the repo.
2018-05-13 23:32:44 +02:00
Linus Probert 3e6976d2cc Adds texture creation of gui frames to reduce render time
Also enables leakchecking and removes leaks from hashtable tests and
some other leaks that were obvious. There are some X11 leaks still
present but I don't think these are caused by me.
2018-05-09 00:21:38 +02:00
Linus Probert a350f66290 Removes some of the spammy logs.
Not as important now that there is an in game log.
2018-04-28 19:03:23 +02:00
Linus_Probert cee584832e Fixed multiple pits in layout file 2018-03-26 13:53:45 +02:00
Linus Probert 0a21a2d915 Adds falling into pits
Monsters also avoid pits. Still need more pit layouts and
prevent monsters from "spawning"  in pits.
2018-03-25 23:30:26 +02:00
Linus Probert 7386b3d582 Adds levelcaps to skills
Still need to add the sparkles when they activate
2018-03-23 22:03:34 +01:00
Linus_Probert 07136c70f9 Windy rooms affect player
Left a possibility to make it affect projectiles.
2018-03-15 16:30:41 +01:00
Linus_Probert d6c21745cd Add possibility to retrieve thrown daggers. 2018-03-13 16:51:08 +01:00
Linus_Probert ac180d1efb Limit the number of daggers carried.
There is a "dagger count" on the player now. Also added the "dagger"
item that can be dropped by monsters.
2018-03-13 16:13:54 +01:00
Linus Probert c360aa75ee Added dagger throw skill
There are still some quirks that could need some love surrounding this
skill. Check the reset countdown for example.
2018-03-10 22:04:03 +01:00
Linus Probert be8677cb39 Adds projectiles
Collisions still need implementing and an underlying skill + some drawing.
2018-03-08 00:58:26 +01:00
Linus Probert 5e0bbe423d Added nice info messages across the screen 2018-03-07 16:02:56 +01:00
Linus Probert 0b98cad726 Fix bug with player hit text and prevent fight pickups 2018-03-03 00:54:50 +01:00
Linus Probert f7ec1195f4 Adds skill return countdown.
Also removes ability to wall-bonk exploit the countdowns.
2018-03-02 17:05:13 +01:00
Linus Probert 7e596a251e Adds the charge skill 2018-03-01 13:48:03 +01:00
Linus Probert da2ec32981 Removes some duplicate code in player.c 2018-03-01 06:14:01 +01:00
Linus Probert c42e6fa621 Removed all the warnings from gcc 2018-03-01 06:04:12 +01:00
Linus Probert 2253479532 Adds skills, 'flurry' skill and sip_potion skill.
Removes shift-h sipping.
2018-02-28 22:31:38 +01:00
Linus Probert 131c0caa4e Memory usage improvements
Adds a texturecache to prevent multiple loads of the same texture. Texture
dimension is now only intended for the actual texture dimension. Sprite
should hold the "rendering dimension". Music songs now load and unload
when switching songs. Standardized a lot of dimensions.
2018-02-23 23:58:29 +01:00
Linus Probert 2a3f5aaa6a Added physfs for file loading and safety. 2018-02-22 12:36:24 +01:00
Linus_Probert 94363a2e95 Added monster stats generation to lua. 2018-02-20 14:22:26 +01:00
Linus_Probert 548eecf3c0 Added some sound and music toggles 2018-02-20 10:45:54 +01:00
Linus Probert d5914071d4 New license. MIT -> GPLv3.0 2018-02-16 18:11:26 +01:00
Linus_Probert 5fce60b44d Player hit sound 2018-02-16 14:16:21 +01:00
Linus_Probert a26c7be122 Use the random generator instead of rand() 2018-02-15 14:45:20 +01:00
Linus_Probert f4867551a1 Added a lot of sound and music. 2018-02-15 14:00:59 +01:00
Linus_Probert cfa522009e Adds functioning player death and introduces better XP threshholds.
I'm pretty sure I've done the XP thing before. Perhaps I never comitted
that code?
2018-02-14 11:00:34 +01:00
Linus_Probert b2b0103b4f Introduced centralized keyboard handling 2018-02-12 10:55:36 +01:00
Linus_Probert 08207f5e35 Bloodspatter based on damage. 2018-02-09 13:55:57 +01:00
Linus_Probert 0b2a29fe3b Hilite current tile under mouse
This is intended for spell usage once I get that in.
2018-02-06 16:53:48 +01:00
Linus Probert 93c0623fe4 Implemented a simple particle engine. 2018-02-03 23:39:49 +01:00
Linus Probert e7e412cc33 Nicer gui and stored potions. 2018-02-03 13:02:39 +01:00
Linus_Probert 9550840a7a Fixed compiler warnings 2018-02-01 09:04:19 +01:00
Linus Probert a0b86eb06d Memory leaks and left over debug prints 2018-01-31 16:55:48 +01:00
Linus Probert 5dff9a9452 Added an XP bar. Need some text to go with it next 2018-01-31 13:52:11 +01:00
Linus Probert 6dc08b8a6b Simple calculation function added. 2018-01-31 10:49:13 +01:00
Linus Probert c19fb67279 WASD movement and more logical monsters in levels. 2018-01-30 21:05:33 +01:00
Linus_Probert b13479b5e1 Monster levels, player death and player levels 2018-01-30 15:16:14 +01:00
Linus_Probert b3d48bd397 Items can now contain items. 2018-01-30 13:44:21 +01:00
Linus Probert 76ddc6c529 Codacy fixes 2018-01-29 18:30:14 +01:00
Linus_Probert 6e6a9641ae Monsters now drop both treasure and items. 2018-01-29 13:48:44 +01:00
Linus_Probert ed63d7a67c Tweaked stats. 2018-01-25 16:42:57 +01:00
Linus_Probert 969af2f8c2 Better labels, more treasure 2018-01-25 10:45:05 +01:00
Linus Probert 417cb78f31 Added items, so far only health that always drops. 2018-01-24 21:14:34 +01:00