示例#1
0
    void setCountry(ValidCountries.Country validCountry)
    {
        string       countryCode = ValidCountries.CountryToString(validCountry);
        ImageTexture texture     = new ImageTexture();

        texture.Load($"Resources/Graphics/Flags/{countryCode}.png");
        country.Texture = texture;
    }
示例#2
0
    void onTournamentInfoSent(string tournamentAlias, ValidCountries.Country country, int maxRate, int memberCount, string schemeName)
    {
        PackedScene         scene = (PackedScene)ResourceLoader.Load("Scenes/AdvancedComponents/TournamentInfoField.tscn");
        TournamentInfoField field = (TournamentInfoField)scene.Instance();

        Tournament data = new Tournament(tournamentAlias, country, maxRate, memberCount, schemeName);

        field.Initialize(data);

        tournamentsList.AddChild(field);
    }