Advertisement
kolton

Untitled

Nov 5th, 2011
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.37 KB | None | 0 0
  1. Unit.prototype.getStatEx = function (ID, subID) {
  2. subID = subID || 0;
  3.  
  4. switch (ID) {
  5. case 31:
  6. if (arguments.length < 2) {
  7. return this.getStat(31);
  8. }
  9.  
  10. break;
  11. case 92:
  12. case 194:
  13. return this.getStat(ID);
  14. }
  15.  
  16. var stats = this.getStat(-2);
  17.  
  18. if (stats[ID] && stats[ID][subID]) {
  19. return stats[ID][subID];
  20. } else {
  21. return 0;
  22. }
  23. }
  24.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement