• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

[Trigger] Kick

Status
Not open for further replies.
First off, how did you do that? It's fancy :D

Secondly, yeah, there is a way to optimize that.

  • Trigger1
  • Events
    • Map Initialization
  • Conditions
  • Actions
    • For each (IntegerA) from 1 to 12, do (Actions)
      • Loop - Actions
        • Trigger - Add to Trigger2 <gen> the event (Player - Player(IntegerA) types a chat message containing -kick as An exact match)
  • Trigger2
  • Events
  • Conditions
    • (Triggering player) Equal to Host
  • Actions
    • For each (IntegerB) from 1 to 12, do (Actions)
      • Loop - Actions
        • If (All conditions are true) then do (Actions) else do (Actions)
          • If - Conditions
            • ((Player(IntegerB) slot status) Equal to Is playing) and ((Player(IntegerB) Not equal to (Triggering player))
          • Then - Actions
            • Dialog - Create a dialog button for DialogMenu2 labelled (Name of Player(IntegerB))
            • Set DialogButton2[(IntegerB)] = (Last created dialog Button)
          • Else - Actions
    • //Rest actions, for the dialog
To get Player(IntegerA) and Player(IntegerB), when it asks for a player input, scroll to Conversion - Convert Player Index to Player.
 
Level 18
Joined
Jan 21, 2006
Messages
2,552
Indeed, very fancy. Though it takes up a hell of a lot of room on the page. It seems like it only works on things that are in tags, as plain text just results in a blank post.
 
Status
Not open for further replies.
Top