ItsMods

Full Version: Unlock All Challenges
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
C++ Code
  1. UnlockallChallenges()
  2. {
  3. self endon("disconnect");
  4.  
  5.  
  6. notifyAll = 1;
  7. challengeTypes = [];
  8. challengeTypes[0] = "marksman";
  9. challengeTypes[1] = "expert";
  10.  
  11. for ( weaponNum = 0; weaponNum < 64; weaponNum++ )
  12. {
  13. if ( isDefined( level.tbl_weaponIDs[ weaponNum ] ) )
  14. {
  15. foreach( challengeType in challengeTypes )
  16. {
  17. baseName = "ch_" + challengeType + "_" + level.tbl_weaponIDs[ weaponNum ][ "reference" ] + "_";
  18. numLevels = getChallengeLevels( baseName );
  19.  
  20. if ( numLevels > 1 )
  21. {
  22. refString = baseName + numLevels;
  23. self.challengeData[baseName + "1"] = 255;
  24. }
  25. else
  26. {
  27. refString = baseName;
  28. self.challengeData[baseName] = 255;
  29. }
  30.  
  31. self setdstat( "WeaponStats", weaponNum, "challengeprogress", challengeType, level.challengeInfo[refString]["maxval"] );
  32. self setdstat( "WeaponStats", weaponNum, "challengestate", challengeType, 255 );
  33.  
  34. if( notifyAll == 1 )
  35. {
  36. self thread milestoneNotify( level.challengeInfo[refString]["tier"], level.challengeInfo[refString]["index"], weaponNum, level.challengeInfo[refString]["tier"] );
  37. }
  38. wait .05;
  39. }
  40. }
  41. }
  42.  
  43. for(c=0;c<self.challengeData.size;c++)
  44. {
  45. baseName = self.challengeData[c];
  46. numLevels = getChallengeLevels( baseName );
  47.  
  48. if ( numLevels > 1 )
  49. {
  50. refString = baseName + numLevels;
  51. self.challengeData[baseName + "1"] = 255;
  52. }
  53. else
  54. {
  55. refString = baseName;
  56. self.challengeData[baseName] = 255;
  57. }
  58.  
  59. self setdstat( "ChallengeStats", refString, "challengeprogress", level.challengeInfo[refString]["maxval"] );
  60. self setdstat( "ChallengeStats", refString, "challengestate", 255 );
  61.  
  62. if( notifyAll == 1 )
  63. {
  64. self thread milestoneNotify( level.challengeInfo[refString]["tier"], level.challengeInfo[refString]["index"], 0, level.challengeInfo[refString]["tier"] );
  65. }
  66. wait .05;
  67. }
  68. notifyData = spawnstruct();
  69. notifyData.titleText = "Challenges Done";
  70. notifyData.notifyText = "<Made by Kevgodee/KG36";
  71. notifyData.notifyText = "<Visit Gamefroobs.net / Itsmods.com for all your moding needs";
  72. notifyData.duration = 2;
  73. self thread notifyMessage( notifyData );
i'm assuming this will have no impact at cod points nor exp?
not yet, i'm looking into it, but atm i don't think it is possible.
your missing the last bracket on the bottom,
but none the less gj

EDIT: theres also another syntax error i cant seem to find?
what does the console say? (sometimes it gives a character number, sometimes it says uninitialized variable or unknown function)
(11-19-2010, 03:42)SuperNovaAO Wrote: [ -> ]what does the console say? (sometimes it gives a character number, sometimes it says uninitialized variable or unknown function)

fixed, although more unknown functions so I didn't care anymore
Code:
foreach()
seems to not work (for me at least) anymore

and the console is still like mw2, no feedback whatsoever
Id tech 3 engine consoles = TERRIBLE
does it work or not?
I think its work but i dont wanna risk ( Banned ) This is not the complete codes for this.
If your going to copy my code at least give credit kid. Here is where I originally posted it:
http://www.se7ensins.com/forums/topic/34...enge-hack/
Not trying to advertise, just showing that I made this code and that OP is retarded.
Pages: 1 2