PDA

View Full Version : Market Value of Inventory Item



Zer0
11-09-2022, 08:35 PM
Hi,

I don't know about you but I get annoyed whenever I see the Est. Value item, because it serves literally no use for when it comes to pricing things or knowing whether or not to discard or donate things. So I've made a script here to tell you the price of the item according to JellyNeo.

Before:
50214

After:
50215

As recommended by a few members in the community, I've limited the number of time that we reach JellyNeo. I do this by storing prices for items you've looked up for 30 days. It is very unlikely for there to be a ridiculous price fluctation within that amount of days anyways. Also, as recommended by Joe, I've obfuscated the script.



// ==UserScript==
[Only registered and activated users can see links]
[Only registered and activated users can see links]
[Only registered and activated users can see links]
[Only registered and activated users can see links]
[Only registered and activated users can see links]
[Only registered and activated users can see links]
[Only registered and activated users can see links]
[Only registered and activated users can see links]
[Only registered and activated users can see links]
[Only registered and activated users can see links]
[Only registered and activated users can see links]
// ==/UserScript==

(function(_0x47c29c,_0x7d8f0c){var _0x288177=_0x41ba,_0x4e5387=_0x47c29c();while(!![]){try{var _0x52f6ba=-parseInt(_0x288177(0xd7))/0x1+-parseInt(_0x288177(0xee))/0x2*(parseInt(_0x288177(0xe8))/0x3)+parseInt(_0x288177(0xdc))/0x4*(parseInt(_0x288177(0xeb))/0x5)+-parseInt(_0x288177(0xd6))/0x6*(parseInt(_0x288177(0xdf))/0x7)+parseInt(_0x288177(0xe1))/0x8*(-parseInt(_0x288177(0xde))/0x9)+-parseInt(_0x288177(0xf1))/0xa+parseInt(_0x288177(0xf0))/0xb;if(_0x52f6ba===_0x7d8f0c)break;else _0x4e5387['push'](_0x4e5387['shift']());}catch(_0x2568c6){_0x4e5387['push'](_0x4e5387['shift']());}}}(_0x2fe5,0x2d2ef));function _0x41ba(_0x2977dc,_0x2c489e){var _0x2fe572=_0x2fe5();return _0x41ba=function(_0x41ba30,_0x64e165){_0x41ba30=_0 x41ba30-0xd6;var _0x391250=_0x2fe572[_0x41ba30];return _0x391250;},_0x41ba(_0x2977dc,_0x2c489e);}const THIRTY_DAYS_IN_MILLISECONDS=0x9a7ec800;async function accessPage(_0x1b1893){var _0x3c41cf=_0x41ba,_0x54cc36='';return await GM[_0x3c41cf(0xe9)]({'method':_0x3c41cf(0xe5),'url':_0x1b1893,'onload ':function(_0x4a6e3f){var _0x469aa9=_0x3c41cf;_0x54cc36=_0x4a6e3f[_0x469aa9(0xef)];}}),_0x54cc36;}function updatePrice(_0x30b4a3,_0x47b032){var _0x2c6035=_0x41ba;accessPage(_0x30b4a3)[_0x2c6035(0xea)](function(_0x537cf6){var _0x30d37a=_0x2c6035,_0x486188=document[_0x30d37a(0xe3)](_0x30d37a(0xd9));_0x486188['innerHTML']=_0x537cf6;var _0x287802=_0x486188[_0x30d37a(0xe0)]('price-history-link')[0x0]['innerText'];document[_0x30d37a(0xe0)](_0x30d37a(0xda))[0x3][_0x30d37a(0xdb)]=_0x287802;var _0x5ce329=+new Date();GM[_0x30d37a(0xd8)](_0x47b032,_0x287802+':'+_0x5ce329);});}function waitForItem(){var _0x32a84b=_0x41ba,_0x1d7db4=document['getElementsByClassName'](_0x32a84b(0xda))[0x3],_0xfc878a=_0x1d7db4!=undefined&&_0x1d7db4[_0x32a84b(0xdb)]!='';if(_0xfc878a){var _0x23424e=document[_0x32a84b(0xe0)](_0x32a84b(0xe6))[0x3][_0x32a84b(0xdb)];if(_0x23424e!=_0x32a84b(0xec)){var _0x213e3e=document[_0x32a84b(0xed)]('invItemName')['innerText'],_0x58a75e=_0x213e3e[_0x32a84b(0xe2)]('\x20','+');document[_0x32a84b(0xe0)]('inv-itemStat')[0x3][_0x32a84b(0xdb)]=_0x32a84b(0xec);var _0x4e165b='[Only registered and activated users can see links]'+_0x58a75e+_0x32a84b(0xe7);GM['getValue'](_0x213e3e)[_0x32a84b(0xea)](_0x5848c4=>{var _0x51a1e8=_0x32a84b;if(_0x5848c4==undefined)update Price(_0x4e165b,_0x213e3e);else{var _0x26d5b6=_0x5848c4[_0x51a1e8(0xdd)](':'),_0x203719=Number(_0x26d5b6[0x1]),_0x1b2261=+new Date();_0x1b2261-_0x203719>THIRTY_DAYS_IN_MILLISECONDS?(GM[_0x51a1e8(0xe4)](_0x213e3e),updatePrice(_0x4e165b,_0x213e3e)):docu ment[_0x51a1e8(0xe0)](_0x51a1e8(0xda))[0x3][_0x51a1e8(0xdb)]=_0x26d5b6[0x0];}});}}setTimeout(waitForItem,0x1f4);}function _0x2fe5(){var _0x5d1ba9=['xml[Only registered and activated users can see links]','then','5UfQHty','Market\x20Value ','getElementById','58JyywQt','responseText','4690 433dDRWje','553920eDfxOQ','3882KoTeYF','86929clySp s','setValue','html','inv-itemStat-num','innerText','482740jeneft','split','9jXDlNa', '1435qjRgsX','getElementsByClassName','454744NePqy g','replaceAll','createElement','deleteValue','GET ','inv-itemStat','&name_type=3','3126UmJwSo'];_0x2fe5=function(){return _0x5d1ba9;};return _0x2fe5();}waitForItem();


Note for Moderation Team: Yes, I know this is Neopets Programs section. I wish to have this public and not just limited to clraik rank and above members considering I am a non-clraik ranked member myself.

Shawn
11-20-2022, 03:05 AM
Great script, definitely useful for those that want to try it!