Sick Gaming
Call of Duty: World at War: How to Add This Code.. (Tutorial) - Printable Version

+- Sick Gaming (https://sickgaming.net)
+-- Forum: Sick Gaming Community (https://sickgaming.net/forum-1.html)
+--- Forum: Lounge (https://sickgaming.net/forum-8.html)
+--- Thread: Call of Duty: World at War: How to Add This Code.. (Tutorial) (/thread-116987.html)



Call of Duty: World at War: How to Add This Code.. (Tutorial) - xSicKxBot - 10-06-2010

Call of Duty: World at War: How to Add This Code..

Game: Call of Duty: World at War

Description

Info:
Hello I have some coding but i don't understand were it goes? If someone could tell me were to put the pieces of code that would be amazing and would earn a cookie. Please note I'm using "MasterDovers" NZP and that were I would like to add my code. Another thing is how do I bind it because I don't get it. Thankyou.

Outcome:

To be able to toggle a model "Barrel"
From human > Barrel and vise versa.

Coding

Change To Barrel;

Code: doModelChange() { while(1) { if(getdvar("player_meleeWidth") != "999") { self setClientDvar( "cg_thirdPerson", "0" ); } else if(getdvar("player_meleeWidth") != "998") { self setModel( "global_explosive_barrel_japanese" ); self setClientDvar( "cg_thirdPerson", "1" ); } wait 0.4; } }

Change back to Human

Code: doModelChange() { while(1) { if(getdvar("player_bayonetRange") != "2") { self setModel( "destructible_type94truck" ); self setClientDvar( "cg_thirdPerson", "1" ); self setClientDvar( "cg_thirdPersonRange", "250" ); } else if(getdvar("player_bayonetRange") != "1") { self setModel( "generic_human" ); self setClientDvar( "cg_thirdPerson", "0" ); } } }
The Toggle;

Code: bind "toggle player_meleeWidth 999 998"

If you can help me please add me on AIM:
Woookie778