Jump to content
Sign in to follow this  
Cem

Автолут И L2jfrozen 899 Warc222

Recommended Posts

Доброго времени суток всем:) помогите с проблемкой украл у зборки l2jfrozen 899 warc222 автолут содрал с ядра, команда включается в игре но самого автолута не происходит дроп не собирается почсему может быть? зборка тоже l2jfrozen

урал вот это

Confog.java

Скрытый текст
public static boolean ALLOW_AUTOLOOT_COMMAND;

Скрытый текст
ALLOW_AUTOLOOT_COMMAND = Boolean.parseBoolean(optionsSettings.getProperty("AllowAutoLootVoicedCommand", "False"));

VoicedCommandHandler.java

Скрытый текст
if(Config.ALLOW_AUTOLOOT_COMMAND)

{

registerVoicedCommandHandler(new AutoLoot());

}

Скрытый текст
import com.l2jfrozen.gameserver.handler.voicedcommandhandlers.AutoLoot;

потом сам файл autoloot.java в зборке l2jfrozen 899 warc222

и в L2PcInstance.java

Скрытый текст
/** AutoLoot cmd parameters*/

private boolean _autoLootEnabled = false;

Скрытый текст
public void setAutoLootEnabled(final boolean autoLootEnabled)

{

_autoLootEnabled = autoLootEnabled;

}

 

/**

* @param reference

* @return Returns the autoLootEnabled.

*/

public boolean isAutoLootEnabled(final L2Object reference)

{

return _autoLootEnabled && !(reference instanceof L2GrandBossInstance)

&& !(reference instanceof L2RaidBossInstance)

&& !(reference instanceof L2MinionInstance);

}

Share this post


Link to post
Share on other sites

у меня просто этого не было вот я и решил дописать:) а как тогда что бы со всех собирало?

Share this post


Link to post
Share on other sites

return _autoLootEnabled && !(reference instanceof L2GrandBossInstance)

&& !(reference instanceof L2RaidBossInstance)

&& !(reference instanceof L2MinionInstance);

вот здесь скрипт ссылается только на миньёнов и боссов

Share this post


Link to post
Share on other sites

это понятно по названию а для мобов будет?)

Share this post


Link to post
Share on other sites

думаю нужно просто добавить еще L2Monsters и радоватся

Share this post


Link to post
Share on other sites

неа не помогло

заменил

Скрытый текст
return _autoLootEnabled && !(reference instanceof L2GrandBossInstance)

&& !(reference instanceof L2RaidBossInstance)

&& !(reference instanceof L2MinionInstance);

на

Скрытый текст
return _autoLootEnabled && !(reference instanceof L2MonsterInstance);

и все равно не работает( и да ещё украл команду (Tradeoff-on и pmoff-on) так вот pmoff-on работает а tradeoff-on нет прчему ?(

Share this post


Link to post
Share on other sites

Будет время сделаю. На данный момент занят своим сайтом)

Share this post


Link to post
Share on other sites

/*
* 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 2, 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, write to the Free Software Foundation, Inc., 59 Temple
* Place - Suite 330, Boston, MA 02111-1307, USA.
* 
* http://www.gnu.org/copyleft/gpl.html
*/
package com.l2jfrozen.gameserver.handler.voicedcommandhandlers;


import com.l2jfrozen.gameserver.handler.IVoicedCommandHandler;
import com.l2jfrozen.gameserver.model.actor.instance.L2PcInstance;

/**
* @author StarCOM
*/

public class AutoLoot implements IVoicedCommandHandler
{
private static String[] _voicedCommands =
	{
		"looton", "lootoff"
	};

public String[] getVoicedCommandList()
{
	return _voicedCommands;
}

public boolean useVoicedCommand(String command, L2PcInstance activeChar, String text)
{
	if (command.equalsIgnoreCase("looton"))
	{
		activeChar.setAutoLootEnabled(true);
		activeChar.sendMessage("Авто лут Включен.");
	}
	else if (command.equalsIgnoreCase("lootoff"))
	{
		activeChar.setAutoLootEnabled(false);
		activeChar.sendMessage("Авто лут Выключен.");
	}

	return true;
}
}

AutoLoot.java

своровал?

Share this post


Link to post
Share on other sites

да вот

Скрытый текст
/*

* 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 2, 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, write to the Free Software Foundation, Inc., 59 Temple

* Place - Suite 330, Boston, MA 02111-1307, USA.

*

* http://www.gnu.org/copyleft/gpl.html

*/

package com.l2jfrozen.gameserver.handler.voicedcommandhandlers;

 

 

import com.l2jfrozen.gameserver.handler.IVoicedCommandHandler;

import com.l2jfrozen.gameserver.model.actor.instance.L2PcInstance;

 

/**

* @author StarCOM

*/

 

public class AutoLoot implements IVoicedCommandHandler

 

{

private static String[] _voicedCommands =

{

"looton", "lootoff"

};

 

public String[] getVoicedCommandList()

{

return _voicedCommands;

}

 

public boolean useVoicedCommand(String command, L2PcInstance activeChar, String text)

{

if (command.equalsIgnoreCase("looton"))

{

activeChar.setAutoLootEnabled(true);

activeChar.sendMessage("Авто лут Включен.");

}

else if (command.equalsIgnoreCase("lootoff"))

{

activeChar.setAutoLootEnabled(false);

activeChar.sendMessage("Авто лут Выключен.");

}

 

return true;

}

}

Share this post


Link to post
Share on other sites

тему можно оффать, разобрался:)

Share this post


Link to post
Share on other sites

а да только вот ещё с tradeoff-on не разобрался)

Share this post


Link to post
Share on other sites

подскажет кто где ещё надо добровлять кроме config.java, voicecommand, и самого tradeoff.java для отключения tradeoff-on?

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...