52 Commits

Author SHA1 Message Date
slawkens
4a6896b446 getPremDays: returns -1 if freePremium 2025-03-15 22:48:59 +01:00
slawkens
464492d826 Update OTS_Account.php 2025-02-26 16:16:45 +01:00
slawkens
ada1e391d4 Add option to restrict Page view to logged user
$logged_access = 0 -> not logged in
$logged_access = 1 -> logged in
2023-11-11 12:52:26 +01:00
slawkens
24ff5684cd More changes to deleted characters (Account, guilds)
Account: Cannot change name, comment, gender
+ Cannot be deleted if owns a guild
Guilds: Cannot create, cannot be invited, cannot accept invite, cannot be passed leadership to
2023-06-30 17:27:31 +02:00
SRNT-GG
76bfab1303 WIP - Removing unneccessary closing tags to prevent potential issues. (#223)
* Part 1

Removing closing tags when no HTML or other output comes after the last PHP codeblock.

* Further removals

* nothing

---------

Co-authored-by: slawkens <slawkens@gmail.com>
2023-06-15 21:06:22 +02:00
slawkens
6625768228 Remove accounts.blocked 2023-02-18 07:14:51 +01:00
slawkens
8985917a96 Fixes to account number 2023-02-14 18:28:31 +01:00
slawkens
8c801dddec PHP 8.1 compatibility 2023-02-02 16:16:06 +01:00
slawkens
77460b0832 Revert "Fix compatibility with PHP 8.1"
This reverts commit 1d1e927d56302e6d21cb51203eee7ad43b89b38d.
2023-02-02 15:39:20 +01:00
slawkens
1d1e927d56 Fix compatibility with PHP 8.1 2023-02-02 11:17:48 +01:00
slawkens
0abb9384a6 Fix: create account by email
Now you can at least create an account if account_login_by_email is enabled :)
2022-05-31 15:09:48 +02:00
slawkens
6d19d69d20 Fix some undefined notice 2021-07-05 17:15:48 +02:00
slawkens
eb091e487d Support for downgraded TFS 7.72 (with accounts.number)
Part one
2021-06-09 01:54:05 +02:00
czbadaro
ea035136e1 Gratis premium account (#156)
* skip premdays and lastdays calculation when premdays = 65535 (gratis premium in TFS)

* TFS consider 65535 as gratis premium account and PHP_INT_MAX does not assume this value

* adds condition of premdays=65535 and standardize the label "gratis premium account" with tibia client

* adjust the label "days" when there is only one day of premium account

* adjusted premium account status

* Some small adjustment

* Sorry, typo.

Co-authored-by: slawkens <slawkens@gmail.com>

(cherry picked from commit 9d7854dda62468e420c26a6e531bacf47351f499)
2021-04-23 01:14:32 +02:00
slawkens
6b07d56627 Fix setPremDays for latest TFS
Fixes editing account in admin panel
2021-02-15 21:05:08 +01:00
slawkens
15d381adfd Fixed account getPremDays() function for latest TFS
This fixes account management + signature
2021-02-15 20:57:24 +01:00
slawkens
855e9aa3b9 Fix: do not count deleted characters
On create new character page
2021-01-20 19:46:07 +01:00
slawkens
a8a36c73e6 Fix notice about premend 2020-12-30 00:27:42 +01:00
slawkens
1ada2317fd Add support for accounts.premium_ends_at (Latest tfs 1.x) 2020-12-30 00:10:49 +01:00
slawkens
7b75a61cdb Support for Nostalrius
https://github.com/TwistedScorpio/Nostalrius
2020-02-27 22:18:39 +01:00
slawkens
2dbf189f43 Use $db->exec where appropriate
May bring some performance boost (little, but still)
2020-02-15 03:15:53 +01:00
slawkens
259cda150d Fix some 7.4 notices about OTS_Account bans
Example: Notice: Trying to access array offset on value of type bool in C:\UniServerZ\www\system\libs\pot\OTS_Account.php on line 784
2020-02-10 23:51:15 +01:00
Tornadia
9f31f90146 Fixing some errors at the install endscreen (#75)
* Fixed some bugs at last install screen (unset country and HTTPS protocol definition)

* Correction: allow_url_fopen is not to make any distinction between HTTP/HTTPS

* Black skull bug when joining serverInfo

* * latin is good but utf8 is better

* also changed ENGINE to InnoDB

* * use curl as alternative option for reporting install

* * you forgot this

* * fix typo

* Revert "* fix typo"

This reverts commit 6f24509dd659032c65c3ccbdf5b5bb3b25cffd72.

* * fix typo

* * this is the correct way to hide that notice
2019-04-19 22:28:38 +02:00
slawkens
559d13dfd9 * fix OTS_Account->setPremDays for OTHire 2019-04-13 04:48:06 +02:00
slawkens
6ccaf316ab * fix saving of account country in player editor 2019-04-13 04:45:48 +02:00
Lee
1859867039 Bug Fixes
-fix for getSkillTries as reported by whiteblXK
-fix for login and account type as reported by vG-
2018-12-30 01:00:26 +00:00
Lee
2667d2b41c Updates + Fixes (#66)
* Updates

+added account editor country list
+added account editor website access flag editor.
+added player blessing1-8 editor
+added fav icon
+added $account->setLastLogin
+added $player->checkBlessings (for blessings 1-8)
+bug fixes

* Blessing Fix

Should now detect the amount of blessings if blessings1 onwards exists.
2018-12-26 11:32:58 +01:00
Lee
6dab50cbd8 Admin Panel (#61)
Thank you Lee for this awesome, Bootstrap Admin Panel!
2018-11-22 07:12:14 +01:00
slawkens1
16bcb70863 * new hooks: LOGIN, LOGIN_ATTEMPT, LOGOUT
* fixed bug with uninstalling some plugin dirs
* updated TODO
2018-01-14 08:59:37 +01:00
slawkens1
f9de0b5eb9 * fixed displaying Premium Account days v2 2018-01-08 00:17:49 +01:00
slawkens1
85083f5979 * fixed displaying premium account days
* function OTS_Account:getPremDays will now return -1 if there's
freePremium configurable enabled on the server
2018-01-08 00:08:17 +01:00
slawkens1
1025fad0e6 * cache $db->hasTable and $db->hasColumn functions
* changed tableExist and fieldExist to $db->hasTable(table) +
$db->hasColumn(table, column)
* new configurable: database_log - can log database queries and show in
website source when logged as super admin
* removed debug_level configurable, enabled by default when logged on
super admin
* added OTS_Account:getCountry()
* added posibility to load OTS_Player partially, and without skills
* (internal) changed depracated $ots->createObject() functions with
their OTS_ equivalents
* (internal) removed unused code
2018-01-06 05:44:33 +01:00
slawkens
2e4321872a * fixed othire account creating/installation
* fixed unexpected error logging about email fail
* added max_execution_time to the install finish step
2018-01-05 09:30:27 +01:00
slawkens1
3e49ef42a2 * fiedx bug on othire with config.account_premium_days
* fixed getPremDays and isPremium functions (newest 11.x engines are
bugged when it comes to PACC, its not fault of MyAAC)
2018-01-03 21:03:05 +01:00
slawkens1
5266f33af5 * reverted getLastLogin cause it was used by tibia11-login plugin 2017-10-20 22:01:05 +02:00
slawkens1
5951fe21ec * fixed creating account :(
* fixed showing premium account status
2017-10-20 21:15:46 +02:00
slawkens1
c6b6638705 * fixed viewing thread without being logged
* removed unused and wrong function OTS_Account::getLastLogin() (field
lastday is used for premium)
2017-10-20 20:29:10 +02:00
slawkens1
abfe3b08af * Account::getAccess = Account::getGroupId() 2017-10-17 03:36:37 +02:00
slawkens
d95aea319e * fixed forum new post on mac os and some specific mysql versions
* fixed Account::getGuildAccess function
2017-10-13 15:30:29 +02:00
slawkens
0a82f306f6 * moved admin pages to twig
* edited account.management.html.twig to fit modern templates, tibiacom have its own template
* sample characters are now assigned to admin account and have group_id 4 to not be shown on highscores
* fixed database pages loading
* added require.database plugin option, which will prove if DATABASE_VERSION is enough
2017-10-10 15:32:59 +02:00
slawkens1
c8c1ba5682 * fixed recovering account and changing password when salt is enabled
* added 'enabled' field in myaac_hooks table, which can enable or
disable specified hook
* password change minimal/maximal length is now more precise
2017-08-25 00:10:53 +02:00
slawkens
45f988c420 *some fixes
* fixed installing samples when for example Rook Sample already exist and other samples not
* fixed some mysql error when character you trying to create already exist
* fixed signature fonts finding path
* removed DEFAULT '' for TEXT field. It didn't worked under some systems like MAC OS X.
* moved news adding at installation from schema.sql to finish.php
* removed some unused cities field from myaac_spells table
* some optimizations
2017-08-23 17:00:41 +02:00
slawkens1
1310a49729 some small update
* moved site_closed to database, now you can close your site through
admin panel
* added option to admin panel: clear cache
* added experiencetable_rows configurable
* optimized OTS_Account->getGroupId(), now its using like 20 queries
less
* optimized OTS_Player->load($id) function, should perform faster
loading
* fixed highscores displaying of group outfits
2017-05-19 02:30:39 +02:00
slawkens1
7b23ffaf23 update to 0.1.5
fixed bug with "Integrity constraint violation: 1048 Column 'ip' cannot
be null"
2017-05-13 22:43:14 +02:00
slawkens1
449ce31ab4 some fixed and new features
* added outfit shower, in characters, online, and highscores
* updated database to version 2
* fixed item images (now using item-images.ots.me host by default)
* fixed news ticket and posting long newses
(https://otland.net/threads/myaac-v0-0-1.251454/page-5#post-2442026)
* news body limit increased to 65535 (mysql text field)
* removed some unused code from my old server
* added spells & monsters to kathrine template
2017-05-13 19:16:03 +02:00
slawkens1
a177c93e97 Some big update
* added option to change character name in accountmanagement
* added automatic database updater (data migrations)
* renamed events to hooks
* moved hooks to database
* now you can use hooks in plugins
* set account.type field to 5, if TFS 1.0+
* added example plugin
* new, latest google analytics code
* fixed bug with loading account.name that has numbers in it
* fixed many bugs in player editor in admin panel
* added error handling to plugin manager and some more verification in
file has been correctly unpacked/uploaded
* fixed Statistics page in admin panel when using account.number
* fixed bug when creating/recovering account on servers with
account.salt field (TFS 0.3 for example)
* fixed forum showing thread with html tags (added from news manager)
* new, actual code for youtube videos in movies
* fixed showing vocation images when using
$config['online_vocations_images']
* many fixes in polls (also importing proper schema)
* fixed hovering on buttons in kathrine template (on accountmanagement
page)
* many fixes in signatures
* added missing gesior signature system
2017-05-11 04:13:16 +02:00
slawkens1
4465da67e9 Fixes
* fixed support for TFS 0.2 series
* added FAQ link
2017-05-05 19:55:25 +02:00
slawkens1
a93bd4a0fc Fixed some warning in PHP 7.1
Warning: Cannot assign an empty string to a string offset
* fixed Notice with tempnam()
2017-05-04 18:32:34 +02:00
slawkens1
6e7a82b425 Fixed https://otland.net/threads/myaac-v0-0-1.251454/#post-2440110 2017-05-03 23:55:17 +02:00
slawkens1
08fce2ade4 * Fixed
* full support for OTHire 0.0.3
* added support for otservers that doesn't use account.name field,
instead just account number will be used
* (install) moved admin account creation to new step
* fixed encryption detection on 0.3
* fixed bug when server_config table doesn't exist
* other fixes
2017-05-03 23:48:04 +02:00