News commandesBonjour /Bonsoir
Aujourd'hui
j'ai décider de vous partager quelques commandes pour les personnes
ne sachant pas les faire elle même.
il y a les commandes
:
.vie
.start (utile pour gravityemu ou elle ne figure
pas)
.pvp1 (astrub)
.pvp2 (amakna village)
.enclo
(bonta)
.atelier (bonta)
.mariage (amène a
l'église)
.kanodjedo1 (village)
.kanodjedo2
(milifutaie)
.inca
.infos (déjà dans l'émulateur a la
base)
.save (déjà dans l'émulateur a la base)
.donjons
(cette commandes vous donnes une liste d'autres commandes qui
téléporte vers des donjons) voici cette liste
:
.dragoeuf
.bouf
.blop
.DC
.champs
.scara
Voila
sa sera tout
voici les ligne code a mettre dans votre
GameThread.java
Spoiler
if(msg.length() > 7 &&
msg.substring(1,
.equalsIgnoreCase("command"))
{
SocketManager.GAME_SEND_MESSAGE(_perso,
"Commandes Disponibles :
\n.enclo\n.atelier\n.kanodjedo1\n.kanodjedo2\n.inca\n.mariage\n.pvp2\n.pvp1\n.vie\n.start\n.infos\n.save\n.donjons",
Ancestra.CONFIG_MOTD_COLOR);
return;
}
if(msg.length() >
7 && msg.substring(1,
.equalsIgnoreCase("donjons"))
{
SocketManager.GAME_SEND_MESSAGE(_perso,
"Commande pour Donjon Disponible :
\n.dragoeuf\n.bouf\n.blop\n.champs\n.scara\n.DC",
Ancestra.CONFIG_MOTD_COLOR);
return;
}
if(msg.length() >
7 && msg.substring(1,
.equalsIgnoreCase("mariage"))
{
if(_perso.get_fight()
!= null)return;
_perso.teleport(Ancestra.CONFIG_mariage_MAP,
Ancestra.CONFIG_mariage_CELL);
return;
}
if(msg.length()
> 5 && msg.substring(1,
6).equalsIgnoreCase("enclo"))
{
if(_perso.get_fight()
!= null)return;
_perso.teleport(Ancestra.CONFIG_enclo_MAP,
Ancestra.CONFIG_enclo_CELL);
return;
}
if(msg.length() >
7 && msg.substring(1,
.equalsIgnoreCase("atelier"))
{
if(_perso.get_fight()
!= null)return;
_perso.teleport(Ancestra.CONFIG_atelier_MAP,
Ancestra.CONFIG_atelier_CELL);
return;
}
if(msg.length()
> 4 && msg.substring(1,
5).equalsIgnoreCase("inca"))
{
if(_perso.get_fight()
!= null)return;
_perso.teleport(Ancestra.CONFIG_INCA_MAP,
Ancestra.CONFIG_INCA_CELL);
return;
}
if(msg.length() >
10 && msg.substring(1,
11).equalsIgnoreCase("kanodjedo1"))
{
if(_perso.get_fight()
!= null)return;
_perso.teleport(Ancestra.CONFIG_kanodjedo1_MAP,
Ancestra.CONFIG_kanodjedo1_CELL);
return;
}
if(msg.length()
> 10 && msg.substring(1,
11).equalsIgnoreCase("kanodjedo2"))
{
if(_perso.get_fight()
!= null)return;
_perso.teleport(Ancestra.CONFIG_kanodjedo2_MAP,
Ancestra.CONFIG_kanodjedo2_CELL);
return;
}
if(msg.length()
> 4 && msg.substring(1,
5).equalsIgnoreCase("bouf"))
{
if(_perso.get_fight()
!= null)return;
_perso.teleport(Ancestra.CONFIG_BOUF_MAP,
Ancestra.CONFIG_BOUF_CELL);
return;
}
if(msg.length() >
4 && msg.substring(1,
5).equalsIgnoreCase("blop"))
{
if(_perso.get_fight()
!= null)return;
_perso.teleport(Ancestra.CONFIG_BLOP_MAP,
Ancestra.CONFIG_BLOP_CELL);
return;
}
if(msg.length() >
5 && msg.substring(1,
6).equalsIgnoreCase("scara"))
{
if(_perso.get_fight()
!= null)return;
_perso.teleport(Ancestra.CONFIG_SCARA_MAP,
Ancestra.CONFIG_SCARA_CELL);
return;
}
if(msg.length() >
2 && msg.substring(1,
3).equalsIgnoreCase("DC"))
{
if(_perso.get_fight() !=
null)return;
_perso.teleport(Ancestra.CONFIG_DC_MAP,
Ancestra.CONFIG_DC_CELL);
return;
}
if(msg.length() >
6 && msg.substring(1,
7).equalsIgnoreCase("champs"))
{
if(_perso.get_fight()
!= null)return;
_perso.teleport(Ancestra.CONFIG_champs_MAP,
Ancestra.CONFIG_champs_CELL);
return;
}
if(msg.length()
> 8 && msg.substring(1,
9).equalsIgnoreCase("dragoeuf"))
{
if(_perso.get_fight()
!= null)return;
_perso.teleport(Ancestra.CONFIG_DRAGO_MAP,
Ancestra.CONFIG_DRAGO_CELL);
return;
}
if(msg.length() >
4 && msg.substring(1,
5).equalsIgnoreCase("pvp1"))
{
if(_perso.get_fight()
!= null)return;
_perso.teleport(Ancestra.CONFIG_PVP1_MAP,
Ancestra.CONFIG_PVP1_CELL);
return;
}
if(msg.length() >
4 && msg.substring(1,
5).equalsIgnoreCase("pvp2"))
{
if(_perso.get_fight()
!= null)return;
_perso.teleport(Ancestra.CONFIG_PVP2_MAP,
Ancestra.CONFIG_PVP2_CELL);
return;
}
if(msg.length() >
5 && msg.substring(1,
6).equalsIgnoreCase("start"))
{
if(_perso.get_fight()
!= null)return;
_perso.teleport(Ancestra.CONFIG_START_MAP,
Ancestra.CONFIG_START_CELL);
return;
}
if(msg.length() >
3 && msg.substring(1, 4).equalsIgnoreCase("vie"))
{
int
count = 100;
Personnage perso = _perso;
int newPDV =
(perso.get_PDVMAX() * count) /
100;
perso.set_PDV(newPDV);
if(perso.isOnline())
SocketManager.GAME_SEND_STATS_PACKET(perso);
SocketManager.GAME_SEND_MESSAGE(_perso,
"Vous avez remplis votre nombre de pdv au max! Chanceux!!",
Ancestra.CONFIG_MOTD_COLOR);
return;
}
if(msg.length() >
5 && msg.substring(1, 6).equalsIgnoreCase("infos"))
{
long
uptime = System.currentTimeMillis() -
Ancestra.gameServer.getStartTime();
int jour = (int)
(uptime/(1000*3600*24));
uptime %= (1000*3600*24);
int hour =
(int) (uptime/(1000*3600));
uptime %= (1000*3600);
int min =
(int) (uptime/(1000*60));
uptime %= (1000*60);
int sec = (int)
(uptime/(1000));
String mess = "===========\n"
+
"Uptime: "+jour+"j "+hour+"h "+min+"m
"+sec+"s\n"
+ "Joueurs en lignes:
"+Ancestra.gameServer.getPlayerNumber()+"\n"
+
"Record de connexion:
"+Ancestra.gameServer.getMaxPlayer()+"\n"
+
"===========";
SocketManager.GAME_SEND_MESSAGE(_perso,
mess, Ancestra.CONFIG_MOTD_COLOR);
return;
}
if(msg.length()
> 4 && msg.substring(1, 5).equalsIgnoreCase("save"))
{
long k;
if((k = System.currentTimeMillis() - _timeLastsave) <
360000)
{
k = (Ancestra.FLOOD_TIME - k)/10;//On calcul la
diff�rence en secondes
return;
}
_timeLastsave =
System.currentTimeMillis();
if(_perso.get_fight() !=
null)return;
SQLManager.SAVE_PERSONNAGE(_perso,true);
SocketManager.GAME_SEND_MESSAGE(_perso,
_perso.get_name()+" sauvegard�.",
Ancestra.CONFIG_MOTD_COLOR);
return;
}
}
Et voila se que vous avez a
mettre dans votre Ancestra.java
Spoiler
public static short CONFIG_START_MAP =
10298;
public static int CONFIG_START_CELL = 314;
public static
short CONFIG_PVP1_MAP = 7423;
public static int CONFIG_PVP1_CELL =
266;
public static short CONFIG_PVP2_MAP = 952;
public static
int CONFIG_PVP2_CELL = 270;
public static short CONFIG_BOUF_MAP =
1856;
public static int CONFIG_BOUF_CELL = 297;
public static
short CONFIG_BLOP_MAP = 11878;
public static int CONFIG_BLOP_CELL
= 323;
public static short CONFIG_SCARA_MAP = 1298;
public
static int CONFIG_SCARA_CELL = 311;
public static short
CONFIG_DC_MAP = 9397;
public static int CONFIG_DC_CELL =
329;
public static short CONFIG_champs_MAP = 7453;
public
static int CONFIG_champs_CELL = 296;
public static short
CONFIG_DRAGO_MAP = 7858;
public static int CONFIG_DRAGO_CELL =
329;
public static short CONFIG_mariage_MAP = 2019;
public
static int CONFIG_mariage_CELL = 381;
public static short
CONFIG_INCA_MAP = 10302;
public static int CONFIG_INCA_CELL =
368;
public static short CONFIG_kanodjedo1_MAP = 534;
public
static int CONFIG_kanodjedo1_CELL = 372;
public static short
CONFIG_kanodjedo2_MAP = 2021;
public static int
CONFIG_kanodjedo2_CELL = 367;
public static short
CONFIG_atelier_MAP = 8731;
public static int CONFIG_atelier_CELL =
381;
public static short CONFIG_enclo_MAP = 8745;
public static
int CONFIG_enclo_CELL = 236;
Voile tous
j’espère en
avoir aider plus d'un