NS Auto-comm
I am trying do a automatic commander to marines, is going fine but I have a little problem, when a player get nearby a resource node a resource tower is created, after 1 sec other resource tower is created and the 2 resources towers are killed because a command I created, but I only want know how to check if the node have already 1 resource tower
I spend 3 hours trying to fix, but nothing plz help-me :D |
Try using find_ent_in_sphere or find_sphere_class to check for nearby resource tower entities.
|
find_ent_in_sphere ( StartEntity, Float:origin[3], Float:radius )
what StartEntity means? |
StartEntity is an offset to start searching from (+1), so you can create a loop to find all of the entities like this:
Code:
This will reassign a value to ent each time through and make sure not to search through what it has already searched, and it will stop the loop if you can't find any more entities passed the offset. |
Is there any way to change or check marine resources?
|
ns_get_res might be able to grab Marine resources, but I don't think ns_set_res will let you set it.
|
| All times are GMT -4. The time now is 19:21. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.