![]() |
NPCS - Town stones - Printable Version +- SphereCommunity (https://forum.spherecommunity.net) +-- Forum: Sphere 0.56d (/Forum-Sphere-0-56d) +--- Forum: Script Help (/Forum-Script-Help) +--- Thread: NPCS - Town stones (/Thread-NPCS-Town-stones) |
NPCS - Town stones - Soulless - 07-11-2012 07:32 AM I've updated this script. decided to include the whole thing, and an outline of the system please let me know if there is any issues Features:
RE: NPCS - Town stones - Skul - 07-11-2012 08:09 AM yes, sendpacket can help you do this. considering npcs don't over-ride their notoriety by sphere's default behavior. Uhm, let me post a script I made, it was not designed to do exactly what you want, but the idea is in the code, maybe you can use it to manifest your own idea? Check it out: Code: [FUNCTION updatecharacter] So packet 077 is 'that' packet you need to change the highlight color of your guards, this function should be called off your guard by let's say @click (when the guard becomes near) or based on a timer from the guard npc itself (some people can disable @click by client settings). This will send packet 077 to all clients in the area to update the character 'updatecharacter' function is called upon. I didn't put any checks in to see if the npc is at war or in another faction, i simply have this looking for the standard stat flags. The last packet in SENDPACKET Code: <HVAL <UID.<LOCAL.UID>.NOTOGETFLAG <UID>>> I hope it helps (and makes any sense at all!) lol. RE: NPCS - Town stones - Anarch Cassius - 07-11-2012 08:17 AM Don't forget this 09-10-2010, ShiryuX - Added: "TAG.OVERRIDE.NOTO" and "TAG.OVERRIDE.NOTO.$uid" as notoriety flag overrides. TAG.OVERRIDE.NOTO is a general override for the notoriety flag. TAG.OVERRIDE.NOTO.$uid overrides the noto flag according to the viewer $uid. * NOTE: The general override is applied before the viewer tag. So it will override EVERYTHING. Usable flags can be found on sphere_defs.scp RE: NPCS - Town stones - Skul - 07-11-2012 08:44 AM Oh ya, I haven't been online recently to try that out. I remember chatting about it, does it override completely? I remember using the code I posted above and having to call it in the walk packet (packet0x02), it was a super lag because sphere's default behavior would override the noto on every step. Although I did notice that NPCs did retain their NOTO color using sendpacket, so I thought of posting this. I'll have to try that new feature out, hopefully it works better than I could get it. Been trying to get guild wars going properly, also custom noto for team PvP events. Thanks Anarch, much appreciated! Quick question, CTAG.OVERRIDE.NOTO[.$uid] ??? RE: NPCS - Town stones - RanXerox - 07-11-2012 08:56 AM I presume if you set the $uid version after the global one you can un-override (or make special exceptions) for specific people (like your guildmates or party members etc.) RE: NPCS - Town stones - Skul - 07-11-2012 09:11 AM exactly Ran, then I'll have lingering tags (considering a player can delete his own character), CTAG would come in use, can always store the tags with 1 as well haha, but ya, just wondering! RE: NPCS - Town stones - RanXerox - 07-11-2012 09:24 AM I imagine the intended use for these overrides is for guilds, parties, and team sports... so that your guild buddies, party members, and team mates are always a particular color even if they accidentally hit you (or steal from your corpse, etc...) RE: NPCS - Town stones - Extreme - 07-11-2012 09:33 AM OMG! These tags are awesome. God bless ShiriuX hahahaha RE: NPCS - Town stones - Soulless - 07-11-2012 03:35 PM Oh thats super guys. thank you all for your help. This has resolved my issue and now everything is going quite swimmingly ![]() THANK YOU RE: NPCS - Town stones - Soulless - 07-12-2012 10:37 AM Just want to say thanks again guys, this worked out perfect and my custom faction system is in place perfectly. love the faction guards. just watching the chaos from taking control of a town is fun. the guards spawn, start attacking the old guards, just making new guards is a hoot, spearmen, horsemen, macers, archers, and mages and such. |