Você não é registrado, por favor registre-se para ter acesso ao conteúdo completo.
Caso seja registrado, efetue login.
Esqueceu sua senha? Clique aqui
Recomendamos o uso do Mozilla Firefox para uma melhor visualização.    


Início Postados Hoje Marcar Fóruns Como Lidos Álbums Banidos SE Team Medalhas
Voltar   Secret Experience > Área L2J > [L2J] Downloads > [Lineage] Java Mods
Registrar Loteria VIPStaff SERegras do fórum Comunidade Arcade Postados Hoje Pesquisar Experience
   

Secret Experience.NET   Secret Experience Corporation - Welcome To The Real World
     Anúncios SE

Resposta
 
LinkBack Ferramentas do Tópico Modos de Exibição
Antigo 09-09-2010, 05:37 PM   #1 (permalink)
Amigo SE
 
Avatar de C.Bartowski
 
Registrado em: Feb 2010
Localização: Caxias do Sul - RS
Posts: 644
Agradeceu: 405
Agradecido 582 Vezes em 224 Posts
Achei Ruim:
Acharam ruim Vezes em Posts
Rate Designer: Iniciante
Meu Estado:
Enviar mensagem via Windows Live Messenger para C.Bartowski
Nome Real: Henrique Galafassi Dalssaso

Inventório de C.Bartowski

Padrão Voiced Command .hero

Bom galera outro mod ae pra voces...

Esse aqui faz com que quando o player digitar .hero

ele virará hero...

Você pode mudar o item que voce quer que o player "Pague" para se tornar hero...

Segue abaixo a Diff em forma de Code e depois vai anexada =)

Código: [Somente Usuários Registrados Podem Visualizar os Links Desta PáginaClique aqui para se Registrar]
Index: Trunk/L2JStep_CORE/config/Custom/L2JMods.properties
===================================================================
--- Trunk/L2JStep_CORE/config/Custom/L2JMods.properties (revision 1)
+++ TTrunk/L2JStep_CORE/config/Custom/L2JMods.properties (working copy)			
@@ -881,6 +881,18 @@
	
+#--------------------------------------------------
+# Set this to True to enable .hero voiced command #
+#--------------------------------------------------
+AllowHeroCommand = False
+# Item id that it will take and make you hero
+HeroItemId = 3481
+# How many of this item will it take?
+HeroItemCount = 1


Index: Trunk/java/com/l2jstep/Config.java
===================================================================
--- Trunk/java/com/l2jstep/Config.java (revision 1)
+++ Trunk/java/com/l2jstep/Config.java (working copy)

@@ -881,6 +881,18 @@

    public static boolean ALT_GAME_KARMA_PLAYER_CAN_USE_WAREHOUSE;
+   public static boolean ALLOW_HERO_COMMAND;
+   public static int HERO_ITEM_ID;
+   public static int HERO_ITEM_COUNT;
    public static boolean L2JMOD_CHAMPION_ENABLE;


@@ -881,6 +881,18 @@


+            	ALLOW_HERO_COMMAND = Boolean.parseBoolean(L2JModSettings.getProperty("AllowHeroCommand", "false")); 
+               HERO_ITEM_ID = Integer.parseInt(L2JModSettings.getProperty("HeroItemId", "3481"));
+               HERO_ITEM_COUNT = Integer.parseInt(L2JModSettings.getProperty("HeroItemCount", "1"));
                L2JMOD_CHAMPION_ENABLE = Boolean.parseBoolean(L2JModSettings.getProperty("ChampionEnable", "false"));
                L2JMOD_CHAMPION_FREQUENCY = Integer.parseInt(L2JModSettings.getProperty("ChampionFrequency", "0"));
                L2JMOD_CHAMP_MIN_LVL = Integer.parseInt(L2JModSettings.getProperty("ChampionMinLevel", "20"));

			
Index: Trunk/L2JStep_CORE/java/com/l2jstep/gameserver/handler/voicedcommandhandlers/hero.java
===================================================================
--- Trunk/L2JStep_CORE/java/com/l2jstep/gameserver/handler/voicedcommandhandlers/hero.java (revision 1)
+++ Trunk/L2JStep_CORE/java/com/l2jstep/gameserver/handler/voicedcommandhandlers/hero.java (working copy)	
+/*
+ * 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/>.
+ */
+package com.it.br.gameserver.handler.voicedcommandhandlers;
+
+import com.l2jstep.Config;
+import com.l2jstep.gameserver.handler.IVoicedCommandHandler;
+import com.l2jstep.gameserver.model.actor.instance.L2PlayableInstance;
+import com.l2jstep.gameserver.model.actor.instance.L2PcInstance;
+import com.l2jstep.gameserver.model.L2ItemInstance;
+import com.l2jstep.gameserver.serverpackets.ActionFailed;
+import com.l2jstep.gameserver.serverpackets.SocialAction;
+
+/**
+ * @author Kinho!
+ */
+public class hero implements IVoicedCommandHandler
+{
+	private static final String[] VOICED_COMMANDS = {"hero"};
+	
+	public boolean useVoicedCommand(String command, L2PcInstance activeChar, String target)
+	{
+		if (command.equalsIgnoreCase("hero"))
+		{
+            if(activeChar.getInventory().getItemByItemId(Config.HERO_ITEM_ID) != null && activeChar.getInventory().getItemByItemId(Config.HERO_ITEM_ID).getCount() >= Config.HERO_ITEM_COUNT)
+            {
+            	activeChar.getInventory().destroyItemByItemId("GoldDragon", Config.HERO_ITEM_ID, Config.HERO_ITEM_COUNT, activeChar, activeChar.getTarget());
+                activeChar.broadcastPacket(new SocialAction(activeChar.getObjectId(), 16));
+            	activeChar.setHero(true);
+                activeChar.sendMessage("You became hero untill restart and gave 1 gold dragon");
+                activeChar.broadcastUserInfo();
+              }
+            else
+            {
+               	activeChar.sendMessage("You need 1 gold dragon to become hero.");
+                return true;
+            }
+		}
+		return false;
+		}
+	public String[] getVoicedCommandList()
+	{
+		return VOICED_COMMANDS;
+	}
+}

Index: Trunk/L2JStep_CORE/java/com/l2jstep/gameserver/handler/voicedcommandhandlers.java
===================================================================
--- Trunk/L2JStep_CORE/java/com/l2jstep/gameserver/handler/voicedcommandhandlers.java (revision 1)
+++ Trunk/L2JStep_CORE/java/com/l2jstep/gameserver/handler/voicedcommandhandlers.java (working copy)

@@ -881,6 +881,18 @@
 import com.l2jstep.gameserver.handler.voicedcommandhandlers.BuyRec;
+import com.l2jstep.gameserver.handler.voicedcommandhandlers.hero;	
 import com.l2jstep.gameserver.handler.voicedcommandhandlers.OnlinePlayers;
@@ -881,6 +881,18 @@

+    	if (Config.ALLOW_HERO_COMMAND)
+    	registerVoicedCommandHandler(new hero());
    	registerVoicedCommandHandler(new stats());
Segue abaixo o anexo e os creditos

Créditos pelo MOD: Kinho! e Mazokista

Vlw's


Arquivos Anexados
Tipo de Arquivo: txt Command .hero.txt (5.2 KB, 33 visualizações) Baixar
__________________
[Somente Usuários Registrados Podem Visualizar os Links Desta PáginaClique aqui para se Registrar] [Somente Usuários Registrados Podem Visualizar os Links Desta PáginaClique aqui para se Registrar] [Somente Usuários Registrados Podem Visualizar os Links Desta PáginaClique aqui para se Registrar]
C.Bartowski está offline  
O seguinte membro ao lado disse Obrigado(a) a : C.Bartowski por gostar deste Post :
FULL_LOL (08-07-2013)
Links Patrocinados
Antigo 09-09-2010, 10:14 PM   #2 (permalink)
Banido
 
Avatar de Kinho!
 
Registrado em: Jun 2010
Posts: 117
Agradeceu: 47
Agradecido 96 Vezes em 44 Posts
Achei Ruim:
Acharam ruim Vezes em Posts
Meu Estado:

Inventório de Kinho!

Padrão

Opa maninho...

Java MOD nao tem creditos definidos.... Apenas Usei um comando como base e alterei umas linha e saiu isso... Achoque o creditos tem que sre todo do Pedro, pois ele que praticamente que fez o Mod....

Obs: Nao me lembro o nick do pedro do outro forum,( Forum Ingles) vou pergunta ele e ja edito o topico...

Kinho! está offline   Responder com Citação
Resposta


Regras para Posts
Você não pode postar novos tópicos
Você não pode postar respostas
Você não pode postar anexos
Você não pode editar seus posts

Código [IMG] Sim
Código HTML Não
Trackbacks are Sim
Pingbacks are Sim
Refbacks are Sim



Horários baseados na GMT -3. Agora são 05:34 AM.
 



Search Engine Optimization by vBSEO 3.3.0