is not a entitiy o.O?

Have questions about CoD2 mapping that aren't covered in the tutorials section? Post here!

Moderator: Core Staff

Post Reply
User avatar
waywaaaard
Core Staff
Core Staff
Posts: 2214
Joined: February 6th, 2006, 3:18 pm
Location: Germany/Bayern

is not a entitiy o.O?

Post by waywaaaard » February 14th, 2008, 8:57 pm

I got a little script but always when I want to linkto something it doesn't work

Code: Select all

main() 
{
	maps\mp\_load::main();

	game["allies"] = "american";
	game["axis"] = "german";
	game["attackers"] = "allies";
	game["defenders"] = "axis";
	game["american_soldiertype"] = "normandy";
	game["german_soldiertype"] = "normandy";
	
	thread trainride();
}

trainride()
{
ttrain1 = getent ("ttrain1_train", "targetname"); // script brushmodel
ttrain1door = getent ("ttrain1_door", "targetname"); // script brushmodel
ttrainspeaker = getent ("ttrain1_speaker", "targetname"); // script model
televator1 = getent ("televator_1", "targetname"); // script brushmodel
ttrain1trig = getent ("ttrain1_trigger", "targetname");
// ttrainspeaker linkto(ttrain1); doesn't work

while(1)
{
ttrain1trig waittill ("trigger");

// door open and close
ttrain1door moveX (4, 1, .5, .5);
ttrain1door waittill ("movedone");
ttrain1door moveY (-40, 1, .5, .5);
ttrain1door waittill ("movedone");
wait 5;
ttrain1door moveX (-4, 1, .5, .5);
ttrain1door waittill ("movedone");
ttrain1door moveY (40, 1, .5, .5);
ttrain1door waittill ("movedone");

ttrain1door linkto ("ttrain1"); // here I get the error Is not a entity o.O

ttrainspeaker playsound ("train_start");
ttrain1 moveY (2063, 20, 1, 1);
ttrain1 waittill ("movedone");

}
}
dunno why I always get this error
is not a entity when I try to link the door to the rain
THAT HANDS WERE NOT TRACED!
visit my blog: Link
Soviet wrote:Yeah, watch out, Peds will hit you with his +5 D-Battleaxe of homosexuality :roll:

User avatar
Drofder2004
Core Staff
Core Staff
Posts: 13313
Joined: April 13th, 2005, 8:22 pm
Location: UK, London

Post by Drofder2004 » February 14th, 2008, 11:02 pm

put a .5 second wait before and after.

If still getting error, comment (//) out the line and see if the rest of the script works.
Image
Virgin Media 20Mb Broadband:
"Perfect for families going online at the same time, downloading movies, online gaming and more."
Borked internet since: 22-07-2010

User avatar
Nightmare
Core Staff
Core Staff
Posts: 2688
Joined: January 12th, 2006, 10:09 pm
Contact:

Post by Nightmare » February 15th, 2008, 3:45 am

make sure you enable linkto for ttrain1
Coding is Poetry. Mapping is Art.
"Cause im the sexiest mapper ever...except for nm, that sexy man" - Soviet

-=[CoDJumper.com Movies]=-
[Ambush] || [Backlot] || [Bloc] || [Bog] || [Broadcast] || [Chinatown] || [Countdown]
[Crash] || [Creek] || [Crossfire] || [District] || [Downpour] || [Killhouse] || [Overgrown]
[Pipeline] || [Shipment & Wetwork] || [Showdown] || [Strike] || [Vacant]

User avatar
waywaaaard
Core Staff
Core Staff
Posts: 2214
Joined: February 6th, 2006, 3:18 pm
Location: Germany/Bayern

Post by waywaaaard » February 15th, 2008, 8:13 pm

if i dont linkto the door to the train it works and I already tried to enable linkto but then it occurs the error already enabled :-(
dunno why it doesnt work -.-
THAT HANDS WERE NOT TRACED!
visit my blog: Link
Soviet wrote:Yeah, watch out, Peds will hit you with his +5 D-Battleaxe of homosexuality :roll:

User avatar
Drofder2004
Core Staff
Core Staff
Posts: 13313
Joined: April 13th, 2005, 8:22 pm
Location: UK, London

Post by Drofder2004 » February 15th, 2008, 9:03 pm

Lev!athan wrote:if i dont linkto the door to the train it works and I already tried to enable linkto but then it occurs the error already enabled :-(
dunno why it doesnt work -.-
have you tried the wait commands i suggested?
Image
Virgin Media 20Mb Broadband:
"Perfect for families going online at the same time, downloading movies, online gaming and more."
Borked internet since: 22-07-2010

User avatar
waywaaaard
Core Staff
Core Staff
Posts: 2214
Joined: February 6th, 2006, 3:18 pm
Location: Germany/Bayern

Post by waywaaaard » February 15th, 2008, 9:17 pm

î tried and get still the is not an entitiy error in line

Code: Select all

ttrain1door linkto ("ttrain1"); // here I get the error Is not a entity o.O 
THAT HANDS WERE NOT TRACED!
visit my blog: Link
Soviet wrote:Yeah, watch out, Peds will hit you with his +5 D-Battleaxe of homosexuality :roll:

User avatar
Drofder2004
Core Staff
Core Staff
Posts: 13313
Joined: April 13th, 2005, 8:22 pm
Location: UK, London

Re: is not a entitiy o.O?

Post by Drofder2004 » February 24th, 2008, 6:02 pm

Topic cleaned.

Ok, I have looked at your map but due to not having a full install I am unable to test things my self but here is one thing which may be the problem.

Neither the train nor the door have an origin brush connected to them
(Create an origin brush (small 6x6x6 square with origin texture) and copy it in the exact same place. Then remake the script_brushmodels using these origins, 1 origin for each)
Image
Virgin Media 20Mb Broadband:
"Perfect for families going online at the same time, downloading movies, online gaming and more."
Borked internet since: 22-07-2010

User avatar
Drofder2004
Core Staff
Core Staff
Posts: 13313
Joined: April 13th, 2005, 8:22 pm
Location: UK, London

Re: is not a entitiy o.O?

Post by Drofder2004 » February 24th, 2008, 6:04 pm

If that still does not work, send me the new map file, the gsc and the compiled version of the map (along with all the textures etc).
Image
Virgin Media 20Mb Broadband:
"Perfect for families going online at the same time, downloading movies, online gaming and more."
Borked internet since: 22-07-2010

Post Reply

Who is online

Users browsing this forum: No registered users and 34 guests