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

Members Online

»
0 Active | 6 Guests
Online:

LATEST FORUM THREADS

»
warfare
CoD4 Map + Mod Releases
Voting menu on maps
CoD+UO General
Hauling 911
CoDBO3 General

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
Previous Page
subscribe
Author Topic: CoD2 Bubble Problem!
tHMatt
General Member
Since: Sep 11, 2007
Posts: 473
Last: Mar 20, 2013
[view latest posts]
Level 5
Category: CoD2 Scripting
Posted: Saturday, Jan. 7, 2012 10:31 am
My post was deleted without any given reason or message, cheers modsonline.
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: Saturday, Jan. 7, 2012 10:33 am
Dobriy writes...
Quote:
IzNoGoD writes...
Quote:
Dobriy writes...
Quote:

nemanja-1997


U can use my script

Code:
main
{
level._effect["nuk"] = loadfx ("fx/zombie/dbubble_deploy.efx");
level._effect["nuks"] = loadfx ("fx/zombie/dbubble_hit.efx");
level._effect["nu"] = loadfx ("fx/zombie/dbubble_green.efx");
level._effect["s"]= loadfx ("fx/zombie/dbubble_powerdown.efx");

self.hudbuble destroy();
self.hudbuble = newClientHudElem(self);
self.hudbuble.alignx = "center";
self.hudbuble.x = 330;
self.hudbuble.y = 120; 
self.hudbuble.fontscale = 1.2;
self.hudbuble.label = &"^2`^9[^1For Delete^9]^2:";

bubble = spawn( "script_model",self.origin+(0,0,20));
bubble setModel("xmodel/bx_dbubble");
time=60;
while(1)
{
time-=0.1;
self.hudbuble setValue(int(time));
bubble rotateto((0, randomfloat(360), randomfloat(360)), 0.4);
playFx( level.fx_dbubble_loop, bubble.origin + (0,0,15));
wait 0.1;
if(time<=0 || self.pers["team"]!="allies" )
{
self.hudbuble destroy();
bubble hide();
playFx( level._effect["s"], bubble.origin );
bubble delete();
self.spawnprotected=false;
break;
}
players = getEntArray( "player", "classname" );
for( i = 0; i < players.size; i++ )
{
if(players[i].pers["team"]=="axis" && distance(bubble.origin, players[i].origin ) < 100 && isAlive(players[i]))
{
playFx( level._effect["nuks"],players[i].origin+(0,0,15));
players[i].health = players[i].health + 300;
players[i] finishPlayerDamage(players[i], players[i], 300, 0, "MOD_PROJECTILE", "panzerschreck_mp", bubble.origin, vectornormalize(players[i].origin - bubble.origin), "none", 0);
}
if(players[i].pers["team"]=="allies" && distance(bubble.origin, players[i].origin ) < 100 && isAlive(players[i]))
{
players[i].spawnprotected=true;
}
if(players[i].pers["team"]=="allies" && distance(bubble.origin, players[i].origin ) >= 100 && isAlive(players[i]))
{
players[i].spawnprotected=false;
}
}
}
}


at least 3 things wrong witht his code: the loadfx() is called too late, so it runs after a wait. Dont ever do this.

The typo: main should be main()

And last but not least: having a while(true) loop which breaks on one condition. Put it in the fkcing loop if you dont mind. thx.


IzNoGoD,You consider yourselves as the cleverest at the given forum? Can before criticising that that is checked really up and works, you show something the instead of will philosophise before those who understands of nothing in cod2 scripting and your advice are not necessary to them, scripts are necessary to them.thx


i dont know if its your spelling or its cause iv been up all night. but the only reason why people like Matty Iznogod reply to what they say. is because you are just handing this dude your code and not teaching him 1 damn thing... how are you about to say his advice is not necessary and the giving the codes are? are you stupid. and of course im already waiting for it cause every time i throw my opinion out at someone like this this thread will probs get locked and this post probs wont even get to you in time. but try and understand iznogod is like every normal person... he dosnt want to see codes being thrown around that people do no understand and that are not trying to learn and trying to find the easy route out. if someone for once could even just pretend to care and say. "hey i got this code i dont know exactly how it works im trying to understand it could someone help me along these lines" everyone would love to help! but someone posting iznogods code in particular that dosnt know sh!t about it and saying dosnt work help. yeah your not getting the easy card. for you just giving this dude a code you probs didnt even make your self throws you into the "dont help this dude to much on modsonline category". atleast thats how i see it. k bye.
Share |
Dobriy
General Member
Since: Mar 31, 2011
Posts: 96
Last: May 23, 2012
[view latest posts]
Level 3
Category: CoD2 Scripting
Posted: Saturday, Jan. 7, 2012 10:55 am
liltc64,You see that someone was scattered here by unique scripts? I do not see! If to the person the script why not to give it is necessary simply to it? He wants the USUAL server, for this purpose to it is not obligatory to study this flicking language on which it is written cod2, especially to it 13-14 years.

P.S. The theme is closed, to mine it found the decision of the problem in my script, instead of in your philosophy
Share |
BraX
General Member
Since: Apr 29, 2008
Posts: 413
Last: May 26, 2012
[view latest posts]
Level 5
Im a fan of MODSonair
Category: CoD2 Scripting
Posted: Monday, Jan. 9, 2012 04:14 pm
Dobriy writes...
Quote:

nemanja-1997


U can use my script

Code:
main
{
level._effect["nuk"] = loadfx ("fx/zombie/dbubble_deploy.efx");
level._effect["nuks"] = loadfx ("fx/zombie/dbubble_hit.efx");
level._effect["nu"] = loadfx ("fx/zombie/dbubble_green.efx");
level._effect["s"]= loadfx ("fx/zombie/dbubble_powerdown.efx");

self.hudbuble destroy();
self.hudbuble = newClientHudElem(self);
self.hudbuble.alignx = "center";
self.hudbuble.x = 330;
self.hudbuble.y = 120; 
self.hudbuble.fontscale = 1.2;
self.hudbuble.label = &"^2`^9[^1For Delete^9]^2:";

bubble = spawn( "script_model",self.origin+(0,0,20));
bubble setModel("xmodel/bx_dbubble");
time=60;
while(1)
{
time-=0.1;
self.hudbuble setValue(int(time));
bubble rotateto((0, randomfloat(360), randomfloat(360)), 0.4);
playFx( level.fx_dbubble_loop, bubble.origin + (0,0,15));
wait 0.1;
if(time<=0 || self.pers["team"]!="allies" )
{
self.hudbuble destroy();
bubble hide();
playFx( level._effect["s"], bubble.origin );
bubble delete();
self.spawnprotected=false;
break;
}
players = getEntArray( "player", "classname" );
for( i = 0; i < players.size; i++ )
{
if(players[i].pers["team"]=="axis" && distance(bubble.origin, players[i].origin ) < 100 && isAlive(players[i]))
{
playFx( level._effect["nuks"],players[i].origin+(0,0,15));
players[i].health = players[i].health + 300;
players[i] finishPlayerDamage(players[i], players[i], 300, 0, "MOD_PROJECTILE", "panzerschreck_mp", bubble.origin, vectornormalize(players[i].origin - bubble.origin), "none", 0);
}
if(players[i].pers["team"]=="allies" && distance(bubble.origin, players[i].origin ) < 100 && isAlive(players[i]))
{
players[i].spawnprotected=true;
}
if(players[i].pers["team"]=="allies" && distance(bubble.origin, players[i].origin ) >= 100 && isAlive(players[i]))
{
players[i].spawnprotected=false;
}
}
}
}


Another moroon modified my script and shared here. "U can use my script" made me laugh.. Oh there's also bx_ (BraX_) prefixed model and my effects.
Share |
Dobriy
General Member
Since: Mar 31, 2011
Posts: 96
Last: May 23, 2012
[view latest posts]
Level 3
Category: CoD2 Scripting
Posted: Wednesday, Jan. 11, 2012 07:44 am
BraX writes...
Quote:
Dobriy writes...
Quote:

nemanja-1997


U can use my script

Code:
main
{
level._effect["nuk"] = loadfx ("fx/zombie/dbubble_deploy.efx");
level._effect["nuks"] = loadfx ("fx/zombie/dbubble_hit.efx");
level._effect["nu"] = loadfx ("fx/zombie/dbubble_green.efx");
level._effect["s"]= loadfx ("fx/zombie/dbubble_powerdown.efx");

self.hudbuble destroy();
self.hudbuble = newClientHudElem(self);
self.hudbuble.alignx = "center";
self.hudbuble.x = 330;
self.hudbuble.y = 120; 
self.hudbuble.fontscale = 1.2;
self.hudbuble.label = &"^2`^9[^1For Delete^9]^2:";

bubble = spawn( "script_model",self.origin+(0,0,20));
bubble setModel("xmodel/bx_dbubble");
time=60;
while(1)
{
time-=0.1;
self.hudbuble setValue(int(time));
bubble rotateto((0, randomfloat(360), randomfloat(360)), 0.4);
playFx( level.fx_dbubble_loop, bubble.origin + (0,0,15));
wait 0.1;
if(time<=0 || self.pers["team"]!="allies" )
{
self.hudbuble destroy();
bubble hide();
playFx( level._effect["s"], bubble.origin );
bubble delete();
self.spawnprotected=false;
break;
}
players = getEntArray( "player", "classname" );
for( i = 0; i < players.size; i++ )
{
if(players[i].pers["team"]=="axis" && distance(bubble.origin, players[i].origin ) < 100 && isAlive(players[i]))
{
playFx( level._effect["nuks"],players[i].origin+(0,0,15));
players[i].health = players[i].health + 300;
players[i] finishPlayerDamage(players[i], players[i], 300, 0, "MOD_PROJECTILE", "panzerschreck_mp", bubble.origin, vectornormalize(players[i].origin - bubble.origin), "none", 0);
}
if(players[i].pers["team"]=="allies" && distance(bubble.origin, players[i].origin ) < 100 && isAlive(players[i]))
{
players[i].spawnprotected=true;
}
if(players[i].pers["team"]=="allies" && distance(bubble.origin, players[i].origin ) >= 100 && isAlive(players[i]))
{
players[i].spawnprotected=false;
}
}
}
}


Another moroon modified my script and shared here. "U can use my script" made me laugh.. Oh there's also bx_ (BraX_) prefixed model and my effects.


BraX,Yes, anybody here also doesn't tell that models and effects are made by me, alas, I am not able to make it
Share |
Restricted Access Topic is Locked
Page
Previous 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

»