summaryrefslogtreecommitdiff
path: root/src
AgeCommit message (Collapse)AuthorFilesLines
2013-08-26Allow abilities name for use_ability()Erik Schilling1-3/+5
2013-08-26Removed ability categoriesErik Schilling6-92/+9
2013-08-26Only call ability recharge callback if it is validErik Schilling1-5/+8
2013-08-26Use '/' as seperator for ability categories rather than '_'Erik Schilling2-6/+6
I find this a lot more readable.
2013-08-26Made cooldowns of abilities scriptableErik Schilling18-288/+166
- Removed hardcoded using of attributes - Simply introduced lua functions to set global and ability cooldowns - Requires database update - Bumps the protocol
2013-08-26Allow multiple scopes (character and monster)Erik Schilling1-4/+10
This allows you to avoid putting usually unnessecary load onto npcs if you only wanted to share an attribute between monsters and characters.
2013-08-26Readded level handlingErik Schilling11-34/+141
Things done: Wrote a entity:give_experience function (lua side only). Renamed characterpoints to attributepoints (no db update. Did not want to do one for a simple rename). Temponary introduced a ATTR_LEVEL constant. TODO: dehardcode this. Script binds for settings the correction and attribute points.
2013-08-26Removed skillsErik Schilling30-1050/+86
This removes support for skills. The plan is to allow to implement the skills as they were implemented before via attributes. This adds a lot more flexibility to the server creators while also removing the confusion about skills and attributes. So this change does: - Remove the skillmanager with all its calls, the skill xml file, etc - Move exp giving to the script engine: --> Allows to implement the old behaviour (and more) in the scripts - Remove the exp tag from the monster definition: + Since the server itself does not require it anymore it feels wrong to require it for EVERY monster. TODO: Add a system to add properties to the monsters/items.xml which allow defining things like the exp and allows to read the value from the script engine. + Small drawback, but it should not be hard to implement this property system. - Drop the level networking and calculation. + level calculation will happen via the attribute system later but i would prefer to do this in a seperate patch since this patch already got longer than expected especially since this requires to make setting correction points and available status points scriptable. + The level would be simply set as a attribute, the int number of it will be the level, the remaining digits will be the % number till the next levelup. - NOT remove any existing skill tables in the database update scripts. + There is no way to move them into the attribute table in a unified way (there are too many different way they could have been used). So server admins have to care about moving theirs skills to attributes themselves. + Keeping the old tables does not hurt for existing databases. So removing does not give any advantage/is required anyway. The now obsolote info about the EXP transaction is not removed for updated databases either. (The update script basically only bumps the version number without doing anything else. - bump the network protocol version --> old clients won't be able to connect. - bump the database version --> serveradmins need to update their db.
2013-08-26Allow names instead of ids for attributes + cleanupErik Schilling14-199/+208
I did not adapt the scripts yet since we need some special handling for the attributes which are required by the server directly. So you still have to use the ids for those. I will change that later. In the future I want to use the AttributeInfo class instead of the int id everywhere possible. So I did a small start on that too.
2013-08-26Warn when defining an attribute without a scopeErik Schilling1-3/+3
Attributes without a scope make no sense.
2013-08-26Added a first very basic monster ai versionErik Schilling1-15/+0
The ai is similar to the old c++ version. Only the target searching is executed every 10 ticks only now to prevent performance issues with too many lua calls.
2013-08-26Added look_at bindErik Schilling1-0/+33
2013-08-26Fixed setting name of monstersErik Schilling1-2/+2
2013-08-26Added tick argument to the monster update callbackErik Schilling1-0/+1
2013-08-26Removed the hardcoded monster AIErik Schilling3-202/+1
2013-08-26Added entity:destination() bindErik Schilling1-0/+18
2013-08-26Added function to check for length of a possible pathErik Schilling3-9/+54
2013-08-26Added get_monster_classes() bindErik Schilling3-2/+28
It returns all monster classes in a id->monsterclass table.
2013-08-26[Abilities] Added abilities to monstersErik Schilling6-26/+140
Monsters can now either receive abilities at lifetime via scripts, or via the <ability> node in the monsters node.
2013-08-26[Abilities] Removed the old autoattack systemErik Schilling25-1899/+15
As a side effect i had to remove the monster attack AI for now. I will readd this as next thing.
2013-08-26[Abilities] Added a add_hit_taken bindErik Schilling5-30/+51
This allows to display hit messages in the client for abilities
2013-08-26[Abilities] Inform other players about ability usesErik Schilling5-4/+77
2013-08-26[Abilities] Added support for a global cooldownErik Schilling11-40/+141
Each ability can now define a cooldown that prevents the player from using other abilities for a while. The time of this cooldown can be set to any attribute. The modified value of the attribute is the value of the cooldown in game ticks. The cooldown will be automatically started if the ability has `autoconsume` set to true. Otherwise a script has to call entity:cooldown_ability(ability).
2013-08-26[Abilities] Added a autoconsume optionErik Schilling3-0/+14
You do not need to reset the mana in the scripts if you do not want to. We will need this for attacks later since those do not nessecary have a script.
2013-08-26[Abilities] Moved the ability code into a own componentErik Schilling9-255/+355
This later allows monsters and characters to use this component.
2013-08-26[Abilities] Made the rechargespeed depending on attributesErik Schilling6-87/+25
This allows a lot more flexibility and makes stuff like magical items a lot easier to implement. We will also use this for the attack system in the future. So a attack (abilitiy) would simply depend on some value like Agility (or a derived attribute from it). Which sets the recharge speed. The recharge speed is the modified value of the attribute per game tick.
2013-08-26[Abilities] Only send status for actually changed abilitiesErik Schilling2-15/+17
Previously *every* ability was spammed over the network regardless whether it was changed or not.
2013-08-26[Abilities] Added network message for removed abilityErik Schilling2-1/+4
This prevents really nasty code clientside
2013-08-26[Abilities] Renamed set to categoryErik Schilling6-30/+30
On the one hand setSetName and setName could sound misleading in the qt client patch i plan. On the otherhand i never really liked the name "set". I think category is more general and obvious.
2013-08-26[Abilities] Renamed specials to abilitiesErik Schilling24-640/+698
2013-08-25Use std::unique_ptr for Account instance of AccountClientThorbjørn Lindeijer3-38/+32
Makes cleanup automatic and ownership somewhat better recognizable.
2013-07-28Allow -v for setting verbosityErik Schilling2-4/+4
I am really bad at spelling verbosity :->
2013-07-19Adapted the inline documentation for markdown docsErik Schilling1-163/+226
2013-06-18Allow manaserv to be built with external ENetBrian Callahan1-3/+9
2013-05-10Partial rewrite and improvements of Warp objectPrzemysław Grzywacz4-30/+180
2013-05-03Maps are now configured in settings.xml tooPrzemysław Grzywacz4-70/+82
2013-05-03Made member function tables available as a globalsThorbjørn Lindeijer1-0/+5
This way the scripts can add or replace existing member functions, which can be useful. As demonstration chr_money and chr_money_change are now added as Entity.money and Entity.change_money. Also fixed the banker to use ask_number instead of ask_integer (I had decided to rename this and apparently forgot the banker). Mantis-issue: 503 Reviewed-by: Ablu
2013-05-02Fixed a bunch of cppcheck warningsErik Schilling21-93/+78
2013-04-30Bumped the protocol version to 3Thorbjørn Lindeijer1-1/+1
Version 2 was on the lpc2012 branch. With version 3 the lpc2012 and master branches use again the same protocol.
2013-04-29Single xml solutionPrzemysław Grzywacz21-569/+884
Mana-mantis: #506.
2013-04-29Fixed two SQL queries that broke since NULL -> nullptr replacementThorbjørn Lindeijer1-3/+3
2013-04-27Warn at failing overridesErik Schilling1-1/+2
2013-04-27Use nullptr instead of NULL everywhereErik Schilling39-78/+78
2013-04-27Fixed typo in script docsErik Schilling1-1/+1
2013-04-25Fixed crash when checking whether a character is already onlineThorbjørn Lindeijer1-3/+2
Not every connected game client has a character in the world. The code was checking this, but since commit aa04597c5f8bb806996 the pointer was being used before being checked.
2013-04-25Simplified BeingComponent::updateDirectionThorbjørn Lindeijer2-74/+7
Same as in the client.
2013-04-15Forgot to rename npc_message in some docsThorbjørn Lindeijer1-11/+11
2013-04-15Fixed small script documentation errorThorbjørn Lindeijer1-1/+1
2013-04-15Fixed error messageThorbjørn Lindeijer1-1/+1
Thanks to Ablu for noticing.
2013-04-15Used static_assert for static assertionThorbjørn Lindeijer1-1/+2
Yay for C++11! static_assert is available since GCC 4.3. Fixed warning when compiling with GCC 4.8: src/utils/mathutils.cpp:53:18: warning: typedef ‘float_must_be_32_bits’ locally defined but not used [-Wunused-local-typedefs]