Olymps Posted December 18, 2014 Posted December 18, 2014 Hello ppl of mxc i was wonder if someone can help me by showing/teaching how can i add an progress bar into an npc via Java scripts :) Quote
0 Tessa Posted December 18, 2014 Posted December 18, 2014 Progress bar? An example.. like screenshot? Quote
0 Olymps Posted December 18, 2014 Author Posted December 18, 2014 (edited) Progress bar? An example.. like screenshot? https://encrypted-tbn3.gstatic.com/images?q=tbn:ANd9GcSd2Z55NF3FteEOrTAJtydm-Lk6cH_H3Oa2bvIonolNh-YVOaZV something like this into a npc!! Eg : min cap mobs killed 0 and max cap mobs killed 1k and you've killed around 600 mobs so the bar will showing your progress at about 60% Edited December 18, 2014 by Olymps Quote
0 Tessa Posted December 18, 2014 Posted December 18, 2014 Which version you need that for? Interlude, H5 etc? Quote
0 Olymps Posted December 18, 2014 Author Posted December 18, 2014 Which version you need that for? Interlude, H5 etc? h5 mate Quote
0 Tessa Posted December 18, 2014 Posted December 18, 2014 I was wondered how to do this, and here is the result: http://prntscr.com/5iagza I've used the hp image from the client side, then i get the percentage value of my current hp... This is the html <table bgcolor="000000" width=100> <tr> <td><img src="L2UI.HP" width="%currenthppercent%" height=16></td> </tr> </table> %currenthppercent% is calculated like this: 100 * currentHp / maxHp I don't have H5's core atm but the process is the same, i suppose :lol: Quote
0 Olymps Posted December 18, 2014 Author Posted December 18, 2014 I was wondered how to do this, and here is the result: http://prntscr.com/5iagza I've used the hp image from the client side, then i get the percentage value of my current hp... This is the html <table bgcolor="000000" width=100> <tr> <td><img src="L2UI.HP" width="%currenthppercent%" height=16></td> </tr> </table> %currenthppercent% is calculated like this: 100 * currentHp / maxHp I don't have H5's core atm but the process is the same, i suppose :lol: so i should do it on html and not on script right? or still i need to create a script ? Quote
0 Tessa Posted December 18, 2014 Posted December 18, 2014 so i should do it on html and not on script right? or still i need to create a script ? You need to get the percentage value from the script... 100 * killedMobs / requiredKills This will return the value that you should use as a width value for the image For example: If you have killed 50 mobs, and the mobs you need to kill are 100, this will return 50% and the width of the image becomes 50 Quote
0 Olymps Posted December 18, 2014 Author Posted December 18, 2014 You need to get the percentage value from the script... 100 * killedMobs / requiredKills This will return the value that you should use as a width value for the image For example: If you have killed 50 mobs, and the mobs you need to kill are 100, this will return 50% and the width of the image becomes 50 Aha will try mate!! thank you very much appretiate it :) hope i'll figure it out :) have a nice day! Quote
0 Tessa Posted December 18, 2014 Posted December 18, 2014 Aha will try mate!! thank you very much appretiate it :) hope i'll figure it out :) have a nice day! You too, and good luck! :) Quote
Question
Olymps
Hello ppl of mxc i was wonder if someone can help me by showing/teaching how can i add an progress bar into an npc via Java scripts :)
9 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.
Note: Your post will require moderator approval before it will be visible.