Set_task tag mismatch
Hi,
I have a problem with setting a pamateter to a set_task. The idea is that an entity is respawned some time after it is picked up. Sorry, I don't have the full code in this computer. PHP Code:
I'm using random locations generator by joropito that's why I use this method for respawning an entity. |
Re: Set_task tag mismatch
PHP Code:
|
Re: Set_task tag mismatch
1. de-tag the Float array in set_task
2. make SpawnEnt public 3. make the origin param an array in SpawnEnt untested PHP Code:
|
Re: Set_task tag mismatch
Thank you both for help.
It seems the problem was solved by adding _: to origin. I don't know what _: does. |
Re: Set_task tag mismatch
I think without _: task will take only origin[0]
|
Re: Set_task tag mismatch
_: do cast to integer.
|
Re: Set_task tag mismatch
_: = untag the var.
|
Re: Set_task tag mismatch
Thanks.
I think I have understood. :) |
Re: Set_task tag mismatch
The reason for the tag mismatch warning is set_task is written to accept an integer array, not a float array. Un-tagging the float array makes set_task think its an integer (untagged) array.
http://www.amxmodx.org/funcwiki.php?go=func&id=253 |
| All times are GMT -4. The time now is 22:01. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.