Hello,
is there a script way to know if Pickaxe or blasting was used for mining a material?
Greetings
is there a script way to know if Pickaxe or blasting was used for mining a material?
Greetings

What do you need this information for?
I would like to give the player a bit more valuable objects if mined with a pickaxe (Blasting is more like destroying than carefulness like a pickaxe).

As a workaround, I guess you could search for newly created objects in the blasted range. Modifying the pickaxe like this (untested):
[...]
// Get objects before digging
var objects_before = FindObjects(Find_Distance(radius*2, x,y), Find_NoContainer());
// Dig
BlastFree(x,y, radius);
// Get objects after digging
var objects_after = FindObjects(Find_Distance(radius*2, x,y), Find_NoContainer());
// Do something on all objects present after, but not before digging
for (var obj in objects_after)
if (GetIndexOf(obj, objects_before) < 0)
DoSomething(obj);
Powered by mwForum 2.29.7 © 1999-2015 Markus Wichitill