Badges and the displaying thereof

Nao

  • Dadman with a boy
  • Posts: 16,082
Re: Badges and the displaying thereof
« Reply #45, on March 30th, 2012, 10:22 AM »
Yeah, post-count groups *are* perverted in some way, I myself am known for spamming some boards when I was close to getting into a 'good' post group, and even becoming silent when I was close to getting out of it :P

Arantor

  • As powerful as possible, as complex as necessary.
  • Posts: 14,278
Re: Badges and the displaying thereof
« Reply #46, on March 30th, 2012, 11:22 AM »
Well, I'd love to have such groups, where groups are based on different criteria (I've seen 'time based' and 'karma based' done as mods) Though doing it is not simple.

Mind you, the whole way post count groups is handled is very awkward and special, and has all sorts of interesting risks, namely that it is possible to get users who are true admins by misconfiguring or attempting to remove all the post count groups.

Then there's the matter of post group permissions. Or even like-count group permissions. Is that a route we'd want to go down potentially?
When we unite against a common enemy that attacks our ethos, it nurtures group solidarity. Trolls are sensational, yes, but we keep everyone honest. | Game Memorial

Nao

  • Dadman with a boy
  • Posts: 16,082
Re: Badges and the displaying thereof
« Reply #47, on March 30th, 2012, 11:31 AM »
I don't know, I think that user-owned groups (for starters) will only get to modify a few of the settings -- basically, the first half of the settings in the membergroup edit page. They will also be able to edit their permissions, I guess, for their own user-created boards. It gets complicated, I know, but it makes sense as well to give users freedom... Otherwise there's no point in implementing blogs or anything. Because that's really what all other forums (except for Noisen but it's pretty much proto-Wedge anyway :P) do WRONG IMHO: they consider that blogs are only to be created by forum admins, or they provide blogs to their users but they're extremely limited, e.g. they can only have one blog, public viewing, etc... I haven't looked much into other forum+blog solutions, but they all seemed to be that limited.

Could you give your opinion on that post, btw..?
http://wedge.org/pub/feats/7108/badges-and-the-displaying-thereof/msg276657/#msg276657

Arantor

  • As powerful as possible, as complex as necessary.
  • Posts: 14,278
Re: Badges and the displaying thereof
« Reply #48, on March 30th, 2012, 11:42 AM »
User-owned groups is something else again on top of the other types of groups mentioned.

The post you linked, it does pretty much cover everything, I think.

Nao

  • Dadman with a boy
  • Posts: 16,082
Re: Badges and the displaying thereof
« Reply #49, on March 30th, 2012, 12:46 PM »
"On top"? You mean, additional groups?

And my post doesn't cover what to do when the group is Additional or Primary, though... Ah ah.

Arantor

  • As powerful as possible, as complex as necessary.
  • Posts: 14,278
Re: Badges and the displaying thereof
« Reply #50, on March 30th, 2012, 12:50 PM »
We've managed to talk about several very very different things.

On the one hand, is user-created groups. A lot of that is UI fluff. I'd argue that the badges for these should never be shown (mind you I don't see that you'd ever have badges for them in the first place, eh)

On the other hand is groups based on other criteria that isn't assigned and isn't posts, e.g. likes. Or number of topics created. Or number of attachments posts. Or total time logged in. Or karma if we still had it. This is where it becomes painfully obvious that there are problems in the post count group setup, in terms of extensibility, usability and reliability. As I've alluded to, it's possible to make people admins *by accident* by screwing up the post count groups.

Which means, then, perhaps we want to rethink how post count groups are actually managed, and not make them groups in the current conventional sense. It does also suggest rethinking how such permissions are determined, too.

Nao

  • Dadman with a boy
  • Posts: 16,082
Re: Badges and the displaying thereof
« Reply #51, on March 30th, 2012, 01:04 PM »
Quote from Arantor on March 30th, 2012, 12:50 PM
We've managed to talk about several very very different things.
I didn't mix it up, for once!
Quote
On the one hand, is user-created groups. A lot of that is UI fluff. I'd argue that the badges for these should never be shown (mind you I don't see that you'd ever have badges for them in the first place, eh)
Badges are set up in the second half of the membergroup editor, so I was implying that custom membergroups shouldn't be able to have badges. :)
Perhaps it could be done, but I suspect through a plugin maybe. By default it really would be opening the door to abuse. e.g. I'll just create 30 groups with a badge and put myself into them :P
(Hmm, would be interesting to ensure that groups you create, you CANNOT join. Any access permissions given to it for your items are automatically given to you anyway, as you're the author...)
Quote
On the other hand is groups based on other criteria that isn't assigned and isn't posts, e.g. likes. Or number of topics created. Or number of attachments posts. Or total time logged in. Or karma if we still had it. This is where it becomes painfully obvious that there are problems in the post count group setup, in terms of extensibility, usability and reliability. As I've alluded to, it's possible to make people admins *by accident* by screwing up the post count groups.
I guess it's something that could be replaced with, I don't know, a wizard like your moderation filters... "If person reaches (X) (Posts/Topics/Likes/Attachments/Media items/etc.), use this group for them: ..."
Eh, what am I talking about... No one would use that anyway. :P
Quote
Which means, then, perhaps we want to rethink how post count groups are actually managed, and not make them groups in the current conventional sense.
That's an interesting remark. But I'm afraid it's not going to be a successful change. User groups are more 'interesting' for admins generally than other X-based groups because they imply seniority. If someone has 3 posts on my forum, I'm less likely to give them access to my private parts blog or something. (Not that I have such a blog, ah ah.) While if someone has 150 likes on different posts, they'll usually be well known in the forum and thus will probably be assigned some custom group anyway.

Perhaps what could be done, though, is to instigate a "minimum post count" setting that would be quite global to the forum. Anywhere you can set up a membergroup, you could also set up a minimum post count check that is done after the membergroup check. That setting could be kept either in a new field in most tables, or simply in a new table with a content_type field or something.

But, quite honestly, I think that id_post_group is... relatively well known now, and perhaps it would put off admins if we removed the system entirely. Like, it might give some users access to areas they previously didn't know about...

Farjo

  • "a valuable asset to the community"
  • Posts: 492
Re: Badges and the displaying thereof
« Reply #52, on March 30th, 2012, 09:30 PM »
Quote from Nao on March 29th, 2012, 03:24 PM
I'm now considering this...
Yes that all sounds great, exactly what I'm after and there's lots of flexibility there for everyone.
Quote
- Show rank image(s) in user box?
      - Always
      - Only if it's the only one
      - Never (Hmm maybe not that option... User could set the thing to 0... Unless they find it confusing to do...)
Haha yes 'Never' for the confused - although perhaps people could set it all up, with the correct image address, before switching it on later?

"How about Like based groups?" It would be cool to have a group for members who joined over x years ago, have at least y posts, and more than z time online as these would be old members who have stuck around and contributed.
But as Arantor hints it would be a bastard to set up and the support would be a never ending stream of user / set-up errors.

Thanks :)

Arantor

  • As powerful as possible, as complex as necessary.
  • Posts: 14,278
Re: Badges and the displaying thereof
« Reply #53, on March 30th, 2012, 09:37 PM »
There already are a lot of issues with users screwing it up, which means I'm inclined to simplify it, so that instead of the current approach, we actually don't have physical groups for post counts etc.

Instead, we have it such that rules are created:
* if user has 0-9 posts, show this badge/title
* if user has 10-100 posts, show this badge/title

Then we can start applying something similar to permissions - but tying it to the permission rather than the group. So for permissions, for example, permission to do X can be 'user in these groups, or has post count of at least X', similar to the power of the moderation filters system.

The only trick is doing it efficiently.

But it wouldn't be hard to stack post count badges with other badges with this set up.

Farjo

  • "a valuable asset to the community"
  • Posts: 492
Re: Badges and the displaying thereof
« Reply #54, on March 30th, 2012, 09:57 PM »
I think I see. Reminds me of a quote (something like) "I spent a week on a ship with Albert Einstein who every day tried to explain his relativity theory, and at the end of the week I was convinced he understood it"

Arantor

  • As powerful as possible, as complex as necessary.
  • Posts: 14,278
Re: Badges and the displaying thereof
« Reply #55, on March 30th, 2012, 10:08 PM »
This is essentially it. I can tell you exactly how every part of the groups system works under the hood. And you'd be convinced I understood it. (You would be right, heh) But I doubt I could explain it sufficiently well to explain it to other people.

For example, as I mentioned, it's possible to screw up the post count groups such that a user could actually become an admin. I can tell you not only what circumstances cause this, I can tell you why those circumstances cause it. But if I were to do so, you'd look at me like I was some kind of loon.

But I do have to wonder whether that level of complexity is really necessary.

Nao

  • Dadman with a boy
  • Posts: 16,082
Re: Badges and the displaying thereof
« Reply #56, on March 31st, 2012, 02:42 PM »
Quote from Arantor on March 30th, 2012, 09:37 PM
The only trick is doing it efficiently.
I think the UI work would be a nightmare, in terms of UX.
SMF's is not perfect, but it would be much worse I reckon.

We should probably stick to physical groups for now... And if we change that in the future, well... We can always add this to the update script.
Re: Badges and the displaying thereof
« Reply #57, on June 3rd, 2012, 02:40 PM »
Bump for this.
I'm currently in the process of reviewing my code for badges and went into rewriting loadMemberContext(). First of all I renamed $display_custom_fields to $full_profile because essentially custom fields are only shown in user boxes, i.e. Display and PM pages. Now I can use that to determine when I should hide or show a badge etc... (Because we're not always planning to show a badge, so why waste time calculating this?)
Problem is -- if I store badge settings per group, I have to: (1) retrieve the list of additional groups (in addition to the main one), (2) ensure groups are self-aware that they're primary or additional (after all, one may want to set badges to show only if the group is a primary one....), (3) load badge settings for every single group. --> this would certainly require a cache...?
The 2 first steps are okay, but the 3rd step depends on several things... Loading a cache in loadMemberContext() may be a bit overkill. Also, with custom group, we may end up with a very large group cache file.

Suddenly I'm not sure this is such a good idea... :^^;:
Quote from Nao on March 29th, 2012, 03:24 PM
I fear I killed the conversation with my above post. It wasn't so scary was it...?

So, I resumed work on this. I implemented the feature, re-enabled 'conditional post-based' like the original default, and figured that there are probably better ways for everyone to implement this.

I'm now considering this...
For EACH membergroup, if you create/modify them, Wedge could give you several additional options (that would be accessible only to group moderators and administrators, just in case we add the ability for everyone to create their own membergroups later.)
As follows:

- Visibility (it's already a feature, I'm just pointing out we have this.)
- Show group in user box?
      - Always
      - Only if it's the only one (<-- should be set by default for post-based groups?)
      - Never (a bit like Visibility, but only for group text)
- Show rank image(s) in user box?
      - Always
      - Only if it's the only one
      - Never (Hmm maybe not that option... User could set the thing to 0... Unless they find it confusing to do...)

Any opinions?

Arantor

  • As powerful as possible, as complex as necessary.
  • Posts: 14,278
Re: Badges and the displaying thereof
« Reply #58, on June 3rd, 2012, 03:32 PM »
Well, loading additional data in loadMemberData is not a big deal (it's only one extra field at this point). The cache of fields/positions etc can be pulled from the membergroups table in probably a single query.

I'd argue that for the purposes of displaying multiple groups, you don't actually have to care about primary/secondary, but rely totally on the order specified in the membergroups themselves, for badges that shouldn't be displayed, store their position as 0, for all others store their position as 1+ to indicate the position, then just query the table WHERE position > 0 ORDER BY position, and you get that information pre-sorted too.

It wouldn't necessarily *require* a cache but I'd cache it.

Nao

  • Dadman with a boy
  • Posts: 16,082
Re: Badges and the displaying thereof
« Reply #59, on June 3rd, 2012, 07:36 PM »
That would make impossible to have badge display depend on other badges being shown or not....?
eg only show a post group badge if no primary group is set
or only show a post group badge if no other group is set
etc...

also, lmc() doesn't do the actual requests so it'd require doing an extra request, i think...