页游SF|页游咯发布站
公益性信息网站,请自行辨别真伪
网站首页
取名符号
技术文章
 
烈焰私服服务端里添加官方九幽海域传送员的脚本详解
文章作者:admin 文章来源:烈焰SF|烈焰77发布站 更新时间:2015-3-14 13:52:07
LUA脚本如下

function ontalk2106(npc,event,player)
player:echo(0,npc:GetLowGUID(),[[ 
 九幽蛇王击溃龙族之后,获得了大量的宝藏
 被藏在了九幽海域深处,勇士们,快前往寻宝吧


<u><a href='event:M2402,1'>九幽海域(60级)</a></u>  <u><a href='event:M2402,2'>九幽海域(70级)</a></u>  <u><a href='event:M2402,3'>九幽海域(80级)</a></u>
#&talk_line#&
<u><a href='event:M2402,4'>九幽海域(飞1)</a></u>  <u><a href='event:M2402,5'>九幽海域(飞2)</a></u>  <u><a href='event:M2402,6'>九幽海域(飞3)</a></u>
#&talk_line#&
<u><a href='event:M2402,7'>九幽海域(4-5)</a></u>  <u><a href='event:M2402,8'>九幽海域(6-8)</a></u>  <u><a href='event:M2402,9'>九幽海域(9-12)</a></u>

说明:
各地图均爆装备,请根据自身能力选择
 
#&talk_line#&
 热血烈海 倾力打造
]]);
end

function ontalk2106_1(npc,event,player)
 if player:gen_has(5192) == 0 and player:gen_has(5193) == 0 and player:gen_has(5194) == 0 and player:gen_has(5195) == 0 and player:gen_has(5300) == 0 and player:gen_has(5301) == 0 and player:gen_has(5302) == 0 and player:gen_has(5303) == 0 then
   if player:get_level() >= 60 and player:get_level() <= 69  then
    if player:num_item(10178,1) >= 1 then
    if player:isenter_map() == 0 then
     player:randomthismap(51);
     player:remove_item(10178,1);
     player:alert(19,0,0,"您只有60分钟时间消灭副本里的怪物");
    else
     player:alert(10,0,0,"你刚退出副本,再次进入需要"..player:isenter_map().."秒");
     ontalk2106(npc,0,player,0);
    end
    else
    player:alert(10,0,0,"需1个破碎的时空卷轴才可进入");
    ontalk2106(npc,0,player,0);
    end
   else
    player:alert(10,0,0,"您的等级在60-69才可进入");
    ontalk2106(npc,0,player,0);
   end

 else
  player:alert(10,0,0,"您正在押镖或押送灵兽,不能进入");
  ontalk2106(npc,0,player,0);
 end
end

function ontalk2106_2(npc,event,player)
 if player:gen_has(5192) == 0 and player:gen_has(5193) == 0 and player:gen_has(5194) == 0 and player:gen_has(5195) == 0 and player:gen_has(5300) == 0 and player:gen_has(5301) == 0 and player:gen_has(5302) == 0 and player:gen_has(5303) == 0 then
   if player:get_level() >= 70 and player:get_level() <= 79  then
    if player:num_item(10178,1) >= 1 then
    if player:isenter_map() == 0 then
     player:remove_item(10178,1);
     player:randomthismap(51);
     player:alert(19,0,0,"您只有60分钟时间消灭副本里的怪物");
    else
     player:alert(10,0,0,"你刚退出副本,再次进入需要"..player:isenter_map().."秒");
     ontalk2106(npc,0,player,0);
    end
    else
    player:alert(10,0,0,"需1个破碎的时空卷轴才可进入");
    ontalk2106(npc,0,player,0);
    end
   else
    player:alert(10,0,0,"您的等级在70-79才可进入");
    ontalk2106(npc,0,player,0);
   end

 else
  player:alert(10,0,0,"您正在押镖或押送灵兽,不能进入");
  ontalk2106(npc,0,player,0);
 end
end

function ontalk2106_3(npc,event,player)
 if player:gen_has(5192) == 0 and player:gen_has(5193) == 0 and player:gen_has(5194) == 0 and player:gen_has(5195) == 0 and player:gen_has(5300) == 0 and player:gen_has(5301) == 0 and player:gen_has(5302) == 0 and player:gen_has(5303) == 0 then
   if player:get_level() >= 80 and player:get_level() <= 89  then
    if player:num_item(10178,1) >= 1 then
    if player:isenter_map() == 0 then
     player:remove_item(10178,2);
     player:randomthismap(52);
     player:alert(19,0,0,"您只有60分钟时间消灭副本里的怪物");
    else
     player:alert(10,0,0,"你刚退出副本,再次进入需要"..player:isenter_map().."秒");
     ontalk2106(npc,0,player,0);
    end
    else
    player:alert(10,0,0,"需1个破碎的时空卷轴才可进入");
    ontalk2106(npc,0,player,0);
    end
   else
    player:alert(10,0,0,"您的等级在80-89才可进入");
    ontalk2106(npc,0,player,0);
   end

 else
  player:alert(10,0,0,"您正在押镖或押送灵兽,不能进入");
  ontalk2106(npc,0,player,0);
 end
end


function ontalk2106_4(npc,event,player)
 if player:gen_has(5192) == 0 and player:gen_has(5193) == 0 and player:gen_has(5194) == 0 and player:gen_has(5195) == 0 and player:gen_has(5300) == 0 and player:gen_has(5301) == 0 and player:gen_has(5302) == 0 and player:gen_has(5303) == 0 then
   if player:get_param(258) >= 1  then
    if player:num_item(10178,1) >= 1 then
    if player:isenter_map() == 0 then
     player:remove_item(10178,2);
     player:randomthismap(53);
     player:alert(19,0,0,"您只有60分钟时间消灭副本里的怪物");
    else
     player:alert(10,0,0,"你刚退出副本,再次进入需要"..player:isenter_map().."秒");
     ontalk2106(npc,0,player,0);
    end
    else
    player:alert(10,0,0,"需1个破碎的时空卷轴才可进入");
    ontalk2106(npc,0,player,0);
    end
   else
    player:alert(10,0,0,"飞升等级1级以上才可进入");
    ontalk2106(npc,0,player,0);
   end

 else
  player:alert(10,0,0,"您正在押镖或押送灵兽,不能进入");
  ontalk2106(npc,0,player,0);
 end
end

function ontalk2106_5(npc,event,player)
 if player:gen_has(5192) == 0 and player:gen_has(5193) == 0 and player:gen_has(5194) == 0 and player:gen_has(5195) == 0 and player:gen_has(5300) == 0 and player:gen_has(5301) == 0 and player:gen_has(5302) == 0 and player:gen_has(5303) == 0 then
   if player:get_param(258) >= 2  then
    if player:num_item(10178,1) >= 1 then
    if player:isenter_map() == 0 then
     player:remove_item(10178,1);
     player:randomthismap(54);
     player:alert(19,0,0,"您只有60分钟时间消灭副本里的怪物");
    else
     player:alert(10,0,0,"你刚退出副本,再次进入需要"..player:isenter_map().."秒");
     ontalk2106(npc,0,player,0);
    end
    else
    player:alert(10,0,0,"需1个破碎的时空卷轴才可进入");
    ontalk2106(npc,0,player,0);
    end
   else
    player:alert(10,0,0,"飞升等级2级以上才可进入");
    ontalk2106(npc,0,player,0);
   end

 else
  player:alert(10,0,0,"您正在押镖或押送灵兽,不能进入");
  ontalk2106(npc,0,player,0);
 end
end

function ontalk2106_6(npc,event,player)
 if player:gen_has(5192) == 0 and player:gen_has(5193) == 0 and player:gen_has(5194) == 0 and player:gen_has(5195) == 0 and player:gen_has(5300) == 0 and player:gen_has(5301) == 0 and player:gen_has(5302) == 0 and player:gen_has(5303) == 0 then
   if player:get_param(258) >= 3  then
    if player:num_item(10178,1) >= 1 then
    if player:isenter_map() == 0 then
     player:remove_item(10178,1);
     player:randomthismap(55);
     player:alert(19,0,0,"您只有60分钟时间消灭副本里的怪物");
    else
     player:alert(10,0,0,"你刚退出副本,再次进入需要"..player:isenter_map().."秒");
     ontalk2106(npc,0,player,0);
    end
    else
    player:alert(10,0,0,"需1个破碎的时空卷轴才可进入");
    ontalk2106(npc,0,player,0);
    end
   else
    player:alert(10,0,0,"飞升等级3级以上才可进入");
    ontalk2106(npc,0,player,0);
   end

 else
  player:alert(10,0,0,"您正在押镖或押送灵兽,不能进入");
  ontalk2106(npc,0,player,0);
 end
end

function ontalk2106_7(npc,event,player)
 if player:gen_has(5192) == 0 and player:gen_has(5193) == 0 and player:gen_has(5194) == 0 and player:gen_has(5195) == 0 and player:gen_has(5300) == 0 and player:gen_has(5301) == 0 and player:gen_has(5302) == 0 and player:gen_has(5303) == 0 then
   if player:get_param(258) >= 4 and  player:get_param(258) <= 5 then
    if player:num_item(10178,1) >= 1 then
    if player:isenter_map() == 0 then
     player:remove_item(10178,1);
     player:randomthismap(56);
     player:alert(19,0,0,"您只有60分钟时间消灭副本里的怪物");
    else
     player:alert(10,0,0,"你刚退出副本,再次进入需要"..player:isenter_map().."秒");
     ontalk2106(npc,0,player,0);
    end
    else
    player:alert(10,0,0,"需1个破碎的时空卷轴才可进入");
    ontalk2106(npc,0,player,0);
    end
   else
    player:alert(10,0,0,"飞升等级4-5级以上才可进入");
    ontalk2106(npc,0,player,0);
   end

 else
  player:alert(10,0,0,"您正在押镖或押送灵兽,不能进入");
  ontalk2106(npc,0,player,0);
 end
end

function ontalk2106_8(npc,event,player)
 if player:gen_has(5192) == 0 and player:gen_has(5193) == 0 and player:gen_has(5194) == 0 and player:gen_has(5195) == 0 and player:gen_has(5300) == 0 and player:gen_has(5301) == 0 and player:gen_has(5302) == 0 and player:gen_has(5303) == 0 then
   if player:get_param(258) >= 6 and  player:get_param(258) <= 8 then
    if player:num_item(10178,1) >= 1 then
    if player:isenter_map() == 0 then
     player:remove_item(10178,1);
     player:randomthismap(57);
     player:alert(19,0,0,"您只有60分钟时间消灭副本里的怪物");
    else
     player:alert(10,0,0,"你刚退出副本,再次进入需要"..player:isenter_map().."秒");
     ontalk2106(npc,0,player,0);
    end
    else
    player:alert(10,0,0,"需1个破碎的时空卷轴才可进入");
    ontalk2106(npc,0,player,0);
    end
   else
    player:alert(10,0,0,"飞升等级6-8级以上才可进入");
    ontalk2106(npc,0,player,0);
   end
 else
  player:alert(10,0,0,"您正在押镖或押送灵兽,不能进入");
  ontalk2106(npc,0,player,0);
 end
end


function ontalk2106_9(npc,event,player)
 if player:gen_has(5192) == 0 and player:gen_has(5193) == 0 and player:gen_has(5194) == 0 and player:gen_has(5195) == 0 and player:gen_has(5300) == 0 and player:gen_has(5301) == 0 and player:gen_has(5302) == 0 and player:gen_has(5303) == 0 then
   if player:get_param(258) >= 9  then
    if player:num_item(10178,1) >= 2 then
    if player:isenter_map() == 0 then
     player:remove_item(10178,2);
     player:randomthismap(58);
     player:alert(19,0,0,"您只有60分钟时间消灭副本里的怪物");
    else
     player:alert(10,0,0,"你刚退出副本,再次进入需要"..player:isenter_map().."秒");
     ontalk2106(npc,0,player,0);
    end
    else
    player:alert(10,0,0,"需2个破碎的时空卷轴才可进入");
    ontalk2106(npc,0,player,0);
    end
   else
    player:alert(10,0,0,"飞升等级9级以上才可进入");
    ontalk2106(npc,0,player,0);
   end

 else
  player:alert(10,0,0,"您正在押镖或押送灵兽,不能进入");
  ontalk2106(npc,0,player,0);
 end
end
Npc2106Funid =
{
[0] = ontalk2106;
[1] = ontalk2106_1;
[2] = ontalk2106_2;
[3] = ontalk2106_3;
[4] = ontalk2106_4;
[5] = ontalk2106_5;
[6] = ontalk2106_6;
[7] = ontalk2106_7;
[8] = ontalk2106_8;
[9] = ontalk2106_9;
}

function CreatureNpcFun(npc,event,player,funid)
 if Npc2106Funid[funid] ~= nil then
  Npc2106Funid[funid](npc,event,player);
 end
end

RegisterUnitEvent(2106,20,"ontalk2106")
RegisterUnitEvent(2106,29,"CreatureNpcFun")

请将以上代码区域的代码复制,用editplus或者LUA编辑器,另存为 九幽2106.lua
然后在烈焰私服MYSQL数据库
creature_proto表INSERT INTO `game`.`creature_proto` (`entry`, `minlevel`, `maxlevel`, `faction`, `minhealth`, `maxhealth`, `mana`, `scale`, `npcflags`, `attacktime`, `attacktype`, `mindamage`, `maxdamage`, `can_ranged`, `rangedattacktime`, `rangedmindamage`, `rangedmaxdamage`, `respawntime`, `armor`, `resistance1`, `resistance2`, `resistance3`, `resistance4`, `resistance5`, `resistance6`, `combat_reach`, `bounding_radius`, `auras`, `boss`, `money`, `invisibility_type`, `walk_speed`, `run_speed`, `fly_speed`, `extra_a9_flags`, `spell1`, `spell2`, `spell3`, `spell4`, `spell5`, `spell6`, `spell7`, `spell8`, `spell_flags`, `modImmunities`, `isTrainingDummy`, `guardtype`, `summonguard`, `spelldataid`, `vehicleid`, `rooted`, `minphysicsattack`, `maxphysicsattack`, `minphysicsguard`, `maxphysicsguard`, `minspellattack`, `maxspellattack`, `minspellguard`, `maxspellguard`, `mintaoattack`, `maxtaoattack`, `duck`, `right`, `brawn`, `luck`, `packweight`, `dressweight`, `interstrengthxp`, `extrahurt`, `extrarate`) VALUES ('2106', '0', '0', '0', '0', '0', '0', '0', '130', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0');
creature_staticspawns表INSERT INTO `game`.`creature_staticspawns` (`id`, `entry`, `Map`, `x`, `y`, `z`, `o`, `movetype`, `displayid`, `factionid`, `flags`, `bytes0`, `bytes1`, `bytes2`, `emote_state`, `npc_respawn_link`, `channel_spell`, `channel_target_sqlid`, `channel_target_sqlid_creature`, `standstate`, `death_state`, `mountdisplayid`, `slot1item`, `slot2item`, `slot3item`, `CanFly`, `phase`, `name`, `leader`, `questitem1`, `questitem2`, `questitem3`, `questitem4`, `questitem5`, `questitem6`) VALUES ('12122', '2106', '12', '123', '115', '1', '0', '0', '1023', '35', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '0', '1', '九幽海域传送员', '0', '0', '0', '0', '0', '0', '0');
 
搞定,一个九幽海域的NPC传送员就此诞生,需要重启后生效.
以上代码为www.yeyo6.com(老MAN,QQ:97078681页游咯原创发布),转载请注明出处,感谢
最新文章
· 蓝月传奇个人BOSS阿修罗神掉宝数据概述...
· 蓝月传奇野外BOSS通天霸主掉宝...
· 蓝月传奇野外BOSS雷炎蛛王掉宝数据...
· 蓝月传奇野外BOSS冰霜教王掉宝数据...
· 蓝月传奇野外BOSS魔龙教王掉宝数据概述...
· 蓝月传奇野外BOSS火龙王掉宝数据概述...
· 烈焰绿色版元宝活动之夺宝战场...
· 烈焰绿色版 7-25 18:00更新维护...
· 给你的烈焰私服增加一个定时刷怪的功能脚本...
· 烈焰服务端对角色进行相关属性操作的脚本命...
热门文章
· 烈焰游戏里神武官阶说明...
· 烈焰私服里战士的PK方法...
· 烈焰私服服务端里添加官方九幽海域传送员的...
· 烈焰SF新春贺礼···...
· 教程--烈焰私服里面添加鉴定大师NPC...
· 怒斩烈焰私服充值攻略...
· 烈焰私服的各种玩法...
· 烈焰私服的各种玩法(续)...
· 烈焰开服表私服里面装备.账号交易方法...
· 烈焰私服里防骗指南...
yeyo6.com背景图
2015-2018(c) www.YeY06.Com 烈焰私服 版权所有 盗版必究
*注释:本站所有信息,均来自互联网。请玩家仔细辨认游戏信息的真实性!与本站无关