Premium Mano 22 Posted August 22, 2015 Premium Share Posted August 22, 2015 hey all i have a problem if moon drop event is on lvl 105 can have the box from wild dog i had made a level_limit in the quest but when i did it nothing is dropped from all monsters here is my quest quest etc_event begin state start begin when kill with game.get_event_flag("etc_event") == 1 begin local level = pc.get_level() local rate = pc.getqf("rate") local limit = tonumber(get_mob_level[npc.get_race()]) local s = number(1, 100) if level < limit+11 then local drop = number(1,rate) if s <= 10 then game.drop_item(50011) elseif s <= 50 then game.drop_item(50011) end end end end end waiting for your help kind regards Link to comment Share on other sites More sharing options...
Aerrow 41 Posted August 22, 2015 Share Posted August 22, 2015 Try this: quest etc_event begin state start begin when kill with game.get_event_flag("etc_event") == 1 begin local level = pc.get_level() local rate = pc.getqf("rate") local limit = get_mob_level(npc.get_race()) local s = number(1, 100) if level < limit+11 then local drop = number(1,rate) if s <= 10 then game.drop_item(50011) elseif s <= 50 then game.drop_item(50011) end end end end end Link to comment Share on other sites More sharing options...
Premium Mano 22 Posted August 23, 2015 Author Premium Share Posted August 23, 2015 Try this: quest etc_event begin state start begin when kill with game.get_event_flag("etc_event") == 1 begin local level = pc.get_level() local rate = pc.getqf("rate") local limit = get_mob_level(npc.get_race()) local s = number(1, 100) if level < limit+11 then local drop = number(1,rate) if s <= 10 then game.drop_item(50011) elseif s <= 50 then game.drop_item(50011) end end end end end thanks but i had fixed it Link to comment Share on other sites More sharing options...
pfanner 2 Posted August 23, 2015 Share Posted August 23, 2015 Mano can you please share with us how did you fix that, it looks a good type of questcan you show us please? Link to comment Share on other sites More sharing options...
Premium Mano 22 Posted August 23, 2015 Author Premium Share Posted August 23, 2015 quest mano_event begin state start begin when kill with game.get_event_flag("mano_drop") == 1 and not npc.is_pc() begin local s = number(1,250) if s == 1 then game.drop_item_with_ownership("50011",1) end end end end just use this it is simple than the first one Link to comment Share on other sites More sharing options...
pfanner 2 Posted August 23, 2015 Share Posted August 23, 2015 but in that caseif a player lv 105 kill a wild dog , will drop a boxhow did u fix that problem? Link to comment Share on other sites More sharing options...
PiK90 9 Posted August 23, 2015 Share Posted August 23, 2015 If you use 40k, you already have the function npc.get_level(), as i remember. And you just have to do something like this: if pc.get_level() - npc.get_level() < 10 then x = number(1, 100) if x < 10 then --drop item end end Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now