Jump to content

V3ct0r

Administrators
  • Content Count

    2,889
  • Joined

  • Last visited

  • Days Won

    519

Everything posted by V3ct0r

  1. Можешь показать скриншот GroupServer.exe?
  2. Привет, @aleksandr! Добро пожаловать на форум! Данная ошибка говорит о том, что сайт не может подключиться к MSSQL-серверу. Веб-сервер и сервер находятся на одном компьютере? В конфиге сайта нужно ввести адрес MSSQL-сервера, логин и незашифрованный пароль. Т.е. все точно так же как и в .cfg сервера, только пароль шифровать не надо. @paicat212 предлагаю решать проблему на форуме, возможно в будущем у кого-то будет похожая ошибка.
  3. Привет! Скоро выложу гайд по установке сервера. А что конкретно не получается?
  4. MSSQL Server 2014 Express. You can free download it from Microsoft site
  5. How to create an account 1) Open MSSQL Management Studio. Connect to SQL Server and create a new query by pressing 'New Query' button on tool bar or hotkey CTRL + N. 2) Enter the following SQL Query: USE AccountServer; INSERT INTO account_login (name, password) VALUES ('<Login>', '<Password>') Where: <Login> - Login for new account; <Password> - MD5 hash of password for new account in upper case. You can get MD5 hash for passwords using special services: http://www.md5.cz/ http://www.md5online.org/md5-encrypt.html http://onlinemd5.com/ Example: you need to make account 'PKODev' with password '123456', so you have to execute the following SQL Query: USE AccountServer; INSERT INTO account_login (name, password) VALUES ('PKODev', 'E10ADC3949BA59ABBE56E057F20F883E') 3) If you need GM-account, you have to exequte one more SQL Query: USE GameDB; INSERT INTO account (act_id, act_name, gm) VALUES ((SELECT MAX(act_id) + 1 FROM account), '<Login>', <GM-level>); Where: <Login> - Login for new account; <GM-Level> - GM level of the account. Example: USE GameDB; INSERT INTO account (act_id, act_name, gm) VALUES ((SELECT MAX(act_id) + 1 FROM account), 'PKODev', 99); As the result, we have created a new account with GM level 99.
  6. Yes, but only up to 48 items. Check items with IDs 3088 - 3093
  7. V3ct0r

    A nice update

    Looks like this is what you need. Try use it: local has_item = BagTempHasItem(role, item_id, item_number) SystemNotice(role, "has_item = " .. has_item) if (has_item == 0) then SystemNotice(role, "No items in temp bag!") else SystemNotice(role, "Items found!") end
  8. V3ct0r

    A nice update

    Yes. They can use something such as: if (CheckTempBagItem(role, 7294) > 0) then local statelv = 1 local statetime = 3600 AddState(role, role, STATE_BRACELET, statelv, statetime) else local statelv_bracelet = GetChaStateLv(role, STATE_BRACELET) if (statelv_bracelet ~= 0) then RemoveState(role, STATE_BRACELET) end and The problem is that we don't have CheckTempBagItem(role, item_id) function. I will add it in my modified GameServer.exe and release soon.
  9. V3ct0r

    Auto-ban

    Auto-ban Credits: insider The following SQL trigger will ban a player when he enters the game, if there are already banned accounts with the same MAC-address. USE AccountServer GO CREATE TRIGGER auto_ban ON account_login AFTER UPDATE AS BEGIN IF UPDATE(last_login_mac) BEGIN DECLARE @mac varchar(50), @count int SELECT @mac = last_login_mac FROM inserted SELECT @count = COUNT(*) FROM account_login WHERE last_login_mac = @mac AND ban = 1 AND last_login_mac <> '00-00-00-00-00-00-00-00' AND last_login_mac <> '' IF @count <> 0 BEGIN ROLLBACK UPDATE account_login SET ban = 1 WHERE last_login_mac = @mac AND ban = 0 END END END How to install: Open MSSQL Management studio and press button 'New Query' on tool bar or CTRL + N. Then execute (F5) the SQL Query above:
  10. User groups User group system does operate on our forum. For a better recognition of users in different user groups, users' aliases are colored into a certain color. So far there are only 5 user groups: Administrator; Community; Moderator; Server administrator; Advanced user; User. User To enter this group you should simply register on our forum and follow the rules. There are restrictions for the "User" group: 1) You cannot send private messages; 2) You can not write posts in the profile (status updates); 3) You cannot edit posts; 4) You cannot attach attachments. 5) Only 10 reactions per day can be given. Advanced user This group has no restrictions of the "User" group. To get into the "Advanced user" group, you must fulfill two conditions: 1) At least 10 days must pass from the moment of registration on the forum; 2) The user must have at least 10 posts. Server administrator This group is intended for private servers' administrators. Applications to enter the group should be sent to any of the forum administration. Requirements to enter the group: 1) Amount of messages on forum should be 50 and above; 2) Reputation equals 10 and above; 3) User should exist at least 15 days after the registration on forum; 4) A running server; 5) Administration's approval. Moderator Group users have access to the Moderation section. Applications to enter the group should be sent to any administrator. Administrator decides whether to accept the application or not; determines himself what reception form to use. Administrator is free to accept or to deny the application. Administrator has the right to beforehand discuss the application with other team members of group "Moderators". Requirements to enter the group: 1) User should exist at least 30 days after the registration on forum; 2) Reputation equals 15 and above; 3) The absence of forum's rules violation; 4) Administration's approval. Community This group is intended for users who have made a great contribution to the development of the forum or somehow affect the development of the community. Administrators decide on their own who they should and should not add to this group. Administrator No comments.
  11. Hello @xtc! My main programming languages are C/C++ and Assembler. I find that these languages are the most universal. You can write anything from operating systems and drivers to servers and games. Also I am electronics engineer, so I need these languages to program microcontrollers. I know LUA because it is scripting language for Tales of Pirates server and I am learning Java, since sometimes I need to write apps for Android. I am totally agree with you! Not enough to know syntax of language, it is necessary to know standard libraries, API, frameworks and etc.
  12. V3ct0r

    A nice update

    As said @xtc, these items (7294 to 7329) use function ItemUse_Bracelet() from ItemEffect.lua.
  13. V3ct0r

    Server Ip

    What version of client and server do you use? 1) Check GateServer.cfg: [ToClient] IP = 0.0.0.0 Port = 1973 2) Then check your client. Make sure that port in Game.exe also equals to 1973. If you connect from local machine you should enter ip 127.0.0.1 in IP Changer.
  14. V3ct0r

    Server rates

    Thank you, @xtc! I will append your addition to the guide
  15. What programming languages do you know or learn? Write here!
  16. Hello friends! If you have any suggestions or ideas regarding the forum and its processes, then you can submit them here, so we could discuss them. Thank you!
  17. Client .txt tables compiling 1) Make compile.bat batch file in client root folder: start system\game.exe startgame table_bin 2) Put .txt tables in table folder (Client\scripts\table); 3) Run compile.bat. You might notice many errors incoming, that's because you haven't placed some .txt files into table folder. Just ignore the errors. 4) If .txt files have no errors and they are correct, then new .bin files will appear in your table folder.
  18. V3ct0r

    A nice update

    ok, send it when you will at home
  19. V3ct0r

    A nice update

    Can you upload iteminfo.bin?
  20. V3ct0r

    Server rates

    Thank you, @Lucky! I've updated the thread.
  21. V3ct0r

    Server rates

    Server rates In this guide I will tell you how to change server rates. To change rates open file variable.lua (Server\resource\script\calculate\) and find variables: EXP_RAID = 1 -- Experience rate MF_RAID = 1 -- Drop rate RESOURCE_RAID_ADJUST = 1 -- Resource drop rate TEAMEXP_RAID = 1 -- Party experience rate ELEEXP_GETRAD = 1 -- Fairy growth rate In that case all rates are equal to x 1 How to add rate for Ships: 1) Add in variable.lua (see above) new variable SHIP_RAID. It will store rate for ship experience: SHIP_RAID = 1 -- Ship experience rate Ship rate is equal to x 1 in that case 2) Open file exp_and_level.lua (Server\resource\script\calculate\) and find function GetExp_PKM(dead, atk). Look below for local ship_expadd = math.floor( math.min(7, (dead_lv / 10 + 2) ) ) and replace it with local ship_expadd = math.floor( math.min(7, (dead_lv / 10 + 2) ) * SHIP_RAID) Then save changes. Now you can specify rate for ship experience. How to make auto rates: You could make rates update automatically depending on your conditions. For example depending on a day time or week day. Let's make so that rates would increase by x 2 every weekends. 1) Experience and ship experience (EXP_RAID and SHIP_RAID). Open file exp_and_level.lua (Server\resource\script\calculate\) and find function GetExp_PKM(dead, atk). At the beginning of the function add the following code: function GetExp_PKM(dead, atk) local day_of_week = GetNowWeek() if day_of_week == 6 or day_of_week == 0 then -- At weekends rates are equal to x 2 EXP_RAID = 2 SHIP_RAID = 2 else -- At weekdays rates are equal to x 1 EXP_RAID = 1 SHIP_RAID = 1 end -- original code ..... end 2) Team experience (TEAMEXP_RAID). In the file exp_and_level.lua (see above) find function ShareTeamExp(dead, team_atker, dead_exp, The_Killer). At the beginning of the function add the following code: function ShareTeamExp(dead, team_atker, dead_exp, The_Killer) local day_of_week = GetNowWeek() if day_of_week == 6 or day_of_week == 0 then -- At weekends rates are equal to x 2 TEAMEXP_RAID = 2 else -- At weekdays rates are equal to x 1 TEAMEXP_RAID = 1 end -- original code ..... end 3) Drop rate (MF_RAID). Open file skilleffect.lua (Server\resource\script\calculate\) and find function Check_Baoliao(ATKER, DEFER, ... ). At the beginning of the function add the following code: function Check_Baoliao(ATKER, DEFER, ... ) local day_of_week = GetNowWeek() if day_of_week == 6 or day_of_week == 0 then -- At weekends rates are equal to x 2 MF_RAID = 2 else -- At weekdays rates are equal to x 1 MF_RAID = 1 end -- original code ..... end 4) Resource drop rate (RESOURCE_RAID_ADJUST). In the file skilleffect.lua find function Check_SpawnResource(ATKER, DEFER, lv_skill, diaoliao_count, ...). At the beginning of the function add the following code: function Check_SpawnResource(ATKER, DEFER, lv_skill, diaoliao_count, ...) local day_of_week = GetNowWeek() if day_of_week == 6 or day_of_week == 0 then -- At weekends rates are equal to x 2 RESOURCE_RAID_ADJUST = 2 else -- At weekdays rates are equal to x 1 RESOURCE_RAID_ADJUST = 1 end -- original code ..... end 5) Fairy growth rate (ELEEXP_GETRAD). Open file functions.lua (Server\resource\script\calculate\) and find function Give_ElfEXP(role, Item, Type, Num). At the beginning of the function add the following code: function Give_ElfEXP(role, Item, Type, Num) local day_of_week = GetNowWeek() if day_of_week == 6 or day_of_week == 0 then -- At weekends rates are equal to x 2 ELEEXP_GETRAD = 2 else -- At weekdays rates are equal to x 1 ELEEXP_GETRAD = 1 end -- original code ..... end That's all! If you have any questions you can ask them here.
  22. @Sultan also asked me how to increase temporary bag capacity for existing characters. Close all GameServers. Open MSSQL Management studio and press button 'New Query' on tool bar or CTRL + N. Then execute (F5) following SQL Query: USE GameDB; UPDATE Resource SET content = REPLACE(content, '16', '32') WHERE type_id = 3; Where 32 is the new size of temporary bag. Don't forget to make backup!
  23. For all inventories (Character inventory, temporary bag and bank) there is limit in GameServer.exe for 48 items maximum. I will try to increase it.
  24. Good job, Sultan! Does sqlcmd.exe display the query output on the GameServer.exe console? Add 1>NUL 2>NUL to end of sqlcmd.exe parameters list to disable the query output. It may increase speed: sqlcmd.exe -S <MSSQL Address> -U <User> -P <Password> -Q <Query> 1>NUL 2>NUL
×
×
  • Create New...