Login x
User Name:
Password:
Social Links Facebook Twitter YouTube Steam RSS News Feeds

Members Online

»
0 Active | 103 Guests
Online:

LATEST FORUM THREADS

»
CoD: Battle Royale
CoD+UO Map + Mod Releases
Damaged .pk3's
CoD Mapping
heli to attack ai
CoD4 SP Mapping

Forums

»

Welcome to the MODSonline.com forums. Looking for Frequently Asked Questions? Check out our FAQs section or search it out using the SEARCH link below. If you are new here, you may want to check out our rules and this great user's guide to the forums and the website.
For more mapping and modding information, see our Wiki: MODSonWiki.com

Jump To:
Forum: All Forums : Call of Duty 2
Category: CoD2 Scripting
Scripting and coding with Call of Duty 2.
Moderators: foyleman, Foxhound, Mystic, StrYdeR, batistablr, Welshy, DrBiggzz, supersword, playername
Latest Posts
Subscribed Posts
Search
Restricted Access Topic is Locked
Page
Next Page
subscribe
Author Topic: Server error
Sense
General Member
Since: Jun 17, 2011
Posts: 12
Last: Apr 24, 2012
[view latest posts]
Level 1
Category: CoD2 Scripting
Posted: Friday, Jun. 17, 2011 03:29 pm
Hello guys im new here but i would really appreciate some help, my server is used to work fine but suddenly a day comes this error everytime some1 disconnects

******* script runtime error *******
pair 'undefined' and 'playing' has unmatching types 'undefined' and 'string': (file 'maps/mp/gametypes/zom.gsc', line 2626)
if(!isDefined(player.pers["team"]) || player.pers["team"] == "spectator" || self.sessionstate == "playing") // || player == self
*
called from:
(file 'maps/mp/gametypes/zom.gsc', line 2714)
thread checkRestart();
*
started from:
(file 'maps/mp/gametypes/zom.gsc', line 2712)
wait 3;
*
************************************
********************
ERROR: script runtime error
(see console for details)
(file 'maps/mp/gametypes/zom.gsc', line 2712)

********************
----- Server Shutdown -----
Share |
liltc64
General Member
Since: Feb 12, 2007
Posts: 906
Last: Oct 22, 2012
[view latest posts]
Level 7
Im a fan of MODSonair
Category: CoD2 Scripting
Posted: Friday, Jun. 17, 2011 03:37 pm
well its saying your session state "playing" is undefined which dosnt sound right to me because playing is a type of session state. can you copy and paste your whole checkRestart thread so we can see more.
Share |
Sense
General Member
Since: Jun 17, 2011
Posts: 12
Last: Apr 24, 2012
[view latest posts]
Level 1
Category: CoD2 Scripting
Posted: Friday, Jun. 17, 2011 03:41 pm
mhm i need some1 to connect and disconnect be4 i can see again :D
Share |
Sense
General Member
Since: Jun 17, 2011
Posts: 12
Last: Apr 24, 2012
[view latest posts]
Level 1
Category: CoD2 Scripting
Posted: Friday, Jun. 17, 2011 03:59 pm
this is all console says :
clientDownload: 2 : client acknowledge of block 31
clientDownload: 2 : client acknowledge of block 32
clientDownload: 2 : writing block 34
clientDownload: 2 : client acknowledge of block 33
clientDownload: 2 : writing block 35
clientDownload: 2 : writing block 36
clientDownload: 2 : client acknowledge of block 34
clientDownload: 2 : client acknowledge of block 35
clientDownload: 2 : writing block 37
clientDownload: 2 : client acknowledge of block 36
clientDownload: 2 : writing block 38
clientDownload: 2 : writing block 39
clientDownload: 2 : client acknowledge of block 37
clientDownload: 2 : client acknowledge of block 38
clientDownload: 2 : writing block 40
clientDownload: 2 : client acknowledge of block 39
clientDownload: 2 : writing block 41
clientDownload: 2 : client acknowledge of block 40
clientDownload: 2 : client acknowledge of block 41
clientDownload: 2 : file "main/zzz_final.iwd" completed
clientDownload: evil.Ni3ls Done
SV_SendClientGameState() for evil.Ni3ls
Going from CS_CONNECTED to CS_PRIMED for evil.Ni3ls
Sending 8207 bytes in gamestate to client: 2
(GAME_DEAD)~>SenSE<~: do :)
Going from CS_PRIMED to CS_ACTIVE for evil.Ni3ls
seb3k@lowday: gtg
seb3k@lowday: ://
(GAME_DEAD)~>SenSE<~: kk
seb3k@lowday: sorry
seb3k@lowday: later
client text ignored for seb3k@lowday: say
(GAME_DEAD)~>SenSE<~: ))
seb3k@lowday: bb ;*
(GAME_DEAD)~>SenSE<~: ye
seb3k@lowday: ^^
(GAME_DEAD)~>SenSE<~: bb
Going to CS_ZOMBIE for
1: EXE_DISCONNECTED
Going from CS_ZOMBIE to CS_FREE for

******* script runtime error *******
pair 'undefined' and 'playing' has unmatching types 'undefined' and 'string': (file 'maps/mp/gametypes/zom.gsc', line 2626)
if(!isDefined(player.pers["team"]) || player.pers["team"] == "spectator" || self.sessionstate == "playing") // || player == self
*
called from:
(file 'maps/mp/gametypes/zom.gsc', line 2714)
thread checkRestart();
*
started from:
(file 'maps/mp/gametypes/zom.gsc', line 2712)
wait 3;
*
************************************
********************
ERROR: script runtime error
(see console for details)
(file 'maps/mp/gametypes/zom.gsc', line 2712)

********************
----- Server Shutdown -----
Sending heartbeat to cod2master.activision.com
==== ShutdownGame ====
Going to CS_ZOMBIE for
0: EXE_DISCONNECTED
Going to CS_ZOMBIE for
2: EXE_DISCONNECTED
---------------------------
Share |
liltc64
General Member
Since: Feb 12, 2007
Posts: 906
Last: Oct 22, 2012
[view latest posts]
Level 7
Im a fan of MODSonair
Category: CoD2 Scripting
Posted: Friday, Jun. 17, 2011 04:01 pm
no i don't mean the error... again... i mean the actual code its self in the zom.gsc
Share |
Sense
General Member
Since: Jun 17, 2011
Posts: 12
Last: Apr 24, 2012
[view latest posts]
Level 1
Category: CoD2 Scripting
Posted: Friday, Jun. 17, 2011 04:04 pm
I think u mean this :

menuAutoAssign()
{
//NOT USED!!!!
if (isDefined(self.delayed) && self.delayed==true)
return;

if (getcvar("scr_zom_NoTeamChange")=="1" && (self.pers["team"] == "allies" || self.pers["team"] == "axis"))
return;

numonteam["allies"] = 0;
numonteam["axis"] = 0;

players = getentarray("player", "classname");
for(i = 0; i < players.size; i++)
{
player = players;

if(!isDefined(player.pers["team"]) || player.pers["team"] == "spectator" || player == self)
continue;

numonteam[player.pers["team"]]++;
}

// if teams are equal return the team with the lowest score
if(numonteam["allies"] == numonteam["axis"])
{
if(getTeamScore("allies") == getTeamScore("axis"))
{
teams[0] = "allies";
teams[1] = "axis";
assignment = teams[randomInt(2)];
}
else if(getTeamScore("allies") < getTeamScore("axis"))
assignment = "allies";
else
assignment = "axis";
}
else if(numonteam["allies"] < numonteam["axis"])
assignment = "allies";
else
assignment = "axis";

if(assignment == self.pers["team"] && (self.sessionstate == "playing" || self.sessionstate == "dead"))
{
if(!isdefined(self.pers["weapon"]))
{
if(self.pers["team"] == "allies")
self openMenu(game["menu_weapon_allies"]);
else
self openMenu(game["menu_weapon_axis"]);
}

return;
}

if(assignment != self.pers["team"] && (self.sessionstate == "playing" || self.sessionstate == "dead"))
{
self.switching_teams = true;
self.joining_team = assignment;
self.leaving_team = self.pers["team"];
self suicide();
}

self.pers["team"] = assignment;
self.pers["weapon"] = undefined;
self.pers["savedmodel"] = undefined;

self setClientCvar("ui_allow_weaponchange", "1");

if(self.pers["team"] == "allies")
{
self openMenu(game["menu_weapon_allies"]);
self setClientCvar("g_scriptMainMenu", game["menu_weapon_allies"]);
}
else
{
self openMenu(game["menu_weapon_axis"]);
self setClientCvar("g_scriptMainMenu", game["menu_weapon_axis"]);
}

self notify("joined_team");
self notify("end_respawn");


}
Share |
liltc64
General Member
Since: Feb 12, 2007
Posts: 906
Last: Oct 22, 2012
[view latest posts]
Level 7
Im a fan of MODSonair
Category: CoD2 Scripting
Posted: Friday, Jun. 17, 2011 04:07 pm
[cry] bro... that code isnt even used in your mod. you can even actually go ahead in delete that out your mod. im talking about checkRestart() thread... can you copy and paste that.
Share |
Sense
General Member
Since: Jun 17, 2011
Posts: 12
Last: Apr 24, 2012
[view latest posts]
Level 1
Category: CoD2 Scripting
Posted: Friday, Jun. 17, 2011 04:13 pm
if (!(thread checkRestart(self)))
{
self thread blackScreen("alliedSuicide");
}
}
else
{
self thread blackScreen("alliedSuicide");

}
}
else
Sorry, i aint that good with scripting :((
Share |
liltc64
General Member
Since: Feb 12, 2007
Posts: 906
Last: Oct 22, 2012
[view latest posts]
Level 7
Im a fan of MODSonair
Category: CoD2 Scripting
Posted: Friday, Jun. 17, 2011 04:17 pm
yeah i can tell. maybe someone else can try to help i cant sit here and do this all day sorry, cya.
Share |
Sense
General Member
Since: Jun 17, 2011
Posts: 12
Last: Apr 24, 2012
[view latest posts]
Level 1
Category: CoD2 Scripting
Posted: Friday, Jun. 17, 2011 04:26 pm
thread checkRestart();

}

PlayerSpawned()
{


self.delayed = false;


//Make sure killcount is defined
if (!isdefined(self.killcount))
self.killcount=0;

//Make sure returnkills is defined
if(getcvar("scr_zom_returnkills") == "")
setcvar("scr_zom_returnkills", "2");

//If returnkills has been reached, reset killcount to 0
if (self.killcount > (getCvarInt("scr_zom_returnkills") - 1))
self.killcount = 0;
Share |
Restricted Access Topic is Locked
Page
Next Page
subscribe
MODSonline.com Forums : Call of Duty 2 : CoD2 Scripting

Latest Syndicated News

»
Codutility.com up and runn...
Nice, and there still using the logo and template for the screenshots, which...
Codutility.com up and runn...
dundy writes...Quote:Call of Duty modding and mapping is barly alive only a ...
Codutility.com up and runn...
Mystic writes...Quote:It seems to me the like the site is completely dead? ...
Codutility.com up and runn...
It seems to me the like the site is completely dead?

Partners & Friends

»