show code js

顯示具有 l1j 標籤的文章。 顯示所有文章
顯示具有 l1j 標籤的文章。 顯示所有文章

2010年9月28日 星期二

升級血魔補滿

開啟: \src\l1j\server\server\model\Instance\L1PcInstance.java

找到:
addBaseMaxHp(randomHp);
addBaseMaxMp(randomMp);

在後面加入:
if (Config.FullHPMP){
setCurrentHp(getMaxHp());
setCurrentMp(getMaxMp());
}

關檔



開啟: \src\l1j\server\Config.java

找到:
public static int LV99_EXP;

在之後加入:
public static boolean MaxHPMP; //TODO 升級血魔滿

找到:
// rates.properties
try {
Properties rateSettings = new Properties();
InputStream is = new FileInputStream(new File(RATES_CONFIG_FILE));
rateSettings.load(is);
is.close();

在之後加入:
MaxHPMP = Boolean.parseBoolean(RateSettings.getProperty(
"FullHPMP", "false"));

找到:
// rates.properties
else if (pName.equalsIgnoreCase("RateXp")) {
RATE_XP = Double.parseDouble(pValue);

在之前加入:
else if (pName.equalsIgnoreCase("FullHPMP")) {
MaxHPMP = Boolean.valueOf(pValue);
}

關檔



開啟: \config\rates.properties
加入:
#──────────────────
# 升級血魔滿
FullHPMP = True

關檔

2010年9月24日 星期五

卡連的對話及傳送

開啟: 資料庫
執行:
UPDATE npcaction SET normal_action = 'karen1', caotic_action = 'karen1', teleport_url = 'karen3', teleport_urla = 'teleport dark island-in' WHERE npcid = '50005';

關閉資料庫

開啟: \data\xml\NpcActions\Teleporter.xml
找到:
<?xml version="1.0" encoding="UTF-8"?>
<NpcActionList>

在之後加入:
<!-- DESC10 -->
<Action Name="teleport dark island-in" NpcId="50005">
<Teleport X="32851" Y="32904" Map="304" Heading="5" Price="0"/>
</Action>
<!-- DESC10 -->

關檔

開啟: \src\l1j\server\server\model\Instance\L1MerchantInstance.java
找到:
// html表示パケット送信

在之前加入:
// DESC10
else if (npcid == 50005) {
if (player.isDarkelf()) {
htmlid = "karen1";
} else if (player.isElf()) {
htmlid = "karen4";
}
else {
htmlid = "karen2";
}
}
// DESC10

關檔

修正沉默洞穴新手傳師

開啟: 資料庫

執行
UPDATE spawnlist_npc SET mapid = 304 WHERE npc_templateid = '50069';
UPDATE npcaction SET normal_action = 'enya1', caotic_action = 'enya1', teleport_url = 'enya3', teleport_urla = 'teleport valley-go' WHERE npcid = '50069';

關閉資料庫

開啟: \data\xml\NpcActions\Teleporter.xml
找到:
<?xml version="1.0" encoding="UTF-8"?>
<NpcActionList>

在之後加入:
<!-- 沉默洞穴艾納至隱藏谷 by sniperlan(yuan) -->
<Action Name="teleport valley-go" NpcId="50069">
<Teleport X="32675" Y="32861" Map="69" Heading="5" Price="0"/>
</Action>
<!-- 沉默洞穴艾納至隱藏谷 by sniperlan(yuan) -->

關檔

修正森林之母非妖精對話

開啟: \src\l1j\server\server\model\Instance\L1MerchantInstance.java
找到:
} else if (npcid == 70844) { // 森とエルフの母
if (player.isElf()) { // エルフ
if (player.getLevel() >= 30) {
if (quest.isEnd(L1Quest.QUEST_LEVEL15)) { // Lv15終了済み
int lv30_step = quest
.get_step(L1Quest.QUEST_LEVEL30);
if (lv30_step == L1Quest.QUEST_END) { // 終了済み
htmlid = "motherEE3";
} else if (lv30_step >= 1) { // 同意済み
htmlid = "motherEE2";
} else if (lv30_step <= 0) { // 未同意
htmlid = "motherEE1";
}
} else { // Lv15未終了
htmlid = "mothere1";
}
} else { // Lv30未満
htmlid = "mothere1";
}
}

在之後加入:
// desc1
else
{
htmlid = "motherm1";
}
// desc1

關檔

2010年9月23日 星期四

修正城堡攻守時間更新

開啟: \src\l1j\server\server\datatables\CastleTable.java

找到:
// Referenced classes of package l1j.server.server:

在之前加入:
import java.text.SimpleDateFormat;

找到:
String fm = DateFormat.getDateTimeInstance().format(
castle.getWarTime().getTime());
替換成:
SimpleDateFormat sdf = new SimpleDateFormat("yyyy/MM/dd HH:mm:ss");
String fm = sdf.format(castle.getWarTime().getTime());
/*String fm = DateFormat.getDateTimeInstance().format(
castle.getWarTime().getTime());*/
關檔及存檔

來源 : linsf260

2010年9月22日 星期三

亞丁、奇岩地下城傳師

問題 : 奇岩內城NPC曼孟因點其時游標為攻擊狀態而無法與其對話,應要修改list.spr增加對應怪物

匯入資料庫:
INSERT INTO `npc` VALUES ('9000021', '普若亞', '普若亞', '亞丁地下城傳師', 'L1Teleporter', '940', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '', '0', '1', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '', '0', '-1', '-1', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '-1', '0', '14', '0', '0', '0');
INSERT INTO `npc` VALUES ('9000022', '曼孟', '$4809', '奇岩地下城傳師', 'L1Teleporter', '4790', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '', '0', '1', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '', '0', '-1', '-1', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '-1', '0', '14', '0', '0', '0');
INSERT INTO `npcaction` VALUES ('9000021', 'adenflora1', 'adenflora1', 'adenflora2', 'teleport adencd');
INSERT INTO `npcaction` VALUES ('9000022', 'gr_mammon1', 'gr_mammon1', 'gr_mammon3', 'teleport grtel');
INSERT INTO `spawnlist_npc` VALUES ('9000001', '普若亞', '1', '9000021', '32870', '32555', '0', '0', '4', '0', '300', '0');
INSERT INTO `spawnlist_npc` VALUES ('9000002', '曼孟', '1', '9000022', '32719', '32799', '0', '0', '4', '0', '52', '0');

開啟: \data\xml\NpcActions\Teleporter.xml
找到:
<NpcActionList>

在後面加入:
<!-- 傳送奇岩地下城的傳師 by sniperlan(yuan) -->
<Action Name="teleport grtel" NpcId="9000022">
<Teleport X="32805" Y="32793" Map="248" Heading="4" Price="0"/>
</Action>
<!-- 傳送奇岩地下城的傳師 by sniperlan(yuan) -->
<!-- 傳送亞丁地下城的傳師 by sniperlan(yuan) -->
<Action Name="teleport adencd" NpcId="9000021">
<Teleport X="32660" Y="32800" Map="257" Heading="2" Price="0"/>
</Action>
<!-- 傳送亞丁地下城的傳師 by sniperlan(yuan) -->

關檔

Beginner資料表

一、用途 : 角色出生同時所攜物品
二、欄位說明
  id 識別用
  item_id 物品識別碼(對應:防具armor、道具etcitem、武器weapon)
  count 數量
  charge_count
  enchantlvl (等級限制)
  item_name 物品名稱
  activate 授予指定的職業
 (一)activeate 各種值定義
    A = 全部
    P = 王族
    E = 妖精
    K = 騎士
    W = 法師
    D = 黑暗妖精
    R = 龍騎士
    I = 幻術士

2010年9月20日 星期一

傳送到新手村傳師

說明: 德瑞斯特-隱藏之谷,傑諾-歌唱之島
開啟: \data\xml\NpcActions\Teleporter.xml
找到:
<?xml version="1.0" encoding="UTF-8"?>
<NpcActionList>

在後面加入:
<Action Name="teleport hidden-valley" NpcId="50055">
<Teleport X="32675" Y="32861" Map="69" Heading="5" Price="0"/>
</Action>
<Action Name="teleport singing-island" NpcId="50016">
<Teleport X="32803" Y="32762" Map="68" Heading="5" Price="0"/>
</Action>

關檔

開啟資料庫:
在 spawnlist_npc 資料表中的 npc_template 欄位為 50016 與 50055 將其 count 欄位值 由 0 改為 1

來源: 87you

一般玩家輸入(.)顯示指令錯誤問題

title: modify (.) to fix a display error in game
open: \src\l1j\server\server\clientpackets\C_Chat.java
find:
if (chatText.startsWith(".")) {

replace:
// ---BEGIN---
/* if (chatText.startsWith(".")) { */
if (chatText.startsWith(".") && pc.getAccessLevel() > 0) {
// ---END---

close and save file

ps:
can add:
&& !chatText.startsWith("..")
when gm send a message is "...." can`t be show a error