Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Initial implementation of Map Zones #8100

Open
wants to merge 54 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 3 commits
Commits
Show all changes
54 commits
Select commit Hold shift + click to select a range
39f6e14
Initial implementation of Map Zones
aleos89 Jan 12, 2024
e60e3e8
Fixes CI errors
aleos89 Jan 12, 2024
004dcf5
More battle_config cleanups
aleos89 Jan 12, 2024
82e362e
Fixes PK damage calculation
aleos89 Jan 12, 2024
997e457
Update messages for other languages
aleos89 Jan 12, 2024
c186c03
Fix Russian specifier to integer
aleos89 Jan 12, 2024
5c24cc4
Disable mapflags on custom scripts
aleos89 Jan 12, 2024
7717070
Translate new messages to Spanish
aleos89 Jan 13, 2024
1e4a219
Implements mapflag MF_FLEE_PENALTY
aleos89 Jan 14, 2024
6568ccf
Cleanup atcommand mapinfo
aleos89 Jan 14, 2024
e405a39
Fixes incorrect message display
aleos89 Jan 14, 2024
53b2a0c
Remove deprecated databases from file move
aleos89 Jan 14, 2024
08068bf
Remove plurality
aleos89 Jan 14, 2024
31cc8c5
Adds a function to assist with PK damage
aleos89 Jan 14, 2024
e3eefb6
Fixes invincible timer check
aleos89 Jan 14, 2024
34065e4
Map Zone parsing optimizations
aleos89 Jan 16, 2024
772c6f3
Invincible timer clean
aleos89 Jan 16, 2024
e9beffe
Adds object type check to isStatusDisabled
aleos89 Jan 16, 2024
941085e
Adds ability to clear mapflags
aleos89 Jan 17, 2024
c178f03
Convert s_map_zone_data storage to shared_ptr
aleos89 Jan 17, 2024
e34973a
Fixes mapflag parsing
aleos89 Jan 17, 2024
4a48b64
Fixes MF_FLEE_PENALTY parsing
aleos89 Jan 17, 2024
10e28ba
Add empty zone notice
aleos89 Jan 17, 2024
cbe0d8f
Adds translation for Portuguese
aleos89 Jan 17, 2024
d3ea299
Remove unused battle configs
aleos89 Jan 17, 2024
fc3cc3c
Fixes atcommands for PvP and GvG toggle
aleos89 Jan 18, 2024
f56c45c
Revert PvP/GvG atcommands
aleos89 Jan 23, 2024
fc7a553
Maps in order
Atemo Feb 9, 2024
9973a89
Corrected the zone of few maps
Atemo Feb 9, 2024
1e4c6ff
Merge branch 'master' into feature/map_zones
aleos89 Apr 16, 2024
b43cd4c
Merge branch 'master' into feature/map_zones
aleos89 May 3, 2024
61b7f33
Resolve compile errors and warnings
aleos89 May 3, 2024
849f1ec
Merge branch 'master' into feature/map_zones
aleos89 May 3, 2024
060629b
Adjust structs to classes
aleos89 May 3, 2024
074fdfb
Refactor a few functions to use sd lookup
aleos89 May 3, 2024
477c845
Clean ups from review
aleos89 May 7, 2024
92b6879
Fixes a compile error
aleos89 May 7, 2024
6ffcedc
Merge branch 'master' into feature/map_zones
aleos89 May 7, 2024
c62395f
Cleanups and optimizations
aleos89 May 7, 2024
2553658
Merge branch 'master' into feature/map_zones
aleos89 May 31, 2024
f0a1847
Merge branch 'master' into feature/map_zones
aleos89 Jun 21, 2024
73ea1ac
Resolve map-server-generator post build tasks
aleos89 Jun 21, 2024
394d502
Adjust getMapZone
aleos89 Jun 26, 2024
e648d02
Fixed alphabetical order and remove some renewal maps from pre-e
Daegaladh Jun 29, 2024
142505f
Merge branch 'master' into feature/map_zones
aleos89 Aug 1, 2024
8ac2975
Resolve a merge error
aleos89 Aug 1, 2024
14aa844
Adjust pre-re map zones
aleos89 Aug 16, 2024
06c595c
Minor message cleanups
aleos89 Aug 16, 2024
a9d3ebd
Fixed pre-re maps
Daegaladh Aug 19, 2024
eacd54b
Add missing atcommand reference
aleos89 Sep 6, 2024
69df753
Add back player_invincible_time battle config
aleos89 Sep 9, 2024
3a0b3cc
Merge branch 'master' into feature/map_zones
aleos89 Sep 20, 2024
a01b87a
Adjust map ID lookup to be primary
aleos89 Sep 20, 2024
857d6e3
Add some renewal maps to zones
aleos89 Sep 20, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 0 additions & 15 deletions conf/battle/battleground.conf
Original file line number Diff line number Diff line change
Expand Up @@ -9,21 +9,6 @@
// assume unit types (1: Pc, 2: Mob, 4: Pet, 8: Homun, 16: Mercenary, 128: NPC, 512: Elemental)
//--------------------------------------------------------------

// Melee damage adjustments (non skills) for Battleground maps (Note 2)
bg_short_attack_damage_rate: 80

// Ranged damage adjustments (non skills) for Battleground maps (Note 2)
bg_long_attack_damage_rate: 80

// Weapon skills damage adjustments for Battleground maps (Note 2)
bg_weapon_attack_damage_rate: 60

// Magic skills damage adjustments for Battleground maps (Note 2)
bg_magic_attack_damage_rate: 60

// Misc skills damage adjustments for Battleground maps (Note 2)
bg_misc_attack_damage_rate: 60

// Flee penalty on BG grounds.
// NOTE: It's %, not absolute, so 20 is -20% of your total flee
bg_flee_penalty: 20
aleos89 marked this conversation as resolved.
Show resolved Hide resolved
Expand Down
15 changes: 0 additions & 15 deletions conf/battle/guild.conf
Original file line number Diff line number Diff line change
Expand Up @@ -27,21 +27,6 @@ guild_max_castles: 0
// Note: This was changed in renewal in favor of individual skill cooldown.
guild_skill_relog_delay: 300000

// Melee damage adjustments (non skills) for WoE battles (Guild Vs Guild) (Note 2)
gvg_short_attack_damage_rate: 80

// Ranged damage adjustments (non skills) for WoE battles (Guild Vs Guild) (Note 2)
gvg_long_attack_damage_rate: 80

// Weapon skills damage adjustments for WoE battles (Guild Vs Guild) (Note 2)
gvg_weapon_attack_damage_rate: 60

// Magic skills damage adjustments for WoE battles (Guild Vs Guild) (Note 2)
gvg_magic_attack_damage_rate: 60

// Misc skills damage adjustments for WoE battles (Guild Vs Guild) (Note 2)
gvg_misc_attack_damage_rate: 60

// Flee penalty on gvg grounds. Official value is 20 (Note 2)
// NOTE: It's %, not absolute, so 20 is -20% of your total flee
gvg_flee_penalty: 20
aleos89 marked this conversation as resolved.
Show resolved Hide resolved
Expand Down
8 changes: 0 additions & 8 deletions conf/battle/misc.conf
Original file line number Diff line number Diff line change
Expand Up @@ -39,14 +39,6 @@ pk_min_level: 55
// players to let them attack each other. 0 disables said limit.
pk_level_range: 0

// For PK servers. Damage adjustment settings, these follow the same logic
// as their WoE counterparts (see guild.conf)
pk_short_attack_damage_rate: 80
pk_long_attack_damage_rate: 70
pk_weapon_attack_damage_rate: 60
pk_magic_attack_damage_rate: 60
pk_misc_attack_damage_rate: 60

// Display skill usage in console? (for debug only) (default: off) (Note 3)
skill_log: off

Expand Down
5 changes: 0 additions & 5 deletions conf/battle/player.conf
Original file line number Diff line number Diff line change
Expand Up @@ -46,11 +46,6 @@ quest_skill_reset: no
// You must have basic skills to be able to sit, trade, form a party or create a chatroom? (Note 1)
basic_skill_check: yes

// When teleporting, or spawning to a map, how long before a monster sees you if you don't move? (time is in milliseconds)
// That is, when you go to a map and don't move, how long before the monsters will notice you.
// If you attack a monster, it will attack you back regardless of this setting.
player_invincible_time: 5000

// The time interval for HP to restore naturally. (in milliseconds)
natural_healhp_interval: 6000

Expand Down
10 changes: 7 additions & 3 deletions conf/msg_conf/map_msg.conf
Original file line number Diff line number Diff line change
Expand Up @@ -933,7 +933,11 @@
// NoBank Mapflag
831: You cannot use the Bank on this map.

//832-899 free
// Map Zones
832: This command is disabled on this map.
833: Map Zone database has been reloaded.

//834-899 free
aleos89 marked this conversation as resolved.
Show resolved Hide resolved

//------------------------------------
// More atcommands message
Expand Down Expand Up @@ -1124,9 +1128,9 @@
// @mapinfo
1038: Please enter at least one valid list number (usage: @mapinfo <0-3> <map>).
1039: ------ Map Info ------
1040: Map: %s | Players: %d | NPCs: %d | Chats: %d | Vendings: %d
1040: Map: %s (Zone: %s) | Players: %d | NPCs: %d | Chats: %d | Vendings: %d
1041: ------ Map Flags ------
1042: Town Map
1042: Damage Rate Adjustments:
1043: Autotrade Enabled
1044: Autotrade Disabled
1045: Battlegrounds ON (type %d)
Expand Down
4 changes: 2 additions & 2 deletions conf/msg_conf/map_msg_frn.conf
Original file line number Diff line number Diff line change
Expand Up @@ -883,9 +883,9 @@
// @mapinfo
1038: Entrez un numéro de la liste (usage: @mapinfo <0-3> <map>).
1039: ------ Map Info ------
1040: Nom de la Map: %s | Joueurs sur la Map: %d | NPCs sur la Map: %d | Chats sur la Map: %d
1040: Nom de la Map: %s | Joueurs sur la Map: %s | NPCs sur la Map: %d | Chats sur la Map: %d
1041: ------ Map Flags ------
1042: Town Map
//1042: Free
1043: Autotrade Activé
1044: Autotrade Désactivé
1045: Battlegrounds ON (type %d)
Expand Down
4 changes: 2 additions & 2 deletions conf/msg_conf/map_msg_idn.conf
Original file line number Diff line number Diff line change
Expand Up @@ -970,9 +970,9 @@
// @mapinfo
1038: Harap masukkan setidaknya 1 pilihan. (Penggunaan: @mapinfo <0-3> <map>).
1039: ------ Map Info ------
1040: Map: %s | Pemain: %d | NPC: %d | Ruang Chat: %d | Toko: %d
1040: Map: %s | Pemain: %s | NPC: %d | Ruang Chat: %d | Toko: %d
1041: ------ Map Flags ------
1042: Kota
//1042: Free
1043: Autotrade diaktifkan
1044: Autotrade dinonaktifkan
1045: Battleground ON (tipe %d)
Expand Down
4 changes: 2 additions & 2 deletions conf/msg_conf/map_msg_por.conf
Original file line number Diff line number Diff line change
Expand Up @@ -1052,9 +1052,9 @@
// @mapinfo
1038: Digite pelo menos um número válido da lista (uso: @mapinfo <0-3> <mapa>).
1039: ------ Informação do Mapa ------
1040: Mapa: %s | Jogadores: %d | NPCs: %d | Chats: %d | Vendas: %d
1040: Mapa: %s | Jogadores: %s | NPCs: %d | Chats: %d | Vendas: %d
1041: ------ Map Flags ------
1042: Mapa de Cidade
//1042: Free
1043: Autotrade Habilitado
1044: Autotrade Desabilitado
1045: Battlegrounds Habilitado (tipo %d)
Expand Down
4 changes: 2 additions & 2 deletions conf/msg_conf/map_msg_rus.conf
Original file line number Diff line number Diff line change
Expand Up @@ -884,9 +884,9 @@
// @mapinfo
1038: Ââåäèòå õîòÿ áû îäèí íîìåð (Èñïîëüçîâàíèå: @mapinfo <0-3> <ëîêàöèÿ>).
1039: ------ Èíôîðìàöèÿ î ëîêàöèè ------
1040: Íàçâàíèå ëîêàöèè: %s | Èãðîêè: %d | ÍÈÏ: %d | ×àòû: %d
1040: Íàçâàíèå ëîêàöèè: %s | Èãðîêè: %s | ÍÈÏ: %d | ×àòû: %d
1041: ------ Ìàïôëàãè ------
1042: Ñòîëèöà
//1042: Free
1043: Autotrade Ðàçðåø¸í
1044: Autotrade Çàïðåù¸í
1045: Battlegrounds ÂÊËÞ×ÅÍÎ (òèï %d)
Expand Down
4 changes: 2 additions & 2 deletions conf/msg_conf/map_msg_spn.conf
Original file line number Diff line number Diff line change
Expand Up @@ -1124,9 +1124,9 @@
// @mapinfo
1038: Introduce un número de la lista (instrucciones: @mapinfo <0-3> <mapa>).
1039: ------ Información del mapa ------
1040: Mapa: %s | Jugadores: %d | NPCs: %d | Chats: %d | Tiendas: %d
1040: Mapa: %s | Jugadores: %s | NPCs: %d | Chats: %d | Tiendas: %d
1041: ------ Opciones del mapa ------
1042: Mapa de ciudad
//1042: Free
1043: Autotrade activado
1044: Autotrade desactivado
1045: Battleground activado (tipo %d)
Expand Down
4 changes: 2 additions & 2 deletions conf/msg_conf/map_msg_tha.conf
Original file line number Diff line number Diff line change
Expand Up @@ -877,9 +877,9 @@
// @mapinfo
1038: â»Ã´ÃкØàÅ¢ÍÂèҧ˹èÍÂ˹Ö觤èÒ¨Ò¡ÃÒ¡Òà (ÇÔ¸Õãªé: @mapinfo <0-3> <map>).
1039: ------ ÃÒÂÅÐàÍÕ´Ἱ·Õè ------
1040: á¼¹·Õè: %s | ¼ÙéàÅè¹: %d | NPCs: %d | Chats: %d | Vendings: %d
1040: á¼¹·Õè: %s | ¼ÙéàÅè¹: %s | NPCs: %d | Chats: %d | Vendings: %d
1041: ------ Map Flags ------
1042: Town Map
//1042: Free
1043: Autotrade Enabled
aleos89 marked this conversation as resolved.
Show resolved Hide resolved
1044: Autotrade Disabled
1045: Battlegrounds ON (type %d)
Expand Down
30 changes: 0 additions & 30 deletions db/import-tmpl/item_noequip.txt

This file was deleted.

28 changes: 0 additions & 28 deletions db/import-tmpl/job_noenter_map.txt

This file was deleted.

39 changes: 39 additions & 0 deletions db/import-tmpl/map_zones.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# This file is a part of rAthena.
# Copyright(C) 2024 rAthena Development Team
# https://rathena.org - https://github.com/rathena
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http:#www.gnu.org/licenses/>.
#
###########################################################################
# Map Zone Database
###########################################################################
#
# Map Zone Settings
#
###########################################################################
# - Id Zone ID.
# DisabledCommands: List of disabled @commands. (Default: null)
# DisabledSkills: List of disabled skills. (Default: null)
# DisabledItems: List of disabled items. (Default: null)
# DisabledStatuses: List of disabled statuses. (Default: null)
# RestrictedJobs: List of restricted jobs from entering zone. (Default: null)
# Maps: List of maps to apply the zone to.
# Mapflags: List of mapflags. (Default: null)
# - Flag Mapflag name.
# Value Value assigned to mapflag. (Default: true)
###########################################################################

Header:
Type: MAP_ZONES
Version: 1
24 changes: 0 additions & 24 deletions db/import-tmpl/skill_nocast_db.txt

This file was deleted.

25 changes: 0 additions & 25 deletions db/import-tmpl/status_disabled.txt

This file was deleted.

47 changes: 47 additions & 0 deletions db/map_zones.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
# This file is a part of rAthena.
# Copyright(C) 2024 rAthena Development Team
# https://rathena.org - https://github.com/rathena
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http:#www.gnu.org/licenses/>.
#
###########################################################################
# Map Zone Database
###########################################################################
#
# Map Zone Settings
#
###########################################################################
# - Id Zone ID.
# DisabledCommands: List of disabled @commands. (Default: null)
# DisabledSkills: List of disabled skills. (Default: null)
# DisabledItems: List of disabled items. (Default: null)
# DisabledStatuses: List of disabled statuses. (Default: null)
# RestrictedJobs: List of restricted jobs from entering zone. (Default: null)
# Maps: List of maps to apply the zone to.
# Mapflags: List of mapflags. (Default: null)
# - Flag Mapflag name.
# Value Value assigned to mapflag. (Default: true)
###########################################################################

Header:
Type: MAP_ZONES
Version: 1

Footer:
Imports:
- Path: db/pre-re/map_zones.yml
Mode: Prerenewal
- Path: db/re/map_zones.yml
Mode: Renewal
- Path: db/import/map_zones.yml
Loading
Loading