海盗王添加黑龙获取职业65BB+27武器教程:
1、打开服务端resource\script\calculate\exp_and_level.lua
2、查找function ShareTeamExp ( dead , team_atker , dead_exp , The_Killer)
3、直接在后面回车加入:Drop_Johnny(dead , The_Killer)
4、将下面一段脚本添加到文件exp_and_level.lua最后
- <font face="微软雅黑" size="3" color="#008000">function Drop_Johnny(dead,atk)
- local MonsterID = GetChaID(dead)
- if MonsterID == 789 then
- local Item_CanGet = GetChaFreeBagGridNum ( atk )
- if Item_CanGet >1 then
- local item
- local item_id
- local item_name
- local Stone_Type = {} --宝石类型如果是个位数的一定要在前面加0 比如玛瑙石4就要变成04 0不可以去掉
- local Stone_Lv = {}
- local job = GetChaAttr(atk,ATTR_JOB)
- if job == 9 then --双剑士
- item_id = 0776
- Stone_Type[0] = 04 --玛瑙
- Stone_Type[1] = 12 --炎玉
- Stone_Type[2] = 25 --辉耀
- Stone_Lv[0] = 9 --玛瑙等级
- Stone_Lv[1] = 9 --类推
- Stone_Lv[2] = 9 --类推
- elseif job == 8 then --巨剑士
- item_id = 0773
- Stone_Type[0] = 12
- Stone_Type[1] = 13
- Stone_Type[2] = 25
- Stone_Lv[0] = 9
- Stone_Lv[1] = 9
- Stone_Lv[2] = 9
- elseif job == 12 then --狙击
- item_id = 0784
- Stone_Type[0] = 11
- Stone_Type[1] = 13
- Stone_Type[2] = 28
- Stone_Lv[0] = 9
- Stone_Lv[1] = 9
- Stone_Lv[2] = 9
- elseif job == 13 then --圣职
- item_id = 0788
- Stone_Type[0] = 8
- Stone_Type[1] = 16
- Stone_Type[2] = 27
- Stone_Lv[0] = 9
- Stone_Lv[1] = 9
- Stone_Lv[2] = 9
- elseif job == 14 then --封印
- item_id = 802
- Stone_Type[0] = 8
- Stone_Type[1] = 16
- Stone_Type[2] = 27
- Stone_Lv[0] = 9
- Stone_Lv[1] = 9
- Stone_Lv[2] = 9
- elseif job == 16 then --航海
- item_id = 0792
- Stone_Type[0] = 8
- Stone_Type[1] = 16
- Stone_Type[2] = 27
- Stone_Lv[0] = 9
- Stone_Lv[1] = 9
- Stone_Lv[2] = 9
- end
- local cha_name = GetChaDefaultName ( atk )
- local item_count = CheckBagItem( atk , item_id )
- if item_count >= 1 then
- Notice ( cha_name.."杀死了黑龙,但是由于该角色背包中已有职业武器,所以系统自动将奖励转换为5000W金钱奖励!")
- AddMoney(atk, 0, 50000000);
- else
- GiveItem (atk,0,item_id,1,22)
- item_name = GetItemName(item_id)
- item = GetChaItem2(atk,2,item_id)
- local Num = GetItemForgeParam ( item, 1 )
- Num = SetNum_Part1 ( Num , 3 ) --开三槽
- Num = SetNum_Part2 ( Num , Stone_Type[0] ) --第一槽宝石
- Num = SetNum_Part3 ( Num , Stone_Lv[0] ) --宝石等级
- Num = SetNum_Part4 ( Num , Stone_Type[1] ) --类推
- Num = SetNum_Part5 ( Num , Stone_Lv[1] ) --类推
- Num = SetNum_Part6 ( Num , Stone_Type[2] ) --类推
- Num = SetNum_Part7 ( Num , Stone_Lv[2] ) --类推
- local Check_SetItemForgeParam = SetItemForgeParam( item , 1 , Num )
- if Check_SetItemForgeParam == 0 then
- SystemNotice( role , "设置精炼属性失败")
- return
- end
- RefreshCha(atk)
- Notice( cha_name.."杀死了黑龙,获得了+27"..item_name.."奖励!")
- end
- else
- AddMoney(atk, 0, 50000000)
- Notice ( cha_name.."杀死了黑龙,但是由于该角色背包中无剩余空间,所以系统自动将奖励转换为5000W金钱奖励!")
- end
- end
- end</font>
复制代码 效果:杀死黑龙后,武器自动进入背包,如背包空间已满或者背包已存在该武器则转换为5000W海盗币,组队时为杀死黑龙的角色获得迷刃。
|