Quake3World.com Forums
     Level Editing & Modeling
        question on target_location entity


Post new topicReply to topic
Login | Profile | | FAQ | Search | IRC




Print view Previous topic | Next topic 
Topic Starter Topic: question on target_location entity

Veteran
Veteran

Joined: 23 Aug 2011
Posts: 174
PostPosted: 08-23-2011 01:01 PM           Profile Send private message  E-mail  Edit post Reply with quote


Hi!

I have found back my old quake 3 ctf map in my backup that I've started working on a couple of years ago and now I want to finish it. I was following the instructions for making it compatible with Team Arena and Threewave CTF. One of the requirements for it is to put target_location entities in the map for reporting the player positions when team chatting or based on certain events (like dropping an item).

From what I understand, for this to work, I created a target_location entity, and then placed it at the player level right on the floor. I just need then to create a key message with the value of the text that I want to display, like message=red flag base and the other key is for the color of the text so count=1 for red.

Am I doing this right? Because it's certainly not working for me. When I stand in my map after compilation like right in front the the target_location entity and trying team chat or dropping an item I always get the text that says unknown location being displayed.

thank you for your time and suggestions.

DGhost




Top
                 

Insane Quaker
Insane Quaker

Joined: 28 Dec 2009
Posts: 290
PostPosted: 08-23-2011 01:29 PM           Profile Send private message  E-mail  Edit post Reply with quote


It only works if you have multiple target_locations placed throughout your map.

And yes, color code your messages. red "^1Base" blue "^4Base" red "^1Base Front", etc.




Top
                 

Veteran
Veteran

Joined: 23 Aug 2011
Posts: 174
PostPosted: 08-23-2011 02:14 PM           Profile Send private message  E-mail  Edit post Reply with quote


I already got 3 target_location with message and count keys placed in my red base but still, no luck. Maybe I need to put more?



_________________
DGhost
http://www.dghost.com


Top
                 

Insane Quaker
Insane Quaker

Joined: 28 Dec 2009
Posts: 290
PostPosted: 08-23-2011 02:26 PM           Profile Send private message  E-mail  Edit post Reply with quote


count keys? is that a Team Arena thing? all I have is something like this:

{
"classname" "target_location"
"message" "^1Base"
"origin" "-2648 -319 128"
}

for original q3.




Top
                 

Veteran
Veteran

Joined: 23 Aug 2011
Posts: 174
PostPosted: 08-23-2011 02:54 PM           Profile Send private message  E-mail  Edit post Reply with quote


I'm not sure if it's from TA or Q3A, my guess would be Q3A, from the GrkRadiant manual :

Quote:
target_location
Map Entity Color: Dark Green
Dimensions: (-8 -8 -8) (8 8 8)
Game Function: Location marker used by bots and players for team orders and team chat in the course of Teamplay games. The closest target_location in sight is used for the location. If none is in sight, the closest in distance is used.

Keys
Message: name of the location (text string). Displayed in parentheses in front of all team chat and order messages. Shorter is better.
count: color of the location text displayed in parentheses during team chat. Set to 0-7 for color.

0 : white (default)
1 : red
2 : green
3 : yellow
4 : blue
5 : cyan
6 : magenta
7 : white


The count key value is only for the color code of the text being displayed. From the original notes for mapping for threewave a note was added to this definition from the manual :

Quote:
Note from Johnny Law Re Above:
The Radiant manual is incorrect about the way target_location entities work. If you examine the gamecode source you can see that Q3 just selects the closest target_location in the Potentially Visible Set. Line of sight is not involved. I just about pulled my hair out trying to get target_locations to work predictably before I discovered that.


DGhost



_________________
DGhost
http://www.dghost.com


Top
                 

Immortal
Immortal

Joined: 02 Jun 2006
Posts: 2250
PostPosted: 08-23-2011 04:31 PM           Profile Send private message  E-mail  Edit post Reply with quote


damn it, did not kow you have to colour code me... another thing to fix in q3ctfp22 :/




Top
                 

Veteran
Veteran

Joined: 23 Aug 2011
Posts: 174
PostPosted: 08-23-2011 04:47 PM           Profile Send private message  E-mail  Edit post Reply with quote


I was just reading the threewave mapping instructions, it says that for target_location, just to give it the team color for the point of the target and white for the ones located in the middle of the map, 0=white, 1=red 4 = blue

Now I just found out that my target_location are working perfectly well in team arena, just not in threewave ctf. And I was following the instructions from Threewave to make those.

Wow that's bugging me even more now that I know it's working in TA.



_________________
DGhost
http://www.dghost.com


Top
                 

Insane Quaker
Insane Quaker

Joined: 05 Mar 2010
Posts: 278
PostPosted: 08-23-2011 10:37 PM           Profile Send private message  E-mail  Edit post Reply with quote


Yep, 3W for some unknown reason uses count keys instead of text colorisation carots. Well, here's one from q3wcp5:
Code:
{
   "spawnflags" "0"
   "classname" "target_location"
   "count" "1"
   "message" "Red Flag"
   "origin" "-216 2616 8"
}

Not sure what the spawnflags 0 is about though. So if you copy that it should have color in 3W, but not TA. To get around that you could possibly have 2 different target_location's - one compatible with 3W and set with "notta" "1" and a TA compatible one with "notq3a" "1".




Top
                 

Cool #9
Cool #9

Joined: 01 Dec 2000
Posts: 36787
PostPosted: 08-23-2011 10:48 PM           Profile   Send private message  E-mail  Edit post Reply with quote


Settings "spawnflags" "0" is the same as omitting the spawnflags key alltogether.



_________________
Get mods & maps at Engines of Creation


Top
                 

Veteran
Veteran

Joined: 23 Aug 2011
Posts: 174
PostPosted: 08-24-2011 05:38 AM           Profile Send private message  E-mail  Edit post Reply with quote


TheMuffinMan : Thank you for the example from your map. I've still tried it on my target_location by adding the spawnflag 0 to my target location. It still work in Team Arena but not in 3W again.

Eraser : You are right, 0 is for nothing, so the spawnflags = o is exactly the same has having no spawnflags setup for the entity.

From what I understand from the GtkR manual, the spawnflags are just option/check boxes for some specific properties for entities (like suspended). Nothing more.

Gaaaaah I'm going crazy. Here's some screenies of my map (it's a space CTF map), just for fun! :






Top
                 
Quake3World.com | Forum Index | Level Editing & Modeling


Post new topic Reply to topic


cron
Quake3World.com
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group