Fix#2319
This should resolve the issue of users getting the popup immediately when logging in and the time out value is set to 0.
This needs tested, its a quick fix put in with the web editor.
* Fix Store Replays Functionality
For whatever reason we have a variable in the servers ini to
enable/disable the storing of replays but there is no code that uses
that variable. At one time there was but in light of it being removed
some were along the line this add's the ability back in for server
owners to disable the storing of game replay data.
* Added code
* Moved store replay check
Moved the check for storing replay information into existing routine.
* Updated Per Request
Combined lines per request
Fix#2285
This change adds an internal counter for each tcp/web socket connection
that the server makes and queries the stored memory count at login
rather than the previous way that quired the database during each login.
Each login that quired the DB put a significant load on the server as
the user base grew.
* Add enable/disable log query functionality
This change adds the ability for server owners to allow log querying
from inside the client. In the event the functionality is not allowed a
result is returned indicating the functionality is disabled.
* Added translation
Added the ability for the disabled messages to be translated.
* Server side idle timeout
Initial commit for server side idle timeout counter. This adds a new
int value that is updated when room/game/mod/admin commands occur and is
checked during the regular ping timout function that if the users new
"idle" value exceeds the idleclienttimeout value defined in the servers
configuration file the user is logged out. The user will receive a
warning at the 90% time frame mark about being idle.
* Use round instead of ceil
Travis fix for older xcode issue's.
* Fixed requested items
Mis-spelleed function, added header, added warning message sent check
value. Also corrected the protobuf declaration file for
event_notifyuser
* Moved bool to protected
* Re-Ordered Declarations
* Removed most stylistic items
Resolved most noted things.
* Remove client side idle timeout
Removed client side idle timeout functionality
* Created first round of helper functions
Started to go through server init function and move statically defined
variables that the server uses into helper functions to allow for
dynamic changing while the server is up rather than requiring a restart.
* Completed Helper Function Creation
Completed adding all the helper functions along with updated the virtual
server function calls and renamed helper functions to match settings
cached ini value names for clarity.
* Comment Cleanup
Removed lines commented out throughout previous changes as well as
cleaned up variable declarations that are no longer needed with helper
functions that query the settingsCache
* Added featureset dynamic refreshing
Added slots/functions/calls for updating the required feature sets
dynamically.
* Created first round of helper functions
Started to go through server init function and move statically defined
variables that the server uses into helper functions to allow for
dynamic changing while the server is up rather than requiring a restart.
* Update log path example when running under windows
Added example of log path syntax when running servatrice under windows.
* Missed example bra cket
* Added user privilege level
Added a enum column in the users table named "privilevel" with the
current values of "none", "vip", and "donator". Also allowed anyone
with a higher privilege level than "none" to log in even if the server
is set to limit the user total and the user limit is reached. This
change add's the new user information into the users container that gets
populated and passed between client and server.
* Added user privilege level
Added a enum column in the users table named "privilevel" with the
current values of "none", "vip", and "donator". Also allowed anyone
with a higher privilege level than "none" to log in even if the server
is set to limit the user total and the user limit is reached. This
change add's the new user information into the users container that gets
populated and passed between client and server.
* don't use corrected name when downloading card (#2164)
* Fix dynamic user limit settings
PR #2220 removed the ability to be able to change the max user limit
count while the server is running requiring a restart to make the
settings change. This PR reverts the behavior back to how it operated
prior to the PR.
* Call class functions for consistency
Updated code to call functions for consistency.
* don't use corrected name when downloading card (#2164)
* Added user privilege level
Added a enum column in the users table named "privilevel" with the
current values of "none", "vip", and "donator". Also allowed anyone
with a higher privilege level than "none" to log in even if the server
is set to limit the user total and the user limit is reached. This
change add's the new user information into the users container that gets
populated and passed between client and server.
* Corrected Typo
Corrected typo in DB Migration Script
* Git fuckup?
* Added word column
Added the word column to migration script for backwards compatibility
PR #2220 removed the ability to be able to change the max user limit
count while the server is running requiring a restart to make the
settings change. This PR reverts the behavior back to how it operated
prior to the PR.
This change accomplishes two goals. The first is it moves the checking
for if the servers set user limit is reached out of the socket interface
and into the protocol handler portion of the code (were it should live).
It also eleminates the need for a DB query at login to check the user
count. The user account is actually already maintained by the server
and a function already existed to get the user count total.
Added the functionality client side to log users out of servers if they
are idle for more than 1 hour without joining either a game or room.
Sending a message (room/game/private) or performing a game action.
* main.cpp: removed path checking and db loading
* card database: merge card loading methods into a single one
* settings cache: take care of returning safe paths for decks,
replays, etc..
* main window: if db loading fails (eg. first run), propose to run
oracle
NSIS: propose to run cockatrice instead of oracle
Rework card database loading
* Move carddatabase-related method out of deckeditor tab
* Load cards in another thread and render them progressively
* Optimize database reload after enabled sets change
Fix deck editor column width
* removed the noCard hack.
* getCard() no more creates cards instead of just returning existing
ones
* Fix the “edit tokens” dialog.
* PictureLoader: avoid trying to download twice the same card
* PictureLoader: correct return of card background
* AbstractCardItem: avoid recalculating card color at every paint
Use a different file to save custom tokens
Misc required improvements
* Use nullptr;
* Refactor CardInfoWidget to use CardInfoPicture and CardInfoText
instead of duplicating code;
* Added CardInfo::getColorChar()
* Fixed some potential crashes
* removed dead code related to CardInfoWidget
* Don't require a restart after adding a new custom sets file
* Bump CMake requirements to 3.1
That marker is only recognized by pb3-compatible compilers, meaning that
tools which are otherwise compatible with our files break on them.
Notably, this includes hprotoc (for haskell).
With this update a new chat history definition is added on a per
room bases which allows operators to specify the number of chat
messages to store and present to the user on join. Please see
the sample ini for room definitions.
When in none auth mode, registered users don't exist; hence the setting
makes the game impossible to join.
Normally the setting would be greyed out when the user is unregistered,
but commit 475c54bf introduced a new edge case where the stored setting
would apply to the field even if the user is unregistered, making the
setting possible to apply in no-reg mode. Regardless, any client could
have done this, not just the default cockatrice.
The server side fix should prevent all issues in the future.
Changed the default value for the client keep alive variable back to 1 (since that is what the setting is if the value is not found in the configuration ini file).
Stub for registration command handling in server
First draft of handling registration requests
WIP (will be rebased)
clean up bad imports (rebase this later)
Finish checkUserIsBanned method
Add username validity check
Check servatrice registration settings
WIP
Finish(?) server side of registration
Needs testing
Fix switch case compile failure
I have no idea why I have to do this
WIP for registration testing python script
Stub register script initial attempt
Rearrange register script
First try at sending reg
register.py sends commands correctly now
Add more debug to register.py
Pack bytes the right way - servatrice can parse py script sends now
register.py should be working now
Parse xml hack correctly
Log registration enabled settings on server start
Insert gender correctly on register
Show tcpserver error message on failed gameserver listen
Fail startup if db configured and can't be opened.
TIL qt5 comes without mysql by default in homebrew...
Previously if you were to reveal the top card, then look at the top x (x
> 1) cards, then move them to another zone, the top card would stop
being revealed.
The issue was that when moving the cards the first card was being
revealed, then being moved.
I have also fixed an issue too:
+ reveal top card
+ scry 4
+ grab all cards and move to the first column of available space at the
left most of the screen (column 0). Everything is fine.
+ now try with another column (> 0), you will see that the card order
has flipped.
This no longer happens.
This needs some testing before being merged. I will run the build for a
while, right now it feels good though.
Will need @ctrlaltca to confirm this wont mess anything up. I have
removed a option to se set from the cmake file. This option is not
needed.
Windows users, you will need to run cmake to create the sln again.
The issue was that I had set the ctor to set the p/t to 0/0 rather than
-1/-1. This meant that when you join a game in progress (spec or
reconnect) the server would send the card value to the client as 0/0,
instead of -1/-1. The client has been coded so that if the toughness is
<0 then dont show it. 0/0 is instead shown.
We still need to look into cards with no p/t being set to a 0/1 as
@tooomm mentioned in anther issue. As it stands, this is more important
than that.