Page 1 of 1

[Orion] Looking for a Claim script

Posted: Sat Aug 05, 2023 12:59 pm
by Alibaster
Does anyone have a script to claim all the corpses at your feet for Orion? I would toggle it on after looting is done I can just clean up the area around me with a simple script. I have no knowledge of scripting so any help would be appreciated. Thank you

Re: [Orion] Looking for a Claim script

Posted: Tue May 14, 2024 6:46 pm
by Valthonis
not sure if this is exactly what you want, but this is what i use and just spam the hotkey i made for it. and i just use this in UOS

Code: Select all

if @findtype 0x2006 'any' 'ground' 1 2
  msg '[claim'
  waitfortarget 15000
  target 'found'
  pause 200
  canceltarget
else
  sysmsg 'No corpse found.'
endif

Re: [Orion] Looking for a Claim script

Posted: Wed May 15, 2024 2:11 am
by slimans
This is what i use in Orion. For it to work you need for the claimAll.oajs to be highlighted on the sscripts from folder window. You just set a hotkey for it and it will claim every corpse in range. If you cant get it to work i can send you the file, just hit me up ingame or on discord Slimans#3175


function claimAll() {
const entities = Orion.FindTypeEx(
"0x2006",
"any",
"ground",
"inlos|ignoreself",
"8"
).sort(function (a, b) {
return a.Distance() - b.Distance();
});
Orion.CancelTarget();
if (entities.length > 0) {
entities.forEach(function (entity) {
if (!Orion.HaveTarget()) {
Orion.Say("[claim");
}
if (Orion.WaitForTarget("1000")) {
Orion.TargetObject(entity.Serial());
}
Orion.Wait("250");
});
}
Orion.CancelTarget();
}

Re: [Orion] Looking for a Claim script

Posted: Mon May 20, 2024 12:11 pm
by gilga
thanks for this slimans, it works great and I do like a clean dungeon. how do i set a hot key for it please.

Re: [Orion] Looking for a Claim script

Posted: Wed May 22, 2024 2:10 am
by slimans
Hotkeys>Scripts "run script claimAll" and pick a key. To effectively run the script after this claimAll..oajs just needs to be highlighted in the "scripts from folder" tab of the scripts tab(not sure why but it wont work without it being highlighted there)