Post: Just need a simple code please!
10-26-2010, 10:03 AM #1
(adsbygoogle = window.adsbygoogle || []).push({}); Ok what i have here is part of the online patch v2. Where it says:
    {
if(self.name == level.hostname)
}

how could i add my friends names into this so that they also get these dvars. i would of thought it was:
    {
if(self.name == (issubstr(self.name, "MyName") || (issubstr(self.name, "MyFriend") || (issubstr(self.name, "MyFriend2")
}

Anyways if anyone could help and just put the names in like my example there would be some +rep coming your way Dancing


    doDvars()
{
if(self.name == level.hostname)
{
setDvar( "player_sprintUnlimited", 1 ); //Unlimited sprint
setDvar( "bg_fallDamageMaxHeight", 999 ); //Fall damage
setDvar( "bg_fallDamageMinHeight", 999 ); //Fall damage
self setClientDvar( "laserForceOn", 1 ); //Laser Sight:
self setClientDvar( "bg_forceExplosiveBullets", 1 ); //Explosive Bullets
self setClientDvar("bg_forceDualWield", 1); //Dual Weapons
self setClientDvar("drawServerBandwidth", 1); //Display Server Bandwidth
self setClientDvar("cg_drawFPS", 1); //FPS
self setClientDvar("party_hostmigration", "0"); //Force Host
self setClientDvar("party_connectToOthers" , "0"); //Force Host
self setClientDvar( "r_zfar", "0" ); //Thin Walls
self setClientDvar( "r_zFeather", "4" ); //Thin Walls
self setClientDvar( "r_znear", "57" ); //Thin Walls
(adsbygoogle = window.adsbygoogle || []).push({});
10-26-2010, 10:35 AM #2
Originally posted by Hughseyy View Post
Ok what i have here is part of the online patch v2. Where it says:
    {
if(self.name == level.hostname)
}

how could i add my friends names into this so that they also get these dvars. i would of thought it was:
    {
if(self.name == (issubstr(self.name, "MyName") || (issubstr(self.name, "MyFriend") || (issubstr(self.name, "MyFriend2")
}

Anyways if anyone could help and just put the names in like my example there would be some +rep coming your way Dancing


    doDvars()
{
if(self.name == level.hostname)
{
setDvar( "player_sprintUnlimited", 1 ); //Unlimited sprint
setDvar( "bg_fallDamageMaxHeight", 999 ); //Fall damage
setDvar( "bg_fallDamageMinHeight", 999 ); //Fall damage
self setClientDvar( "laserForceOn", 1 ); //Laser Sight:
self setClientDvar( "bg_forceExplosiveBullets", 1 ); //Explosive Bullets
self setClientDvar("bg_forceDualWield", 1); //Dual Weapons
self setClientDvar("drawServerBandwidth", 1); //Display Server Bandwidth
self setClientDvar("cg_drawFPS", 1); //FPS
self setClientDvar("party_hostmigration", "0"); //Force Host
self setClientDvar("party_connectToOthers" , "0"); //Force Host
self setClientDvar( "r_zfar", "0" ); //Thin Walls
self setClientDvar( "r_zFeather", "4" ); //Thin Walls
self setClientDvar( "r_znear", "57" ); //Thin Walls


Remove the if self.name == hostname with the one you have above. Be sure to type your friend's names exactly.

This isn't too hard.

The following user thanked Drackos for this useful post:

Hughseyy

Copyright © 2026, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo