mirror of
https://github.com/yairm210/Unciv.git
synced 2025-10-01 07:51:53 -04:00
Added "Community" tab in the menu, with links to the Github and Discord
This commit is contained in:
parent
fc41de7a83
commit
84bcfe2d39
@ -420,6 +420,8 @@
|
|||||||
French:"Construire [improvement]"
|
French:"Construire [improvement]"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
"Start Golden Age":{}
|
||||||
|
|
||||||
"Yes":{
|
"Yes":{
|
||||||
Italian:"Sì"
|
Italian:"Sì"
|
||||||
Russian:"Да"
|
Russian:"Да"
|
||||||
@ -619,6 +621,8 @@
|
|||||||
Japanese:"社会政策"
|
Japanese:"社会政策"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
"Community":{}
|
||||||
|
|
||||||
|
|
||||||
"Close":{
|
"Close":{
|
||||||
Italian:"Chiudi"
|
Italian:"Chiudi"
|
||||||
|
@ -422,13 +422,13 @@
|
|||||||
|
|
||||||
"Can construct roads":{
|
"Can construct roads":{
|
||||||
Italian:"Può costruire Strade"
|
Italian:"Può costruire Strade"
|
||||||
Simplified_Chinese:"可以建造道路"
|
Simplified_Chinese:"可以建造道路"
|
||||||
French:"Peut construire des routes"
|
French:"Peut construire des routes"
|
||||||
}
|
}
|
||||||
|
|
||||||
"Construct road":{ // for unit action button
|
"Construct road":{ // for unit action button
|
||||||
Italian:"Costruisci Strada"
|
Italian:"Costruisci Strada"
|
||||||
Simplified_Chinese:"建造道路"
|
Simplified_Chinese:"建造道路"
|
||||||
French:"Construire une route"
|
French:"Construire une route"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,17 +1,24 @@
|
|||||||
package com.unciv.app;
|
package com.unciv.app;
|
||||||
|
|
||||||
|
import android.content.Intent;
|
||||||
import android.os.Bundle;
|
import android.os.Bundle;
|
||||||
|
|
||||||
import com.badlogic.gdx.backends.android.AndroidApplication;
|
import com.badlogic.gdx.backends.android.AndroidApplication;
|
||||||
import com.badlogic.gdx.backends.android.AndroidApplicationConfiguration;
|
import com.badlogic.gdx.backends.android.AndroidApplicationConfiguration;
|
||||||
import com.unciv.UnCivGame;
|
import com.unciv.UnCivGame;
|
||||||
|
|
||||||
|
import static android.content.Intent.ACTION_VIEW;
|
||||||
|
|
||||||
public class AndroidLauncher extends AndroidApplication {
|
public class AndroidLauncher extends AndroidApplication {
|
||||||
@Override
|
@Override
|
||||||
protected void onCreate (Bundle savedInstanceState) {
|
protected void onCreate (Bundle savedInstanceState) {
|
||||||
super.onCreate(savedInstanceState);
|
super.onCreate(savedInstanceState);
|
||||||
AndroidApplicationConfiguration config = new AndroidApplicationConfiguration();
|
AndroidApplicationConfiguration config = new AndroidApplicationConfiguration();
|
||||||
String version = BuildConfig.VERSION_NAME;
|
String version = BuildConfig.VERSION_NAME;
|
||||||
|
|
||||||
|
|
||||||
|
Intent openInActionView = new Intent(ACTION_VIEW);
|
||||||
|
|
||||||
initialize(new UnCivGame(version), config);
|
initialize(new UnCivGame(version), config);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
package com.unciv.ui.worldscreen.optionstable
|
package com.unciv.ui.worldscreen.optionstable
|
||||||
|
|
||||||
|
import com.badlogic.gdx.Gdx
|
||||||
import com.unciv.UnCivGame
|
import com.unciv.UnCivGame
|
||||||
import com.unciv.models.gamebasics.tr
|
import com.unciv.models.gamebasics.tr
|
||||||
import com.unciv.ui.CivilopediaScreen
|
import com.unciv.ui.CivilopediaScreen
|
||||||
@ -53,9 +54,31 @@ class WorldScreenMenuTable(val worldScreen: WorldScreen) : PopupTable(worldScree
|
|||||||
remove()
|
remove()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
addButton("Community"){
|
||||||
|
WorldScreenCommunityTable(worldScreen)
|
||||||
|
remove()
|
||||||
|
}
|
||||||
|
|
||||||
addButton("Close".tr()){ remove() }
|
addButton("Close".tr()){ remove() }
|
||||||
|
|
||||||
open()
|
open()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
class WorldScreenCommunityTable(val worldScreen: WorldScreen) : PopupTable(worldScreen) {
|
||||||
|
init{
|
||||||
|
addButton("Discord"){
|
||||||
|
Gdx.net.openURI("https://discord.gg/bjrB4Xw")
|
||||||
|
remove()
|
||||||
|
}
|
||||||
|
|
||||||
|
addButton("Github"){
|
||||||
|
Gdx.net.openURI("https://github.com/yairm210/UnCiv")
|
||||||
|
remove()
|
||||||
|
}
|
||||||
|
|
||||||
|
addButton("Close".tr()){ remove() }
|
||||||
|
|
||||||
|
open()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user