Help! - Printable Version +- SphereCommunity (https://forum.spherecommunity.net) +-- Forum: Sphere 0.56d (/Forum-Sphere-0-56d) +--- Forum: Script Help (/Forum-Script-Help) +--- Thread: Help! (/Thread-Help--4833) Pages: 1 2 |
RE: Help! - Extreme - 06-14-2016 01:29 PM First check if regions accepts tags, if not, use vars in @enter to count players inside the region, then announce RE: Help! - rastrero - 06-27-2016 11:16 PM Here you got your script fixed (not tested but should work) [REGIONTYPE r_region_attack] On=@Enter IF (<SRC.IsPlayer>) //you only need one if. TAG.players += 1 //**read note ENDIF On=@Exit IF (<SRC.IsPlayer>) TAG.players -= 1 ENDIF if (<tag0.player> < 0) checks the tag dosnt take alues under 0 (if dosnt exist = 0) tag.player //erase tag. endif *Notes 1 -if 0 will auto set tag.players = 1 -u dont need to put "region." to call the region. If you put only "tag.players" wtihout "region." or "src." it will affect to the region. -src.region.tag.player would point to the players region. -if you writte region.tag.player on that trigger, you are calling the region where the region is. Is like writting <region.region.tag.player> You can check all I said on this link, look for "References"TORFO WIKI SPHERE hope this solve your problem. And learn to use the wiki. **Notes 2 Try to remember that when you set tag. if the value are numbers, sphere will save the value as HEXADECIMAL, so you will need do <eval <tag.player> to retrieve the value of the tag in decimals numbers. Example: (1=01) (10=0a) RE: Help! - an0n!m0use - 06-28-2016 02:29 AM (06-27-2016 11:16 PM)rastrero Wrote: Here you got your script fixed (not tested but should work)Thx, working perfectly RE: Help! - rastrero - 06-28-2016 04:48 AM Im glad it works, but please, LEARN the wiki. Your error was so basic. That is the reason nobody saw it or helped you. Learn how to use the wiki!!! |