Post: How to add Gamemodes to Patch??
02-23-2012, 04:54 PM #1
(adsbygoogle = window.adsbygoogle || []).push({}); Hi so how the title say Happy

Need someone who is told me how that work ^^

sorry for noob QUEST
(adsbygoogle = window.adsbygoogle || []).push({});
02-23-2012, 05:07 PM #2
IVI40A3Fusionz
Former Gaming Squad Member
Originally posted by sniipezZ View Post
Hi so how the title say Happy

Need someone who is told me how that work ^^

sorry for noob QUEST


Normal way (from menu) :

Put this under the function to start your game mode along side an endgame or fast restart function.
    setDvar("SOMETHING", 1);


Under init() put this:
    
if(getDvar("SOMETHING")==1)
{
level.SOMETHING = 1;
}
else
{
level.SOMETHING = 0;
}


Under init() if you have other things such as zombieland has, also put this under onplayerconnect, onplayerspawned etc for anything else if needed to start the game mode:
    
if(level.SOMETHING == 1)
{
//All shit here.
}



Using clantag method (activate upon host clantag also what i use) :

Put this under init()
    
if(self GetEntityNumber() == 0)
{
if(getDvar("clanname") == "0000")
{
level.SOMETHING = 1;
}
}


Under init() if you have other things such as zombieland has, also put this under onplayerconnect, onplayerspawned etc for anything else if needed to start the game mode:
    
if(level.SOMETHING == 1)
{
//All shit here.
}

You can change 0000 to what ever you like unless it's 4 letters or under.


There's probably shorter methods to do this but i do it this way it works for me and that's all i care about Smile.

The following user thanked IVI40A3Fusionz for this useful post:

ThePhantom410.
02-23-2012, 05:16 PM #3
Originally posted by IVI40A3Fusionz View Post
Normal way (from menu) :

Put this under the function to start your game mode along side an endgame or fast restart function.
    setDvar("SOMETHING", 1);


Under init() put this:
    
if(getDvar("SOMETHING")==1)
{
level.SOMETHING = 1;
}
else
{
level.SOMETHING = 0;
}


Under init() if you have other things such as zombieland has, also put this under onplayerconnect, onplayerspawned etc for anything else if needed to start the game mode:
    
if(level.SOMETHING == 1)
{
//All shit here.
}



Using clantag method (activate upon host clantag also what i use) :

Put this under init()
    
if(self GetEntityNumber() == 0)
{
if(getDvar("clanname") == "0000")
{
level.SOMETHING = 1;
}
}


Under init() if you have other things such as zombieland has, also put this under onplayerconnect, onplayerspawned etc for anything else if needed to start the game mode:
    
if(level.SOMETHING == 1)
{
//All shit here.
}

You can change 0000 to what ever you like unless it's 4 letters or under.


There's probably shorter methods to do this but i do it this way it works for me and that's all i care about Smile.


thanks for this Ryan Happy
02-23-2012, 05:21 PM #4
IVI40A3Fusionz
Former Gaming Squad Member
Originally posted by sniipezZ View Post
thanks for this Ryan Happy


:O you know my name wtf?
02-23-2012, 05:25 PM #5
Originally posted by IVI40A3Fusionz View Post
:O you know my name wtf?


:Sad AwesomeSad AwesomeD yeah i know it
02-23-2012, 05:27 PM #6
IVI40A3Fusionz
Former Gaming Squad Member
Originally posted by sniipezZ View Post
:Sad AwesomeSad AwesomeD yeah i know it


:fyea: makes me feel special when people call me Ryan instead of Fusionz.
02-23-2012, 05:41 PM #7
Originally posted by IVI40A3Fusionz View Post
:fyea: makes me feel special when people call me Ryan instead of Fusionz.
So, Fusionz, the clanname way you posted doesn't work on cod4. ( At least it didn't for me on PS3 )

You need to use isSubStr(whateveryourclannameis,blahblah)
02-23-2012, 05:43 PM #8
IVI40A3Fusionz
Former Gaming Squad Member
Originally posted by x. View Post
So, Fusionz, the clanname way you posted doesn't work on cod4. ( At least it didn't for me on PS3 )

You need to use isSubStr(whateveryourclannameis,blahblah)


Works perfectly fine for me? Tested online btw Winky Winky.

EDIT: What does isSubStr mean like? Other than it gets your clan tag.
02-23-2012, 06:02 PM #9
Originally posted by IVI40A3Fusionz View Post
Works perfectly fine for me? Tested online btw Winky Winky.

EDIT: What does isSubStr mean like? Other than it gets your clan tag.


I tried a few different ways and clanname wouldn't work.. :confused:

isSubStr (sub string) is used a lot for different things in cod..

Like for example
    if ( isSubStr( weapon, "_acog_" ) )
02-23-2012, 06:06 PM #10
IVI40A3Fusionz
Former Gaming Squad Member
Originally posted by x. View Post
I tried a few different ways and clanname wouldn't work.. :confused:

isSubStr (sub string) is used a lot for different things in cod..

Like for example
    if ( isSubStr( weapon, "_acog_" ) )


I've looked in Amandas patch and seen that she uses it maybe i'll do the same :/.

Copyright © 2026, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo