2022-06-25 01:32:32 +02:00
|
|
|
{% extends "packages/package_base.html" %}
|
|
|
|
|
|
|
|
{% block title %}
|
|
|
|
{{ _("Supported Games") }}
|
|
|
|
{% endblock %}
|
|
|
|
|
|
|
|
{% block content %}
|
2022-06-25 03:51:29 +02:00
|
|
|
<a class="float-right btn btn-secondary" href="{{ url_for('flatpage', path='help/game_support') }}">
|
|
|
|
{{ _("Documentation") }}
|
|
|
|
</a>
|
2022-06-25 01:32:32 +02:00
|
|
|
<h2 class="mt-0">{{ self.title() }}</h2>
|
2023-06-18 22:11:17 +02:00
|
|
|
<p>
|
|
|
|
{{ _("Game support is configured using the package's .conf file. See the documentation for more info") }}
|
2022-06-25 02:16:22 +02:00
|
|
|
</p>
|
2022-06-25 01:32:32 +02:00
|
|
|
|
|
|
|
<div class="list-group">
|
|
|
|
<div class="list-group-item">
|
|
|
|
<div class="row">
|
|
|
|
<span class="col-5">
|
|
|
|
{{ _("Package") }}
|
|
|
|
</span>
|
|
|
|
<span class="col-5">
|
|
|
|
{{ _("Source") }}
|
|
|
|
</span>
|
|
|
|
<span class="col-2 text-right">
|
|
|
|
{{ _("Supported?") }}
|
|
|
|
</span>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
2023-06-18 22:11:17 +02:00
|
|
|
{% if package.supports_all_games %}
|
|
|
|
<div class="list-group-item">
|
|
|
|
{{ _("Supports all games unless otherwise stated") }}
|
|
|
|
</div>
|
|
|
|
{% endif %}
|
|
|
|
|
|
|
|
{% for support in package.get_sorted_game_support() %}
|
2022-06-25 01:32:32 +02:00
|
|
|
<a class="list-group-item list-group-item-action"
|
2023-06-18 22:56:19 +02:00
|
|
|
href="{{ support.game.get_url('packages.view') }}">
|
2022-06-25 01:32:32 +02:00
|
|
|
<div class="row">
|
|
|
|
<span class="col-5">
|
|
|
|
{{ _("%(title)s by %(display_name)s",
|
|
|
|
title=support.game.title, display_name=support.game.author.display_name) }}
|
|
|
|
</span>
|
|
|
|
<span class="col-5">
|
|
|
|
{% if support.confidence == 1 %}
|
|
|
|
{{ _("Detected from dependencies") }}
|
2022-06-25 04:20:27 +02:00
|
|
|
{% elif support.confidence == 11 %}
|
2022-06-25 02:16:22 +02:00
|
|
|
{{ _("Added by Editor") }}
|
2022-06-25 01:32:32 +02:00
|
|
|
{% elif support.confidence == 10 %}
|
2023-06-19 23:33:45 +02:00
|
|
|
{{ package.get_conf_file_name() }}
|
2022-06-25 01:32:32 +02:00
|
|
|
{% else %}
|
|
|
|
{{ support.confidence }}
|
|
|
|
{% endif %}
|
|
|
|
</span>
|
|
|
|
<span class="col-2 text-right">
|
|
|
|
{% if support.supports %}
|
|
|
|
<span class="badge badge-success">Yes</span>
|
|
|
|
{% else %}
|
|
|
|
<span class="badge badge-danger">No</span>
|
|
|
|
{% endif %}
|
|
|
|
</span>
|
|
|
|
</div>
|
|
|
|
</a>
|
|
|
|
{% else %}
|
2023-06-18 23:57:24 +02:00
|
|
|
{% if not package.supports_all_games %}
|
|
|
|
<div class="list-group-item text-danger">
|
|
|
|
{{ _("Unknown. Please either add supported games or check 'Supports all games'") }}
|
|
|
|
</div>
|
|
|
|
{% endif %}
|
2022-06-25 01:32:32 +02:00
|
|
|
{% endfor %}
|
|
|
|
</div>
|
2022-06-25 02:16:22 +02:00
|
|
|
|
2022-06-25 04:13:36 +02:00
|
|
|
{% if mod_conf_lines %}
|
2023-06-19 23:33:45 +02:00
|
|
|
<h3>{{ _("Generated %(conf)s lines", conf=package.get_conf_file_name()) }}</h3>
|
2022-06-25 04:13:36 +02:00
|
|
|
<pre><code>{{ mod_conf_lines }}</code></pre>
|
|
|
|
{% endif %}
|
2022-06-25 02:16:22 +02:00
|
|
|
|
2022-06-25 03:27:51 +02:00
|
|
|
{% if form %}
|
|
|
|
<h2>Options</h2>
|
2022-06-25 02:16:22 +02:00
|
|
|
|
|
|
|
{% from "macros/forms.html" import render_field, render_checkbox_field, render_submit_field %}
|
|
|
|
<form method="POST" action="" class="tableform">
|
|
|
|
{{ form.hidden_tag() }}
|
|
|
|
|
2022-06-25 03:51:29 +02:00
|
|
|
{{ render_checkbox_field(form.enable_support_detection, disabled=force_game_detection) }}
|
|
|
|
{% if force_game_detection %}
|
|
|
|
<p class="text-muted">
|
|
|
|
{{ _("You need to manually define at least one supported game before you can turn this off.") }}
|
|
|
|
</p>
|
|
|
|
{% endif %}
|
2022-06-25 03:27:51 +02:00
|
|
|
|
2023-06-19 23:22:55 +02:00
|
|
|
{{ render_checkbox_field(form.supports_all_games, disabled=not can_support_all_games) }}
|
|
|
|
{% if can_support_all_games %}
|
|
|
|
<p class="text-muted">
|
|
|
|
{{ _("Unless otherwise stated, this package should work with all games.") }}
|
|
|
|
{{ _("You can check this and still specify games in supported_games that you've tested.") }}
|
|
|
|
</p>
|
|
|
|
{% elif package.type.name == "TXP" %}
|
|
|
|
<p class="text-muted">
|
|
|
|
{{ _("It's not possible for texture packs to support all games") }}
|
|
|
|
</p>
|
|
|
|
{% endif %}
|
2023-06-18 22:11:17 +02:00
|
|
|
|
|
|
|
{% if form.supported and form.unsupported %}
|
2022-06-25 03:27:51 +02:00
|
|
|
<h3>
|
2022-06-25 04:20:27 +02:00
|
|
|
{{ _("Editor Overrides") }}
|
2022-06-25 03:27:51 +02:00
|
|
|
<i class="ml-2 fas fa-user-edit"></i>
|
|
|
|
</h3>
|
|
|
|
{{ render_field(form.supported) }}
|
|
|
|
{{ render_field(form.unsupported) }}
|
|
|
|
{% endif %}
|
2022-06-25 02:16:22 +02:00
|
|
|
|
|
|
|
{{ render_submit_field(form.submit, class_="mt-4 btn btn-primary") }}
|
|
|
|
</form>
|
|
|
|
{% endif %}
|
2022-06-25 01:32:32 +02:00
|
|
|
{% endblock %}
|