Jump to content

Get Workshop Object with a certain Keyword on it


niston

Recommended Posts

Two appraches come to mind:

 

a) If the item is likely to be within the active 10,000 game unit radius of the player (from uGridsToLoad) then run a FindAllReferencesWithKeyword() area scan. If there is only one this should be a cheap call. Note Sanctuary/Specatle build areas are wider than 20K.

 

b) get the WorkshopREF via self.GetLinkedRef(WorkshopItemKeyword) then iterate the WorkshopREF.GetRefsLinkedToMe(WorkshopItemKeyword). This could be a bunch of processing.

Edited by SKK50
Link to comment
Share on other sites

No women, no children.

 

actually there is cunning plan C which is to use a disposable quest reference conditional fill to do the work, they can scan any active worldspace and are extremely fast and efficient as its an engine function rather than script abstraction.

Edited by SKK50
Link to comment
Share on other sites

"Near Alias: Select another Reference Alias on this quest - the Story Manager will run the conditions only on any references linked to that alias's ref."

 

Sounds great. Except where it says "(NOTE: Only linked refs with NO keyword are considered.)" at the end.

Link to comment
Share on other sites

I would not use the near alias, I'd use Find matching reference closest to none and do the linked ref and keywords in the conditions box.

 

There are a couple of base game quests that do this to pick owned Workshops without defense or recruitment beacons (or something like that).

 

HasLinkedRef or IsLinkedTo plus HasKeyword and adding GetIsID or GetIsObjectType will speed up the search.

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...