User Tag List

Results 1 to 3 of 3

Thread: Ranking computer players in game

  1. #1
    No Products Registered

    Join Date
    Sep 2006
    Posts
    33
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Ranking computer players in game

    I am making a business sim, where at the end of the week, I
    need to list the player as well as the computer competitors
    in their rank of winning.
    I have all the work done as to how they achieve their positions, and assign their ranking, but what I need to know
    is how do I organize their rankings from 1-6, assign these rankings, and then assign the name of the competitor to that
    ranking so I can transfer the string to the end of week screen.
    I have six competitors listed as 1-6, and need to make the one with the highest rating #1, second #2, and so on. Thank you for any help you can give me.

  2. #2
    Clicker Multimedia Fusion 2 DeveloperiOS Export ModuleSWF Export ModuleUnicode Add-on

    Join Date
    Jun 2006
    Location
    Australia
    Posts
    988
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Ranking computer players in game

    You could use the list object to add the competitors names, ie:

    Code:
    1 - Ben
    2 - Scott
    3 - Michelle
    4 - Katy
    5 - Mike
    6 - Lemon
    By having the "Sort" property turned on it will automatically put them in the right order, so that you can simply add the players individually in any order.

    Then you have a string that displays:

    Code:
     List Line Text$( "List", 1)+NewLine$
    +List Line Text$( "List", 2)+NewLine$
    +List Line Text$( "List", 3)+NewLine$
    +List Line Text$( "List", 4)+NewLine$
    +List Line Text$( "List", 5)+NewLine$
    +List Line Text$( "List", 6)
    (Using 1-based index). This is really just "Display Line 1 plus a new line, then display line 2 plus a new line...". You could also use 6 strings if you wanted to.

    If you just want their names, and not the numbers then you can use:

    Code:
    Mid$(List Line Text$( "List", 1), 3, 99) + NewLine$ + ...
    (Cuts off the first 3 characters of the line)

  3. #3
    Clickteam Clickteam
    LB's Avatar
    Join Date
    Jun 2007
    Location
    Richardson, Texas, North America
    Posts
    8,937
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)

    Re: Ranking computer players in game

    You can also use Right$() to get the whole right except the left 3 characters.
    Working as fast as I can on Fusion 3

Similar Threads

  1. Setting up players/controllers for your game (single player)
    By colej_uk in forum XNA Specific Example Files
    Replies: 5
    Last Post: 26th March 2013, 01:21 PM
  2. ranking in the edit box
    By daniele in forum Multimedia Fusion 2 - Technical Support
    Replies: 7
    Last Post: 8th February 2012, 08:28 PM
  3. Multiplayer Online game and players from LAN
    By Greg in forum Multimedia Fusion 2 - Technical Support
    Replies: 7
    Last Post: 18th April 2010, 04:17 PM
  4. Rating computer players
    By DisneyBoy in forum Multimedia Fusion 2 - Technical Support
    Replies: 0
    Last Post: 28th February 2010, 05:13 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •