Raised This Month: $ Target: $400
 0% 

Finding Spawns


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Votorx
Senior Member
Join Date: Jun 2004
Old 03-03-2005 , 11:48   Finding Spawns
Reply With Quote #1

*Sigh* I remember a while back I had a problem with this. I figured out how to do it and incorporated it into my plugin and it worked. Of course, I need to do it again for another plugin I'm making only I forgot how to do it, I can't find my old plugin where I did it and I can't find anything to help me here on the forums so...

Does anyone know how I can get the origin of all the spawns for both the ct and t team? I've used find_ent_classname(blada) but its returning origins that are obviously not right (like x = 10039294 y = 92938481 z = 91029342), how can I do it correctly?
__________________
Currently Looking for a mod team.
Votorx is offline
Send a message via AIM to Votorx Send a message via MSN to Votorx Send a message via Yahoo to Votorx
twistedeuphoria
Veteran Member
Join Date: Jul 2004
Old 03-03-2005 , 12:17  
Reply With Quote #2

Did you try "info_player_start" and "info_player_deathmatch"?
__________________
twistedeuphoria is offline
Votorx
Senior Member
Join Date: Jun 2004
Old 03-03-2005 , 21:16  
Reply With Quote #3

Yeah
__________________
Currently Looking for a mod team.
Votorx is offline
Send a message via AIM to Votorx Send a message via MSN to Votorx Send a message via Yahoo to Votorx
slurpycof
Senior Member
Join Date: Nov 2004
Old 03-03-2005 , 23:05  
Reply With Quote #4

I found this code somewhere on the these forums (sorry, don't remember who to credit). Part of it may help you.

Code:
 public plugin_precache() {     precache_model("models/w_suit.mdl")     return PLUGIN_CONTINUE  }  public tspawn_test(id, level, cid) {     new entid, Float:Ang[3], Float:Vec[3], Float:vAng[3]     new tEnt, tfEnt     new i=0     tEnt = find_ent_by_class(-1, "info_player_deathmatch")     while (tEnt > 0) {         tfEnt = find_ent_by_class(tEnt, "info_player_deathmatch")         entity_get_vector(tEnt, EV_VEC_angles, Ang)         entity_get_vector(tEnt, EV_VEC_origin, Vec)         entity_get_vector(tEnt, EV_VEC_v_angle, vAng)         entid = create_entity("info_target")         entity_set_string(entid, EV_SZ_classname, "view_spawn")         entity_set_model(entid, "models/w_suit.mdl")         entity_set_origin(entid, Vec)         entity_set_vector(entid, EV_VEC_angles, Ang)         entity_set_vector(entid, EV_VEC_v_angle, vAng)         entity_set_int(entid, EV_INT_solid, 1)         entity_set_int(entid, EV_INT_movetype, 6)         tEnt = tfEnt         i++     }     return PLUGIN_CONTINUE  }
slurpycof is offline
Zor
Veteran Member
Join Date: Mar 2004
Location: Toronto, ON
Old 03-04-2005 , 11:00  
Reply With Quote #5

If you want to find spawn points download ripent.exe, and rip all the entities out of given map and look at the spawn points.

Cheers!
__________________
Zor is offline
Send a message via AIM to Zor Send a message via MSN to Zor Send a message via Yahoo to Zor
Votorx
Senior Member
Join Date: Jun 2004
Old 03-04-2005 , 11:50  
Reply With Quote #6

Yeah that would be an easier way of doing it but that's not how I want my plugin to operate.

is find_ent_class() the best way of finding the spawns or is there an easier way?
__________________
Currently Looking for a mod team.
Votorx is offline
Send a message via AIM to Votorx Send a message via MSN to Votorx Send a message via Yahoo to Votorx
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 02:54.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode