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

Members Online

»
0 Active | 8 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 : DOOM III
Category: DOOM III Mapping
D3 mapping and level design.
Moderators: foyleman, Foxhound, Mystic, StrYdeR, batistablr, Welshy, DrBiggzz, supersword
Latest Posts
Subscribed Posts
Search
Restricted Access Topic is Locked
Page
Previous Page
subscribe
Author Topic: Same old scripting problem
drech
General Member
Since: Aug 25, 2004
Posts: 118
Last: Jul 31, 2005
[view latest posts]
Level 4
Category: DOOM III Mapping
Posted: Sunday, Sep. 26, 2004 12:08 am
upon further experimentation I've found that it doesn't seem to be able to call any functions (I tried with one called say_stuff() and then sayStuff() that had simply
{
sys.print("stuff");
}
in it.

And I got the same error. However, it is finding and running the script, because in main I have a sys.print("room.script initialized.")
my map is called room, and the script room.script, and I have the key script with the value room.script in the worldspawn, and the main works, so I'm really really lost.

However, this leaves hope that maybe my method does work, but it's another problem entirely.
Share |
foyleman
Preferred PLUS Member
Since: Nov 7, 2001
Posts: 95762
Last: Apr 13, 2021
[view latest posts]
Level 10
Admin
Forum Moderator
Im a fan of MODSonair
Im a HOST of MODSonair
Category: DOOM III Mapping
Posted: Sunday, Sep. 26, 2004 04:12 pm
I am able to print out to the console whatever I want based on settings in the game.. however, I am unable to get the name of the entity calling it.

If I can figure out how to getName of an entity that is triggering the event, then I can figure ou thow to call the rest.

working example that prints the value of the key "doorname" in the console:

void openme() {
string doorent;

doorent = $func_door_1.getKey( "doorname" );

sys.print("*******\n");
sys.print(doorent);
sys.print("*******\n");
}

What I want to try but can't get the entity name:

void openme() {
string doorent;
entity ent;

ent = sys.getEntity(); // or getName?
doorent = ent.getKey( "doorname" );

sys.print("*******\n");
sys.print(doorent);
sys.print("*******\n");
}
Go ahead... You Play I Mod : Support Modsonline by becoming a PREFERRED MEMBER today!
Have you heard the MODSonair Podcast?:
MODSonair is a weekly podcast bringing you the news from a modders perspective.
Tune in every Sunday at 12pm EST to listen LIVE.
Quake 4 Mods for Dummies - Half-Life 2 Mods for Dummies
Share |
foyleman
Preferred PLUS Member
Since: Nov 7, 2001
Posts: 95762
Last: Apr 13, 2021
[view latest posts]
Level 10
Admin
Forum Moderator
Im a fan of MODSonair
Im a HOST of MODSonair
Category: DOOM III Mapping
Posted: Sunday, Sep. 26, 2004 04:34 pm
drech writes...
Quote:
the real problem with that is that Doom 3 does not have a "this" object. Usually you can use "this" (in Java, possibly C++ and in other forms of code including flash) to refer to the object that called the function. Doom 3 does not have a "this," and therefore, you must know the name of the object that targets another object to use $object.getTarget()



I now can agree with this. I can't find any way to find out the name of an entity that calls to a script. Seems rediculous that this is not in there, but I can't find it.
Go ahead... You Play I Mod : Support Modsonline by becoming a PREFERRED MEMBER today!
Have you heard the MODSonair Podcast?:
MODSonair is a weekly podcast bringing you the news from a modders perspective.
Tune in every Sunday at 12pm EST to listen LIVE.
Quake 4 Mods for Dummies - Half-Life 2 Mods for Dummies
Share |
drech
General Member
Since: Aug 25, 2004
Posts: 118
Last: Jul 31, 2005
[view latest posts]
Level 4
Category: DOOM III Mapping
Posted: Sunday, Sep. 26, 2004 11:13 pm
a lot of iD functions are assembled like this:

function ( entity self )
{
self.doWhatever();
}

and, though 'self' seems like it shouldn't work any better than 'door,' it's possible that when you call a function that requires an entity named 'self,' it will get the 'self' entity from whatever entity called the function, therefore making 'self' a kind-of 'this' object.
Share |
foyleman
Preferred PLUS Member
Since: Nov 7, 2001
Posts: 95762
Last: Apr 13, 2021
[view latest posts]
Level 10
Admin
Forum Moderator
Im a fan of MODSonair
Im a HOST of MODSonair
Category: DOOM III Mapping
Posted: Monday, Sep. 27, 2004 01:05 am
have your tried using self? I have and it did nothing for me. it seemed that self is nothing more than another named object just like entity door, entity name or whatever. It did not work like "this".

I saw this idea posted in another forum and that's why I tried it.

[ohwell]
Go ahead... You Play I Mod : Support Modsonline by becoming a PREFERRED MEMBER today!
Have you heard the MODSonair Podcast?:
MODSonair is a weekly podcast bringing you the news from a modders perspective.
Tune in every Sunday at 12pm EST to listen LIVE.
Quake 4 Mods for Dummies - Half-Life 2 Mods for Dummies
Share |
rEdrUmMDK
Preferred PLUS Member
Since: May 29, 2002
Posts: 6787
Last: Feb 12, 2009
[view latest posts]
Level 10
Admin
Category: DOOM III Mapping
Posted: Monday, Sep. 27, 2004 01:08 am
Have you guys seen this in a stock map or custom map?
Backup Your Work or your Work will be gone.
http://www.modsonline.com
better red than dead
Share |
foyleman
Preferred PLUS Member
Since: Nov 7, 2001
Posts: 95762
Last: Apr 13, 2021
[view latest posts]
Level 10
Admin
Forum Moderator
Im a fan of MODSonair
Im a HOST of MODSonair
Category: DOOM III Mapping
Posted: Monday, Sep. 27, 2004 01:26 am
I saw this in a post on another site. uhm... HERE

The author didn't try it out.. just wrote it.
Go ahead... You Play I Mod : Support Modsonline by becoming a PREFERRED MEMBER today!
Have you heard the MODSonair Podcast?:
MODSonair is a weekly podcast bringing you the news from a modders perspective.
Tune in every Sunday at 12pm EST to listen LIVE.
Quake 4 Mods for Dummies - Half-Life 2 Mods for Dummies
Share |
siilence
General Member
Since: May 14, 2004
Posts: 131
Last: Aug 10, 2005
[view latest posts]
Level 4
Category: DOOM III Mapping
Posted: Saturday, Oct. 2, 2004 09:44 am
[puke] how do i use the editor? what do i do with the menu that u get with right clicking on the grid? [mad]
Share |
foyleman
Preferred PLUS Member
Since: Nov 7, 2001
Posts: 95762
Last: Apr 13, 2021
[view latest posts]
Level 10
Admin
Forum Moderator
Im a fan of MODSonair
Im a HOST of MODSonair
Category: DOOM III Mapping
Posted: Saturday, Oct. 2, 2004 12:07 pm
Check out the great video tutorials I made. They will show you how to use the editor.

They're located in the tutorials section which is linked on the left.
Go ahead... You Play I Mod : Support Modsonline by becoming a PREFERRED MEMBER today!
Have you heard the MODSonair Podcast?:
MODSonair is a weekly podcast bringing you the news from a modders perspective.
Tune in every Sunday at 12pm EST to listen LIVE.
Quake 4 Mods for Dummies - Half-Life 2 Mods for Dummies
Share |
Restricted Access Topic is Locked
Page
Previous Page
subscribe
MODSonline.com Forums : DOOM III : DOOM III Mapping

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

»