GUIA DE SERVIDORES EATHENA
Navegador Web ::
GuiaRO >>
Guías eAthena >>
Servidores eAthena
[Guia] Añadir mas mapas al @go
[Categoria: Servidores eAthena]
[Autor: djscusa]
[Tema Foro: [Guia] Añadir mas mapas al @go || Comentarios: 2]
Esta guia es para la nueva versión del @go que esta disponibles en la
version actual del eathena.
Empezamos abriendo este archivo del eathena. eathena/src/map/atcommand.c
Una vez abierto el documento le damos a buscar y en la busqueda ponemos MAP_PRONTERA
Bien ya hay vamos a empezar a añadir nuestra propia ciudad o otros
mapas.
Abajo de MAP_VEINS añadimos exactamente igual que
todos los de arriba nuestro mapas, yo por ejemplo e añadido Moscovia
que no esta y mi propia ciudad. ejemplo:
| Codigo |
const struct { char map[MAP_NAME_LENGTH_EXT]; int x,
y; } data[] = {
{ MAP_PRONTERA, 156, 191 }, // 0=Prontera
{ MAP_MORROC, 156, 93 }, // 1=Morroc
{ MAP_GEFFEN, 119, 59 }, // 2=Geffen
{ MAP_PAYON, 162, 233 }, // 3=Payon
{ MAP_ALBERTA, 192, 147 }, // 4=Alberta
{ MAP_IZLUDE, 128, 114 }, // 5=Izlude
{ MAP_ALDEBARAN, 140, 131 }, // 6=Al de Baran
{ MAP_LUTIE, 147, 134 }, // 7=Lutie
{ MAP_COMODO, 209, 143 }, // 8=Comodo
{ MAP_YUNO, 157, 51 }, // 9=Yuno
{ MAP_AMATSU, 198, 84 }, // 10=Amatsu
{ MAP_GONRYUN, 160, 120 }, // 11=Gon Ryun
{ MAP_UMBALA, 89, 157 }, // 12=Umbala
{ MAP_NIFLHEIM, 21, 153 }, // 13=Niflheim
{ MAP_LOUYANG, 217, 40 }, // 14=Lou Yang
{ MAP_NOVICE, 53, 111 }, // 15=Training Grounds
{ MAP_JAIL, 23, 61 }, // 16=Prison
{ MAP_JAWAII, 249, 127 }, // 17=Jawaii
{ MAP_AYOTHAYA, 151, 117 }, // 18=Ayothaya
{ MAP_EINBROCH, 64, 200 }, // 19=Einbroch
{ MAP_LIGHTHALZEN, 158, 92 }, // 20=Lighthalzen
{ MAP_EINBECH, 70, 95 }, // 21=Einbech
{ MAP_HUGEL, 96, 145 }, // 22=Hugel
{ MAP_RACHEL, 130, 110 }, // 23=Rachel
{ MAP_VEINS, 216, 123 }, // 24=Veins
{ MAP_MOSCOVIA, 150, 150 }, // 25=Moscovia (custom)
{ MAP_LIBERTY, 319, 285 }, // 26=Liberty (custom)
}; |
Ahora que emos modificado esa parte, seguimos bajando el documento para seguir
modificando las cosas necesarias, por ejemplo la parte cuando hacemos @go siempre
no saldra el tipico mensaje con el numero y nombre de la ciudad (tambien vamos
a añadirle nuestro mapas), Ejemplo:
| Codigo |
clif_displaymessage(fd, msg_txt(38)); // Invalid location
number or name.
clif_displaymessage(fd, msg_txt(82)); // Please, use one of this number/name:
clif_displaymessage(fd, " 0=Prontera 1=Morroc 2=Geffen");
clif_displaymessage(fd, " 3=Payon 4=Alberta 5=Izlude");
clif_displaymessage(fd, " 6=Al De Baran 7=Lutie 8=Comodo");
clif_displaymessage(fd, " 9=Yuno 10=Amatsu 11=Gon Ryun");
clif_displaymessage(fd, " 12=Umbala 13=Niflheim 14=Lou Yang");
clif_displaymessage(fd, " 15=Novice Grounds 16=Prison 17=Jawaii");
clif_displaymessage(fd, " 18=Ayothaya 19=Einbroch 20=Lighthalzen");
clif_displaymessage(fd, " 21=Einbech 22=Hugel 23=Rachel");
clif_displaymessage(fd, " 24=Veins 25=Moscovia 26=Liberty"); |
Ya por ultimo, hay que modificar esta parte del documento abierto, un poco
mas abajo tenemos que añadir la version @go nombre mapa, como lo emos
echo arriba tenemos que copiar parte del codigo y modificarlo quedando de esta
manera. (solo esta la parte final del codigo) ejemplo:
| Codigo |
} else if (strncmp(map_name, "einbech", 3)
== 0) { // 3 first characters
town = 21;
} else if (strncmp(map_name, "hugel", 3) == 0) { // 3 first
characters
town = 22;
} else if (strncmp(map_name, "rachel", 3) == 0) { // 3 first
characters
town = 23;
} else if (strncmp(map_name, "veins", 3) == 0) { // 3 first
characters
town = 24;
} else if (strncmp(map_name, "moscovia", 3) == 0) { // Custom
town = 25;
} else if (strncmp(map_name, "liberty", 3) == 0) { // Custom
town = 26;
}
|
Pero la cosa que aun no termina de modifcar, ahora tenemos que abrir otro archivo.
Abrimos eathena/src/common/mapindex.h
Ahora tenemos que añadir nuestro mapa en la lista de hay, por ejemplo:
| Codigo |
#define MAP_PRONTERA "prontera"
#define MAP_GEFFEN "geffen"
#define MAP_MORROC "morocc"
#define MAP_ALBERTA "alberta"
#define MAP_PAYON "payon"
#define MAP_IZLUDE "izlude"
#define MAP_ALDEBARAN "aldebaran"
#define MAP_LUTIE "xmas"
#define MAP_COMODO "comodo"
#define MAP_YUNO "yuno"
#define MAP_AMATSU "amatsu"
#define MAP_GONRYUN "gonryun"
#define MAP_UMBALA "umbala"
#define MAP_NIFLHEIM "niflheim"
#define MAP_LOUYANG "louyang"
#define MAP_JAWAII "jawaii"
#define MAP_AYOTHAYA "ayothaya"
#define MAP_EINBROCH "einbroch"
#define MAP_LIGHTHALZEN "lighthalzen"
#define MAP_EINBECH "einbech"
#define MAP_HUGEL "hugel"
#define MAP_RACHEL "rachel"
#define MAP_VEINS "veins"
#define MAP_MOSCOVIA "moscovia" // Custom
#define MAP_LIBERTY "liberty" // Custom
#define MAP_JAIL "sec_pri"
#define MAP_NOVICE "new_zone01" |
Ya con eso añadido, ya emos terminado de modificar el source ya solo
queda compilar el eathena para que puedas usar las modificaciones realizadas.
[Si quieres distribuir esta Guia primero pide permiso al Autor y respeta el
Autor origianl]
[Categoria: Servidores eAthena]
[Autor: djscusa]
[Tema Foro: [Guia] Añadir mas mapas al @go || Comentarios: 2]
Navegador Web ::
GuiaRO >>
Guías eAthena >>
Servidores eAthena
|