![]() |
Need help with some cool stuff - Printable Version +- SphereCommunity (https://forum.spherecommunity.net) +-- Forum: Sphere 0.56d (/Forum-Sphere-0-56d) +--- Forum: General Help (/Forum-General-Help) +--- Thread: Need help with some cool stuff (/Thread-Need-help-with-some-cool-stuff) |
Need help with some cool stuff - escribano - 11-18-2012 03:32 PM Hello everyone, first of all this is my first topic and i want to start with some cool stuff.. So, lets go. Im scripting a integration between shard and website... its a socket connection trough PHP and sphere, with an account and start execute any sphere command by PHP. Ok it's ready and it's working! ![]() But now, i decided to make a web-papperdoll to my shard and there is where my problem begins... I used a php code that i send 2 fields on $_GET (ids,hues) to the file and the papperdoll is printed on the website using the .mul's files of UO. (It's a very old code, but still working) Usage exemple: (12 is the male gump id of papperdol, and 33770 is the HUE color) <img src="papperdoll.php?index=12&hue=33770" /> Ok, i 've made a script to sphere that in all world save, a mySQL table will be updated with the online player papperdolls itens, so i created a table to store de "player uid", "item id", "hue", "description". [FUNCTION update_papperdoll] db.connect db.query "delete from <def.db_players> where uid = '<uid>'" for x 1 24 if (<findlayer.<local.x>.id> != 0) db.query "insert into players (uid, id, hue, description) values ('<uid>', '<findlayer.<local.x>.id>', '<findlayer.<local.x>.color>', '<findlayer.<local.x>.name>')" endif endfor It's wrong, i need to get the relative gump id of the item to store on the DB cuz if i get the <findlayer.<local.x>.id> of a plate mail i'll get "01415" but i need the gump id "5141"... Someone understand the problem? sorry about my poor english! Many Thanks! RE: Need help with some cool stuff - escribano - 11-19-2012 06:12 AM I've found some good information on this link! http://uo.stratics.com/heptazane/fileformats.shtml#1.0 I still trying! thx RE: Need help with some cool stuff - Shaklaban - 11-19-2012 07:21 AM use '<eval <findlayer.<local.x>.id>>' instead of '<findlayer.<local.x>.id>' RE: Need help with some cool stuff - escribano - 11-20-2012 03:03 AM Thanks for help!!!! It works!!! here is the first picture taken from my system ![]() Written in PHP, using .mul files from my shard. As u can see, it works with HUES custom colors and custom gumps ![]() Thanks! ANother one.... now with other gump ![]() Now added transparency to the background! (the red background is the HTML background) RE: Need help with some cool stuff - darksun84 - 11-20-2012 06:59 AM very nice ![]() RE: Need help with some cool stuff - escribano - 11-20-2012 09:08 AM Thanks Darksun84!!!! |