Skocz do zawartości
  • 👋 Witaj na MPCForum!

    Przeglądasz forum jako gość, co oznacza, że wiele świetnych funkcji jest jeszcze przed Tobą! 😎

    • Pełny dostęp do działów i ukrytych treści
    • Możliwość pisania i odpowiadania w tematach
    • System prywatnych wiadomości
    • Zbieranie reputacji i rozwijanie swojego profilu
    • Członkostwo w jednej z największych społeczności graczy

    👉 Dołączenie zajmie Ci mniej niż minutę – a zyskasz znacznie więcej!

    Zarejestruj się teraz

[Pytanie] Jak podłączyć skript pod MySql ?


*RadIoActiVe

Rekomendowane odpowiedzi

Opublikowano

Jak podłączyć skript pod MySql ?

To jest kod:

# ==== Variables ====

variables backup interval: 2 hours
# If this is set to something other than 0 the variables file will be backed up repeatedly.
# Please note that variables are saved constantly no matter what is set here.
# Backing up the file could cause Skript to hang while the backup is created. This does likely not happen if your server is running Java 7 though.

database:
	# Database to store variables in. This can either be used as a simple one-server-storage
	# where variables are written constantly but only read at server start,
	# or as a connection between multiple servers by monitoring the database for changes.
	# !! Please note that this feature is experimental, i.e. might contain severe bugs!
	
	# Please also note that '/skript reload' will not reload this section, i.e. you'll have to restart Skript for changes to take effect.
	
	type: SQLite
	# The type of the database. Currently only MySQL and SQLite are supported. Use 'none' for Skript's default CSV flatfile storage.
	
	pattern: db_.*
	# If you only want to store part of your variables in the database (e.g. only player stats), set this pattern to match only those variables.
	# Variables that don't match the pattern will be saved in the default flatfile format.
	# This pattern uses Regex syntax, e.g. use 'db_.*' (without the quotes) to store all variables prefixed with 'db_' in the database,
	# or use '.*' (the default value) to store all variables in the database.
	
	monitor changes: false
	monitor interval: 20 seconds
	# If 'monitor changes' is set to true, variables will repeatedly be checked for updates in the database (in intervals set in 'monitor interval').
	# ! Please note that you should set 'pattern', 'monitor changes' and 'monitor interval' to the same on all servers that access the same database!
	
	# MySQL configuration
	host: localhost <-- i host do maszyny localhost
	port: 3306 <-- port mysql podstawowy 3306
	user: root <-- Uzytkownik
	password: pass <-- haslo
	database: skript <-- nazwa bazy danych
	
	# SQLite configuration
	file: ./plugins/Skript/variables.db
Opublikowano
# MySQL configuration
host: localhost <-- Nazwa hosta
port: 3306 <-- port mysql podstawowy 3306
user: root <-- Uzytkownik
password: pass <-- haslo
database: skript <-- nazwa bazy danych

# SQLite configuration
file: ./plugins/Skript/variables.db
 

 

 

type: SQLite
 

Zmieniasz na

 

 

type: MySQL
 

Zarchiwizowany

Ten temat przebywa obecnie w archiwum. Dodawanie nowych odpowiedzi zostało zablokowane.

×
×
  • Dodaj nową pozycję...