Jump to content

Hooks

Closed 2.4.7

phudgee
phudgee

Posted (edited)

Might just be me, but im having trouble getting  OnRaidableBaseCompleted to fire.

		[PluginReference] 
		private Plugin RaidableBases;
		
		private void OnRaidableBaseCompleted(Vector3 raidPos, int mode, bool allowPVP, string id, float spawnTime, float despawnTime, float loadTime, ulong ownerId, BasePlayer owner, List<BasePlayer> raiders, List<BasePlayer> intruders, List<BaseEntity> entities)
        	{
            	foreach(var r in raiders)
            	{
               	 Puts(r.displayName + " has finished a raid!");
            	}
        	}

i get nothing. In chat it says the player(s) beat the raid, but this never fires. 

 

Am I missing something? Or am i just an idiot?

 

 

Edited by phudgee
nivex

Posted

heya.

List<BaseEntity> entities

is actually HashSet<BaseEntity> entities

just an oversight that I forgot to change when I changed it to HashSet

i've fixed this in the next update.

however you can simply use :

private void OnRaidableBaseCompleted(Vector3 raidPos, int mode, bool allowPVP, string id, float spawnTime, float despawnTime, float loadTime, ulong ownerId, BasePlayer owner, List<BasePlayer> raiders)

 

phudgee

Posted

I think that did it! Thanks!

  • Like 1
nivex

Posted

Changed Status from Pending to Closed

1.6m

Downloads

Total number of downloads.

7.7k

Customers

Total customers served.

115.7k

Files Sold

Total number of files sold.

2.4m

Payments Processed

Total payments processed.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.