• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.
  • Create a faction for Warcraft 3 and enter Hive's 19th Techtree Contest: Co-Op Commanders! Click here to enter!
  • Create a void inspired texture for Warcraft 3 and enter Hive's 34th Texturing Contest: Void! Click here to enter!
  • The Hive's 21st Texturing Contest: Upgrade is now concluded, time to vote for your favourite set of icons! Click here to vote!

String case error

Status
Not open for further replies.
Level 12
Joined
Dec 2, 2016
Messages
733
JASS:
  local string currPlayer
  loop
    exitwhen i > 11
    set players[i] = PlayerStruct.create(i)
   set currPlayer = GetPlayerName(Player(i))
   StringCase(currPlayer, true)
    if (ClanTag.checkMember(i, COLOR_ACCESS_1) and not ClanTag.checkMember(i, COLOR_ACCESS_NO_TAG)) then
      set players[i].name = "[VFG]"+GetPlayerName(Player(i))
    elseif currPlayer == "RUGARUSVF" or currPlayer == "DOMINGOS" or currPlayer == "FINEX" or currPlayer == "MADERYAR" or currPlayer == "SINDRICUS" or currPlayer == "THEHUMANHUNTER" or currPlayer == "MRGAJ" then
   set players[i].name = "[RG]"+GetPlayerName(Player(i))
   else
      set players[i].name = GetPlayerName(Player(i))
    endif

    set i = i + 1
  endloop


So the idea of this script is to convert each player's names to all caps and the if statement adds a clan tag onto their name if the name matches. But I get this error: Screenshot - 6ec2e5b4b8ed1dd1c3f0e4b1e2d04e94 - Gyazo

I assume I went about doing this wrong?

I'm trying to convert the string 'currPlayer' to all uppercase.
 
Status
Not open for further replies.
Top