Spawn entities classnames.
Now I don't have enough time to test so I'd like to ask if it's possible to replace the terrorist's spawn entities classnames by ct's ones (info_player_deathmatch and info_player_start respectively). What I thought about is hooking FM_Spawn pre and replacing the classname there (with some checks obviously). Will it work?
|
Re: Spawn entities classnames.
If you want to swap team spawns, then check this plugin:
http://forums.alliedmods.net/showthread.php?p=897057 |
Re: Spawn entities classnames.
Basically I can only think of 2 methods, have not tested them!
Before FM_Spawn to change its classname or in FM_AllocString. Other than that I do not know. |
Re: Spawn entities classnames.
Quote:
I suggets to hook FM_CreateEntity or FM_CreateNamedEntity (pre) and supercede with your own entity. Also you can hook keyvalues to save it and then at spawn (post) create a new spawnpoint for the other team in same location and delete de first one (I suggets to set FL_KILLME). |
Re: Spawn entities classnames.
Code:
|
Re: Spawn entities classnames.
Currently I'm trying to do something like this but with custom entities.
I have a map with non-standard classnames (func_xpaw for example) Then, in my plugin I want to get those func_xpaw and convert to other entity (func_wall, func_door, etc). I've tried to hook CreateNamedEntity, but is not called at map load (at precache). Does anyone knows how to hook them? |
| All times are GMT -4. The time now is 07:09. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.