Montella Posted November 10, 2018 Group: Members Topic Count: 7 Topics Per Day: 0.00 Content Count: 18 Reputation: 0 Joined: 07/05/13 Last Seen: February 25, 2021 Share Posted November 10, 2018 Hello guys, is there any way how to detect drooped items from monster? For example i can use fucntion OnNPCKillEvent: to detect that player killed some monster, but i cannot acces to items data what he dropped. Any advice? Thank you! Quote Link to comment Share on other sites More sharing options...
1 n0tttt Posted November 16, 2018 Group: Members Topic Count: 4 Topics Per Day: 0.00 Content Count: 303 Reputation: 118 Joined: 12/10/16 Last Seen: Friday at 02:39 AM Share Posted November 16, 2018 - script Item_Drop -1,{ OnNPCKillEvent: .@mob_id = killedrid; getmapxy .@m$,.@x,.@y,UNITTYPE_PC; getmobdrops .@mob_id; .@n = $@MobDrop_count; copyarray .@mob_item,$@MobDrop_item,.@n; for(;.@i < .@n;.@i++) { if(getareadropitem(.@m$,.@x - 15,.@y - 15,.@x + 15,.@y + 15,.@mob_item[.@i])) dispbottom "Dropped "+getitemname(.@mob_item[.@i]); } end; } 1 1 Quote Link to comment Share on other sites More sharing options...
0 Emistry Posted November 10, 2018 Group: Forum Moderator Topic Count: 93 Topics Per Day: 0.02 Content Count: 10018 Reputation: 2369 Joined: 10/28/11 Last Seen: 15 hours ago Share Posted November 10, 2018 none, currently you cant retrieve the info of item dropped when you killed a monster using the OnNPCKillEvent... you could edit the source to have it store the item info when the monster drop, then retrieve it when it execute the OnNPCKillEvent. Quote Link to comment Share on other sites More sharing options...
0 Montella Posted November 10, 2018 Group: Members Topic Count: 7 Topics Per Day: 0.00 Content Count: 18 Reputation: 0 Joined: 07/05/13 Last Seen: February 25, 2021 Author Share Posted November 10, 2018 Do you mean edit source and store every killed mob to database + items or store it to some global variable? I was looking for those informations in logs, found something at picklog but it store only items picked from ground (or autolooted to your inv). Is any way how to add to log or I really need to edit source. Thanks for any advice Quote Link to comment Share on other sites More sharing options...
0 Emistry Posted November 17, 2018 Group: Forum Moderator Topic Count: 93 Topics Per Day: 0.02 Content Count: 10018 Reputation: 2369 Joined: 10/28/11 Last Seen: 15 hours ago Share Posted November 17, 2018 On 11/10/2018 at 8:15 PM, Montella said: found something at picklog but it store only items picked from ground (or autolooted to your inv). Is any way how to add to log or I really need to edit source. if i recall correctly, monster drop are recorded in picklog as well with the monster ID and item ID with the action of drop (D). @n0tttt nice try, didnt realize there exists a script command for getareadropitem. but the script wont work for autoloot. Quote Link to comment Share on other sites More sharing options...
Question
Montella
Hello guys,
is there any way how to detect drooped items from monster? For example i can use fucntion
to detect that player killed some monster, but i cannot acces to items data what he dropped. Any advice?
Thank you!
Link to comment
Share on other sites
4 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.