jobsofferings-backgammon
v1.0.1
Published
this is my backgammon game
Downloads
1
Readme
五子棋游戏 backgammon game
[TOC]
中文
这是 jobsofferings 做的一个移动端五子棋小游戏,请使用手机体验。
中文更新日志
- 2020-4-10 第一次更新
做好了一个JavaScript五子棋游戏,暂时未做专业美化,暂时无悔棋、对战双方显示、人机对战功能,将在后续持续更新, 敬请期待!
- 2020-4-10 功能修改
修改了JS文件的导入方式,修改了README.md文件
使用方法
先使用以下命令下载npm包
npm install jobsofferings-backgammon --save-dev
在node_modules
会出现这个文件夹jobsofferings-backgammon
,里面有对应JS文件,导入即可
假设
目录
node_modules/
jobsofferings-backgammon/
// some files
index.html
package.json
...
html文件导入JS
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport"
content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
<title>backgammon</title>
</head>
<body>
<div id="chess"></div>
<script src="./node_modules/jobsofferings-backgammon/index.js"></script>
<script>
const chess = document.getElementById('chess');
const fiveChess = FiveChess.getInstance(chess, 420)
fiveChess.init();
</script>
</body>
</html>
English
This is a backgammon game made by jobsofferings, please use mobile phone experience.
English update logs
- 2020-4-10 First update
We have completed a JavaScript Gobang game, which has not been professionally beautified for the time being. There are no regrets for chess, display of both sides of the match, and man-machine match function. It will be updated in the future, so stay tuned!
- 2020-4-10 Function modification
Modified the import method of JS file, modified the README.md file
How to use?
First download the npm package using the following command
npm install jobsofferings-backgammon --save-dev
This folder jobsofferings-backgammon
will appear in node_modules
, there is a corresponding JS file. Just import it.
Suppose
table of Contents
node_modules/
jobsofferings-backgammon/
// some files
index.html
package.json
...
HTML file import JS
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport"
content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
<title>backgammon</title>
</head>
<body>
<div id="chess"></div>
<script src="./node_modules/jobsofferings-backgammon/index.js"></script>
<script>
const chess = document.getElementById('chess');
const fiveChess = FiveChess.getInstance(chess, 420)
fiveChess.init();
</script>
</body>
</html>