Age | Commit message (Collapse) | Author | Files | Lines |
|
|
|
This replaces the rather hard to understand event dispatcher with a
probably even harder to understand templated library, but fortunately
we can rely on the available documentation.
Hopefully it will also help with the readability of our code and with
adding additional signals to other classes.
Added libsigc++ to README and Travis CI configuration.
Reviewed-by: Erik Schilling
|
|
Same thing, but shorter.
|
|
During the implementation bjorn and I agreed to limit the number of attacks that
can be used in the same tick to one. This makes a lot of stuff easier and the
client cannot display two frames at the same time
Things done:
- Implemented setting of attacks when equipping/unequipping items
- Single place where the xml attack node is parsed
- Finished attack logic
- Unified the attack handling of monsters and characters
- Added a global cooldown after attack use
(not only for next use of same attack)
- Removed the temponary attributes for the monster attack values
- Priorities for all attacks
- Rewrote the attack core:
- Attacks now have this attributes:
- warmup -> time a attack needs after starting it to actually deal the damage
- cooldown -> time a attack needs after dealing damage before another attack
can be used
- reuse -> time before the same attack can be used again
- If no attack is performed at the moment the following is done:
- make a list with all ready attacks
- check for attack that has the necessarily range and highest priority
- start this attack (inform client about it)
- when warmup is finished -> trigger damage
- when cooldown is finished -> allow to use other (or the same if reusetimer
allows) attacks
TODO:
- sync client with this to allow better timed animations
|
|
|
|
The timeout remembers a reference point of time against which it can check
how much time is remaining.
Reviewed-by: Erik Schilling
Reviewed-by: Yohann Ferreira
|
|
In preparation for using an entity/component system for the entities
in the game world, this name will be more recognizable and easier to
talk about.
Reviewed-by: Yohann Ferreira
|
|
The main change here is to remove the separate calling of 'perform' on all
beings, and rather rely on the beings to do whatever they were doing in
that function when the virtual 'update' function is called.
Reviewed-by: Yohann Ferreira
|
|
Reviewed-by: o11c, bjorn, Bertram.
|
|
This is more precise than sending the attack type, that
can be guessed by the client anyway when the type parameter
will be added in the <attack> tag.
This is the server part of Mana issue: #363.
Reviewed-by: Bjorn.
|
|
The crash happened when it was trying to move an NPC from its old zone
to its new zone. The old zone was based on the old position, which was
(0,0). That crashed since its zone didn't match its old position, but
its new one.
This fix makes sure to update the old position to be in sync with the
zone, by resetting it after being inserted into the MapComposite.
Reviewed-by: Yohann Ferreira
|
|
There was a version taking an attack range, but the range was always the
same as the one specified in the Damage class.
|
|
The server was actually using the bitmask enum while the the client
still sent another one, creating discrepancies.
A second problem is that the being direction was not properly
initialized and not updated while it was moving.
Reviewed-by: Jaxad.
|
|
Trivial fix.
|
|
Reviewed-by: Bertram
|
|
Also added an header to the autoattack.{h,cpp} files.
Big but trivial fix.
|