[SM Plugin] Squad Control

Discussion in 'Coding' started by Mikleo, Apr 5, 2017.

  1. Kidpaler

    Kidpaler Member

    Messages:
    738
    Likes Received:
    58
    Trophy Points:
    0
    Like I said, I like this plugin, but the more you divide up the channels the more confusing it gets for everyone. If it were to be implemented into base game I'd hope something like (Squad) could be added next to the icon of the person talking to indicate it is squad chat.
     
  2. flasche

    flasche Member Staff Member Moderator

    Messages:
    13,299
    Likes Received:
    168
    Trophy Points:
    0
    thats my whole point exactly. this plugin is damn useful, but you only can have some features if they get added to the base game - manly gui stuff, but also not having to rely on prefixes for squadchat f.e. (at least i think so, correct me if im wrong)
     
  3. Mikleo

    Mikleo Member

    Messages:
    155
    Likes Received:
    98
    Trophy Points:
    0
    I mean of course they would change the color etc of the speaking icons and hud elements.
    I don't see how it gets confusing when the sound at the start of the speech clearly indicates that they are using squad voice. They could even apply a filter over the sound to make it sound different and add some background stuff. There are plenty of things they can do and there are already many games that use separate channels of communication. Take the game "Squad" for example, squadleaders can communicate to each other a separate channel than they can speak to their squad.

    Flasche you're right about prefixes, there is nothing i can do about them really. I tried for a long time to look into a way of binding a key but i couldn't find one. All I needed was a bind that would open the chat box and toggle squad_chat_only. however bind x "say_team;squadchatonly 1 " doesn't open a chat box.
     
    Last edited: Apr 12, 2017
  4. Xyaminou

    Xyaminou Member

    Messages:
    1,369
    Likes Received:
    156
    Trophy Points:
    0
    22:14 - Desert Yinglet: Why the SL vote is not N-1 ?
    22:14 - Desert Yinglet: to be more precisie
    22:15 - Mr. X.: I don't know, ask Mikleo
    22:15 - Mr. X.: I think 3 votes is fine
    22:15 - Desert Yinglet: (if squad player count N+2) N-1 vote to change leader
    22:15 - Desert Yinglet: no no no
    22:16 - Desert Yinglet: That ways it does like if the squad is full
    22:16 - Desert Yinglet: with a dynamic count, it works from 3 player (where it needs 2 votes to change)
    22:17 - Desert Yinglet: but since its a small sperectum it could be done manually
    22:17 - Desert Yinglet: like squad of 3 player = 2 votes
    22:17 - Desert Yinglet: 4 player = 3 votes
    22:17 - Desert Yinglet: 5 players = 3 vote
    22:21 - Mr. X.: You should post that on the forums in mikleo's squadcontrol thread or on my issue tracker
    22:21 - Desert Yinglet: I dont use forums
    22:21 - Desert Yinglet: even since from 2008
    22:21 - Desert Yinglet: its not a place of equal grounds
     
  5. Mikleo

    Mikleo Member

    Messages:
    155
    Likes Received:
    98
    Trophy Points:
    0
    Generally that was my original idea to set it as 51% of players but I never got around to it. That is effectively the same thing. The issue was if someone leaves a squad I don't want someone to automatically be made leader, so they would have to be aware that they needed to vote again in order to change leader. But yea I planned to do that but no one asked for it so I kinda forgot.
     
  6. Kidpaler

    Kidpaler Member

    Messages:
    738
    Likes Received:
    58
    Trophy Points:
    0
    There's a big difference though, those games have the means to explain these different systems right off the bat. Empires doesn't even have a comprehensive tutorial.

    Perhaps an Arma style system would work best? That's pretty obvious.
     
  7. Xyaminou

    Xyaminou Member

    Messages:
    1,369
    Likes Received:
    156
    Trophy Points:
    0
    Request:
    Add colors to the plugin for the messages sent to everyone and for the squad/commander messages. Commander and Squad messages should be a different blue or red depending on if you're NF or BE.
     
  8. Mikleo

    Mikleo Member

    Messages:
    155
    Likes Received:
    98
    Trophy Points:
    0
    v0.5
    fixed some bugs
    added proper colors
    added a few more error messages
    added a more pronounced sound for comm alert.
    refiring events that should fix comm vote numbers for joining players.

    plugin now depends on votetime ^0.3
     
  9. Mikleo

    Mikleo Member

    Messages:
    155
    Likes Received:
    98
    Trophy Points:
    0
    I think refiring the comm vote events has caused client crashes, probably on some edge case. until I understand why the feature has been disabled. sc_fixcommvotes defaults to 0 for now.

    If a dev can give me some insight about the crash dump that would be cool.
     
  10. Thexa4

    Thexa4 Developer Staff Member Moderator

    Messages:
    304
    Likes Received:
    98
    Trophy Points:
    0
    It tried to set text on non-existent labels on the comm vote screen, you probably skipped some setup code. I couldn't see more from the crash dump than that.

    To be more precise, it was missing player name labels.
     
  11. Mikleo

    Mikleo Member

    Messages:
    155
    Likes Received:
    98
    Trophy Points:
    0
    Oh wait I remember finding a strange quirk with the commander_vote event while I was trying to get it working. For some reason it sends (client index -1) through the event instead of the actual client index. I had to correct that with the event but i forgot about it when resending them.

    So if the client stored them from 0-63, when a 64 index came through there might be a problem. maybe no label like you said. Thanks for the information. It was probably broken anyway if the indexes were wrong.
     
  12. Mikleo

    Mikleo Member

    Messages:
    155
    Likes Received:
    98
    Trophy Points:
    0
    I'm thinking about working in an alert if a player becomes squadleader. It was suggested to me but I don't know if the devs have it planned or not.
     
    Avatarix and Neoony like this.
  13. Mikleo

    Mikleo Member

    Messages:
    155
    Likes Received:
    98
    Trophy Points:
    0
    0.6

    Bug fixes
    An alert sound and text message when you become squad leader.
     
    Neoony, Avatarix and Xyaminou like this.
  14. Mikleo

    Mikleo Member

    Messages:
    155
    Likes Received:
    98
    Trophy Points:
    0
    0.61

    Ok right. Sourcemod actually intends that /command and !command work even in teamchat. The reason why it doesen't work in empires is that the client appends coordinates to the start of the message. Squadcontrol fixes that issue so that you can use !command and /command even in teamchat. This gets rid of the silly confusion around everyone using !squadinfo and !sl in team chat, now they will actually work. Hooray!

    Fixed some chat conflicts. The most common is the elipsis '...', even I used that. This will no longer trigger comm chat. '; )' , ';P' and ';D' will also not trigger squad chat.

    You can now use !commander [opposite team] after the round has ended.

    I also found a simpler way of using squad chat and comm chat.

    bind "semicolon" "say_team"
    bind . "say_team"

    This means all you have to do is press the same button twice to use squad chat or comm chat.
     
    Last edited: Apr 29, 2017
  15. Mikleo

    Mikleo Member

    Messages:
    155
    Likes Received:
    98
    Trophy Points:
    0
    0.62

    Fixed issue with squadleader alert.
    Added !squadskills, which tells you what skills everyone in your squad is using. However like your class, this doesn't update properly during the commander vote, It will only show when you actually spawn.
     
  16. Mikleo

    Mikleo Member

    Messages:
    155
    Likes Received:
    98
    Trophy Points:
    0
    0.7
    /move [coordinates]
    /attack [coordinates]

    Issue squad move or attack commands before the game has started, while your dead or where you can't see.
    subcoordinates 1-9. 1 is top left, 9 is bottom right. so /move a1-9 is the bottom right of the a1.

    /squadpos
    Displays the coordinates of everyone in your squad.
     
    Xyaminou and Neoony like this.
  17. Mikleo

    Mikleo Member

    Messages:
    155
    Likes Received:
    98
    Trophy Points:
    0
    Was planning on adding a couple of things which I didn't get time for, maybe next week.
    /move @[squad] coordinates
    For commander to move squads before the game.

    And commander objectives which stay at the top of the screen for up to 4 minutes. These are like short pieces of text.
    e.g.
    "A:NW B+C:Center D:RUINS"
    "Get Light Tanks"
    "Defend City take NW"
    "DEFEND MAIN"
    or w/e
    Text is too big for my liking though, but I can't change the size unfortunately.
     
  18. Mikleo

    Mikleo Member

    Messages:
    155
    Likes Received:
    98
    Trophy Points:
    0
    Currently thinking about changing it so that any message that the commander sends comes with a sound and they don't need to use .[message] for this. Any thoughts?
     
  19. D.D.D. Destroyer

    D.D.D. Destroyer Member Staff Member Moderator

    Messages:
    9,509
    Likes Received:
    111
    Trophy Points:
    0
    Personally, I'm against this, I'm a pretty talkative person in general and tend to write a lot of useless things.
     
  20. Mikleo

    Mikleo Member

    Messages:
    155
    Likes Received:
    98
    Trophy Points:
    0
    So you write a lot of useless things in team text chat when your commanding a game? I think most irrelevant conversation happens in all chat tbh.
     

Share This Page