Age | Commit message (Collapse) | Author | Files | Lines |
|
The client needs to know the URL to open in the browser. The bare token
is still sent as well, which might allow the client to directly interact
with a Stellar wallet in the future.
|
|
* Added PAMSG_STELLAR_LOGIN / PAMSG_STELLAR_LOGIN_RESPONSE, which is
used by the client to request a login token that can be signed using a
Stellar wallet.
* Added uWebSockets dependency, used to listen for a separate server
that verifies signed tokens (the Stellar Bridge). When a token is
verified, it is sent to manaserv-account, which then sends a
APMSG_LOGIN_RESPONSE to the client matching the token.
* Added RapidJSON dependency to parse the JSON WebSocket messages.
* To keep everything in a single thread, uWebSockets is now driving the
event loop. Processing of ENet hosts, writing stats and expired bans
have been moved to uSocket timers.
* C++ standard updated to C++17, as required by uWebSockets.
When Stellar is used to login, the public key is used as the username.
It might be better to introduce an explicit field for this, especially
when we want to enable an account to feature both Stellar login as well
as login with username / password.
|
|
This makes it easier on the client to decide whether to immediately open
the Create Character page or to go to the Choose Character page.
Still supports client version 9 as well.
|
|
|
|
Without this message it is not possible to reliably know how many items
were traded with an NPC at the client side. It helps with updating the
shop's inventory.
|
|
|
|
|
|
|
|
NPCs, monsters and character are all actors, but no entity exists that
has "actor" as its type.
To avoid having to increment the protocol version, the values of the
different entity types are now mentioned explicitly.
|
|
The old connection is now terminated. And the new connection will
receive the character data properly.
|
|
I did this patch quite a while ago. Big thx to Stefan Beller for
"rebasing" it.
|
|
|
|
|
|
I had to rearrange the protocol a bit in order to allow to keep the
related things together.
|
|
Things done:
- Removed the equips table and added another column which keeps track about
whether the item is equipped or not
- Added a message to notify the client about failing equips instead of
hardcoding to chat notification
- Removed the move possibillity. It was a quite long function and our future
idea of the inventory does not need any moves
- Removed the inInventory and inEquipment parameters from chr_inv_count,
but added a equipped key to the table that chr_get_inventory returns
This change makes equipped items still being in the inventory. This means
in-inventory triggers are still active! However it makes no sense to disable
this triggers during equipping since it will appear as still in the inventory
to the client.
|
|
|
|
- Removed hardcoded using of attributes
- Simply introduced lua functions to set global and ability cooldowns
- Requires database update
- Bumps the protocol
|
|
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.
|
|
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.
|
|
As a side effect i had to remove the monster attack AI for now. I will
readd this as next thing.
|
|
|
|
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).
|
|
This prevents really nasty code clientside
|
|
|
|
Version 2 was on the lpc2012 branch. With version 3 the lpc2012 and
master branches use again the same protocol.
|
|
If you set net_gameServerName you can now reserve maps in the maps.xml.
There you have to add the servername - property to the <map> tag.
Then the map will only be activated by that server.
Also changed the activate sequence that the account server now tells the game
server what maps to activate (previously the server requested all maps and the
account server said yes or no).
TODO: Fix general inter server map switching.
|
|
|
|
Gender is shared. There is no reason in duplicating code
*Breaks compatbility with old clients*
*Requires clientside patch*
Reviewed-by: Stefan Beller.
|
|
Change is tested.
Reviewed-by: bjorn.
|
|
- Removed possibility of skills getting mixed with attributes
- Made the server sending the level of the current skill on exp change
(currently the client could calculate it itself, but it allows more
flexibillity in future this way)
- Fixed reading of skills out of the database
(for some reason the status effects were added as skills)
** Needs clientside patch as well (coming soon) **
Reviewed-by: Bertram.
|
|
Allows inspection of message data. It is off by default since it consumes
additional bandwidth, but it can be turned on using the net_debugMode option
in manaserv.xml.
Currently the option only affects outgoing data for each host individually.
In particular, enabling this debug mode for the server does not automatically
make the client annotate its messages.
Reviewed-by: Erik Schilling
|
|
List of things fixed:
- fixed having multiple guild support everywhere
- implemented kick code (untested due to missing kick possiblity in client)
- fixed giving owner rights to next member when owner leaves guild
- fixed potentional segmention fault when trying to access deleted guild after all members left
- fixed saving right changes to database
- made searching for guilds faster a bit (at least when having many guilds)
TODO:
+ Fix conflict between guild and normal channels
+ Fix being able to leave guild channel without leaving guild itself
+ Add kick possiblity to client
Reviewed-by: bjorn.
|
|
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
|
|
- Made the current charge being saved.
- Added script binds:
- chr_set_special_recharge_speed
- chr_get_special_recharge_speed
- chr_set_special_mana
- chr_get_special_mana
- get_special_info
- Added special info lua class. Functions:
- name
- needed_mana
- rechargeable
- on_use
- on_recharged
- category
Further the engine no longer sets charge to 0 after using of specials
this allows more flexbilillity (like failing specials).
Changes on the xml database:
- recharge renamed to rechargeable (needed by client and server)
- needed - the needed mana to trigger a special (server only)
- rechargespeed - the defailt recharge speed in mana per tick (server only)
- target - the type of target (either being or point) (server and client)
I also made the lua engine pushing nil instead of a 0 light userdata when
the pointer was 0.
Database update needed.
Change is tested.
Mana-Mantis: #167, #156
Reviewed-by: bjorn.
|
|
Due to a wrong primary key, which covered only the state name, it was
impossible to use the same state name on different maps. This has now
been fixed.
Another problem was that the map variables were being included in the
global variables, because the related database query did not filter on
the map_id column properly. While fixing that, the map_id column now
allows explicitly marking a state variable as global (with the value 0)
or system variables (with the value -1).
System variables are currently not accessible from scripts, but that
could be changed later.
Reviewed-by: Yohann Ferreira
Reviewed-by: Erik Schilling
|
|
When creating an NPC, you now provide its optional talk and update functions
directly rather than them being stored in a table on the Lua side and then
called in response to a global callback.
Also fixed an issue with a missing gender parameter to the delayed NPC
creation callback used by NPCs defined on the map (found by Erik while
reviewing this patch).
Reviewed-by: Erik Schilling
|
|
- Added announcements having senders now.
- Removed /announcement support.
Reviewed-by: Bjorn.
|
|
Reviewed-by: o11c, bjorn, Bertram.
|
|
Changed range of amount to unsigned int(10).
Sqlite update scripts is empty since no change was required here.
Reviewed-by: Bertram.
|
|
|
|
Conflicts:
src/game-server/character.cpp
src/scripting/lua.cpp
|
|
|
|
Reviewed-by: o11c.
|
|
|
|
Also made some random changes where useful, including:
- Code formatting fixes,
- Design fix about the fact that only the game config option
should be checked.
- Fixed the size of the values sent and receive to follow
the rest of the development.
- Fixed variables names to make them show what they are,
and not why they are used.
Resolves: Mana-Mantis #142.
|
|
Conflicts:
src/account-server/storage.cpp
src/game-server/mapreader.cpp
src/sql/mysql/createTables.sql
|
|
It was uneasy to not miss something when updating the db.
And as the db version is somewhat corresponding to a certain
protocol version, adding it in the protocol file sounds relevant
to me, and helps when updating it.
|
|
equipment-fix
Conflicts:
example/serverdata/scripts/maps/desert.lua
|
|
|
|
an arbitrary number of layers. (up to 255).
|