1.0.40 • Published 5 months ago
emykr-dotsmine v1.0.40
Dots. Mine Launcher
개요
Dots. Mine Launcher는 Minecraft 게임을 실행하고 관리하기 위한 Electron 기반의 런처입니다. Microsoft 계정을 통해 인증하고, 게임 파일을 관리하며, 사용자 프로필을 표시합니다.
설치 및 실행
요구 사항
- Node.js (v14 이상)
- npm 또는 yarn
설치
# 저장소 클론
git clone https://github.com/your-repo/dots-mine-launcher.git
cd dots-mine-launcher
# 의존성 설치
npm install
# 또는
yarn install
실행
# 개발 모드 실행
npm run dev
# 또는
yarn dev
# 빌드
npm run build
# 또는
yarn build
기능
- Microsoft 계정을 통한 인증
- Minecraft 게임 파일 관리
- 사용자 프로필 표시 및 관리
- 게임 설정 및 모드 관리
- 자동 업데이트 기능
API
인증 API
authenticate()
: Microsoft 계정을 통해 로그인합니다.checkAuth()
: 현재 인증 상태를 확인합니다.logout()
: 현재 계정에서 로그아웃합니다.
게임 파일 관리 API
launchGame(version: string, type: string)
: 특정 버전의 게임을 실행합니다.checkGameFiles(version: string, type: string)
: 특정 버전의 게임 파일을 확인합니다.
사용자 프로필 API
getUserProfile()
: 현재 사용자의 프로필 정보를 가져옵니다.updateProfile(data: object)
: 사용자 프로필을 업데이트합니다.
업데이트 API
checkForUpdates()
: 업데이트를 확인합니다.downloadUpdate(url: string)
: 업데이트를 다운로드합니다.
사용 방법
인증
const { ProjectLib } = require('./src/renderer/ProjectLib.js');
// 로그인
ProjectLib.authenticate().then(() => {
console.log("로그인 성공");
// 로그인 후 인증 상태 확인
return ProjectLib.checkAuth();
}).then((authStatus) => {
console.log("인증 상태:", authStatus);
}).catch((error) => {
console.error("로그인 또는 인증 상태 확인 실패:", error);
});
게임 파일 관리
const version = "1.16.5";
const type = "release";
// 게임 실행
ProjectLib.launchGame(version, type).then(() => {
console.log(`${version} 버전의 게임 실행 완료`);
// 게임 파일 확인
return ProjectLib.checkGameFiles(version, type);
}).then((fileStatus) => {
console.log(`${version} 버전의 게임 파일 상태:`, fileStatus);
}).catch((error) => {
console.error("게임 실행 또는 파일 확인 실패:", error);
});
사용자 프로필
// 사용자 프로필 가져오기
ProjectLib.getUserProfile().then((profile) => {
console.log("사용자 프로필:", profile);
// 프로필 업데이트
profile.nickname = "새 닉네임";
return ProjectLib.updateProfile(profile);
}).then(() => {
console.log("프로필 업데이트 완료");
}).catch((error) => {
console.error("프로필 가져오기 또는 업데이트 실패:", error);
});
업데이트
// 업데이트 확인
ProjectLib.checkForUpdates().then((updateInfo) => {
console.log("업데이트 정보:", updateInfo);
// 업데이트 다운로드
const updateUrl = updateInfo.url;
return ProjectLib.downloadUpdate(updateUrl);
}).then(() => {
console.log("업데이트 다운로드 완료");
}).catch((error) => {
console.error("업데이트 확인 또는 다운로드 실패:", error);
});
기여
기여를 원하시면 저장소를 포크하고 풀 리퀘스트를 제출해주세요. 버그 보고 및 기능 요청은 이슈 트래커를 이용해주세요.
라이선스
이 프로젝트는 Apache-2.0 라이선스 하에 배포됩니다.