html5 open source game,GitHub - undarkness/freeciv-web: Freeciv-web is an Open Source strategy game ...

THE FREECIV-WEB PROJECT

6b8d58f576c7e95b24aade71c8025758.png

68747470733a2f2f696d672e736869656c64732e696f2f6c67746d2f67726164652f6a6176617363726970742f672f667265656369762f667265656369762d7765622e7376673f6c6f676f3d6c67746d266c6f676f57696474683d3138

68747470733a2f2f696d672e736869656c64732e696f2f6c67746d2f616c657274732f672f667265656369762f667265656369762d7765622e7376673f6c6f676f3d6c67746d266c6f676f57696474683d313868747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c6963656e73652d4147504c25323076332d626c75652e737667

Freeciv-web is an open-source turn-based strategy game. It can be played in any HTML5 capable web-browser and features in-depth game-play and a wide variety of game modes and options. Your goal is to build cities, collect resources, organize your government, and build an army, with the ultimate goal of creating the best civilization. You can play online against other players (multiplayer) or play by yourself against the computer. There is both a HTML5 2D version with isometric graphics and a 3D WebGL version of Freeciv-web.

Live servers

Currently known servers based on Freeciv-web:

moving borders (Everything except longturn and real-Earth)

License

Freeciv-web is free and open source software. The Freeciv C server is released under the GNU General Public License, while the Freeciv-web client is released under the GNU Affero General Public License. See License for the full license document. By contributing to the Freeciv-web project, you must accept that your contibutions are also AGPL licensed. Contributions including code, graphics and rulesets are also AGPL.

Screenshots

Freeciv WebGL 3D:

741f558d86416c398c1830011e078a19.png

Freeciv-web HTML5 version:

freeciv-web-screenshot.png

System Overview

Freeciv-Web consists of these components:

Freeciv-web - a Java web application for the Freeciv-web client.

This application is a Java web application which make up the application

viewed in each user's web browser. The Metaserver is also a part of this module.

Implemented in Javascript, Java, JSP, HTML and CSS. Built with maven and runs

on Tomcat 8 and nginx.

Freeciv - the Freeciv C server forked for Freeciv-web. Implemented in C with a WebSocket/JSON protocol.

Freeciv-proxy - a WebSocket proxy which allows WebSocket clients in Freeciv-web

to send socket requests to Freeciv servers. WebSocket requests are sent from Javascript

in Freeciv-web to nginx, which then proxies the WebSocket messages to freeciv-proxy,

which finally sends Freeciv socket requests to the Freeciv servers. Implemented in Python.

Publite2 - a process launcher for Freeciv C servers, which manages

multiple Freeciv server processes and checks capacity through the Metaserver.

Implemented in Python.

pbem is play-by-email support.

freeciv-earth is code to generate Freeciv savegames from a map captured from mapbox.

Freeciv WebGL

Freeciv WebGL is the 3D version, which uses the Three.js 3D engine. More info about the WebGL 3D version can be found for developers and 3D artists.

Developer: Andreas Røsdal @andreasrosdal

Running Freeciv-web on your computer

The recommended and probably easiest way is to use Vagrant on VirtualBox.

Whatever the method you choose, you'll have to check out Freeciv-web to a

directory on your computer, by installing Git and

running this command:

git clone https://github.com/freeciv/freeciv-web.git --depth=10

You may also want to change some parameters before installing, although

it's not needed in most cases. If you have special requirements, have a look

at config.dist,

copy it without the .dist extension and edit to your liking.

⚠️ Notice for Windows users

Please keep in mind that the files are to be used in a Unix-like system

(some Ubuntu version with the provided Vagrant file).

Line endings for text files are different in Windows, and some editors

"correct" them, making the files unusable in the VM.

There's some provision to recode the main configuration files when installing,

but not afterwards. If you touch shared files after installation, please use

an editor that respect Unix line endings or transform them with a utility

like dos2unix after saving them.

Running Freeciv-web with Vagrant on VirtualBox

Freeciv-web can be setup using Vagrant on VirtualBox to quickly create a

local developer image running Freeciv-web on latest Ubuntu on your host

operating system such as Windows, OSX or Linux.

This is the recommended way to build Freeciv-web on your computer.

Install VirtualBox: https://www.virtualbox.org/ - Install manually on Windows, and with the following command on Linux:

sudo apt-get install virtualbox

Install Vagrant: http://www.vagrantup.com/ - Install manually on Windows

, and with the following command on Linux:

sudo apt-get install vagrant

Run Vagrant with the following commands in your Freeciv-web directory:

vagrant up

This will build, compile, install and run Freeciv-web on the virtual server image. Wait for the installation process to complete, watching for any error messages in the logs.

Test Freeciv-web by pointing your browser to http://localhost if you run Windows or http://localhost:8080 if you run Linux or macOS.

To log in to your Vagrant server, run the command:

vagrant ssh

The Vagrant guest machine will mount the Freeciv-web source repository in the /vagrant directory.

Note that running Freeciv-web using Vagrant requires about 4Gb of memory

and 3 Gb of harddisk space.

System Requirements for manual install

Install this software if you are not running Freeciv-web with Vagrant:

When in a tested system,

you may run scripts/install/install.sh and it will fetch and configure what's needed.

Start and stop Freeciv-web with the following commands:

start-freeciv-web.sh

stop-freeciv-web.sh

status-freeciv-web.sh

All software components in Freeciv-web will log to the /logs sub-directory of the Freeciv-web installation.

Running Freeciv-web on Docker

Freeciv-web can easily be built and run from Docker using docker-compose.

Make sure you have both Docker and Docker Compose installed.

Run the following from the freeciv-web directory:

docker-compose up -d

Connect to docker via host machine using standard browser

Enjoy. The overall dockerfile and required changes to scripts needs some further improvements.

Freeciv-Web continuous integration on Travis CI

Freeciv-Web is built on Travis CI on every commit. This is the current build status: 6b8d58f576c7e95b24aade71c8025758.png

Freeciv-web has CasperJS tests which are run by Travis CI on every commit, and by Vagrant when creating a new image. The tests can be found in tests/freeciv-web-tests.js. Please make sure that patches and commits for Freeciv-web don't break the CasperJS tests. Thanks!

Developers interested in Freeciv-web

If you want to contibute to Freeciv-web, see the issues on GibHub and the TODO file for

some tasks you can work on. Pull requests on Github is welcome!

Credits

Significant contributors to Freeciv-web:

and thanks to the Freeciv.org project and Sid.

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值