Support filtering entities by FTBTeams
bartico6 opened this issue · 4 comments
Describe the feature
Much like the team
filter parameter seen here...
... it would be useful if you could filter entities by which FTBTeams team they are associated with.
Obviously, the namings and parameters are TBD, but some examples I can think of would be:
In the following examples, "your team" refers to the team of the drone's owner.
ftbteams_member=yes|no
Match players who are or aren't members of your team.
ftbteams_ally=yes|no
Match players who are or aren't allies of your team.
ftbteams_associate=yes|no
Match players who are or aren't associates (members OR allies - basically any "friendlies") of your team
ftbteams_team=team_guid|no
Match players who are part of that specific team, or teamless.
Reasons why it should be considered
Vanilla Minecraft teams are seldom used on modded servers, usually in favour of FTBTeams or some other team mod - it appears that FTB Teams are by far the most dominant choice modpack authors opt for, so supporting it would probably make a lot of sense for people who want an easy way to exclude their team from war crimes being attacked by drones, or include only their team in drones picking them up to fly them somewhere etc.
Additional details
I'm not sure if you can chain modifiers in parenthesis (@player(ftbteams_team=SOME-GUID-HERE,ftbteams_ally=yes)
) but if you cannot, support for this would likely help this tag in particular if you want to, let's say, target two specific teams on the server and nobody else - although you can probably do this already by having two separate target specifiers with their own modifier each.
Adding FTB teams filtering is easy, but not in the way you suggest; there is no context, so "your team" doesn't actually mean anything here. The entity filter modifier method takes an Entity
to be tested, and a String
, which is parsed by the method as needed to perform a match on the entity.
So I can easily add for example @player(ftbteam=<short-team-name>)
or @player(ftbteam=<team-id>)
but there's no concept of "your team" here.
Update: I can add a few modifiers here:
ftbteam
- check for member or betterftbteam_officer
- check for officer (or owner)ftbteam_owner
- check for ownerftbteam_ally
- check for ally or betterftbteam_enemy
- check for enemy (and only enemy)
I mentioned it in the original post that "your team" is supposed to mean team of drone owner - but I keep forgetting that drones aren't the only thing using entity filters - in the case of micromissiles it'd be the thrower etc but I agree it's probably unnecessarily complex to do, and specifying just team id or shortname is better ❤️
Either way, appreciate the change, I hope others find it as useful as me :D
Edit: Forgot you keep issues open until release, my mistake for closing it.
No worries. Having done some playtesting, the other thing that's needed is an easier way to get the FTB Teams id/shortname... which is a feature for FTB Teams 😄 Mostly like "copy team id to clipboard" / "copy team shortname" button somewhere in the teams GUI. Will make it easier to paste into entity filter textfields.