chase-ai

🎮 An artificial intelligence game to demonstrate the A* pathfinding. The enemy will try to get close to the agent and make it stuck between walls.(用于演示A*寻路算法的人工智能游戏,敌人会追踪宝藏并尝试将其困在围墙之间。)

https://github.com/zhuagenborn/chase-ai

Science Score: 44.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
    Found CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
  • Academic publication links
  • Committers with academic emails
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (6.3%) to scientific vocabulary

Keywords

a-star-algorithm artificial-intelligence game path-finding
Last synced: 6 months ago · JSON representation ·

Repository

🎮 An artificial intelligence game to demonstrate the A* pathfinding. The enemy will try to get close to the agent and make it stuck between walls.(用于演示A*寻路算法的人工智能游戏,敌人会追踪宝藏并尝试将其困在围墙之间。)

Basic Info
  • Host: GitHub
  • Owner: Zhuagenborn
  • License: mit
  • Language: Python
  • Default Branch: main
  • Homepage:
  • Size: 1.77 MB
Statistics
  • Stars: 29
  • Watchers: 2
  • Forks: 3
  • Open Issues: 0
  • Releases: 0
Topics
a-star-algorithm artificial-intelligence game path-finding
Created about 5 years ago · Last pushed 6 months ago
Metadata Files
Readme License Citation

README.md

Chase AI

Python ECMAScript License

Introduction

Cover

An artificial intelligence game to demonstrate the A* path-finding. The enemy will try to get close to the agent and make it stuck between walls.

Getting Started

Prerequisites

bash pip install -r requirements.txt

Running

bash python main.py

Configurations

The game configuration is in the src/config.json file.

Documents

See docs/wiki.md for the details.

Class Diagram

```mermaid classDiagram

class Action { <> Stay Up Down Left Right }

class Occupy { <> None Wall Role }

class Terrain { <> Wall Grass Bush }

class Status { int score int steps Agent agent Enemy enemy }

class Map { terrain(x, y) Terrain occupied(x, y, Status) Occupy move_cost(x, y) float }

Map ..> Status Map ..> Occupy Map *-- Terrain

class Role { <> move() bool peek_action() Action stuck() bool }

Role ..> Action Role --> Map Role -- Status

class Agent Role <|-- Agent

class Enemy { list~pos~ path }

Role <|-- Enemy

ActionLevels --> Action

class Strategy { <> action_lvls(Status)* ActionLevels }

Strategy ..> ActionLevels Strategy ..> Status Strategy --> Role

class Random Strategy <|-- Random

class MoveAway Strategy <|-- MoveAway

class MoveClose Strategy <|-- MoveClose

class WallDensity Strategy <|-- WallDensity

class AStar { list~pos~ prev_path }

Strategy <|-- AStar

Enemy --> Random Enemy --> AStar Enemy --> MoveClose Enemy --> WallDensity

Agent --> Random Agent --> MoveAway Agent --> WallDensity ```

Dependencies

License

Distributed under the MIT License. See LICENSE for more information.

The image resources are from the book "Making Games with Python & Pygame" written by Al Sweigart.

Owner

  • Name: Zhuagenborn
  • Login: Zhuagenborn
  • Kind: organization
  • Location: Ireland

Software Development | Artificial Intelligence | Reverse Engineering.

Citation (CITATION.cff)

cff-version: 1.2.0
authors:
- family-names: Chen
  given-names: Zhenshuo
  orcid: https://orcid.org/0000-0003-2091-4160
- family-names: Liu
  given-names: Guowen
  orcid: https://orcid.org/0000-0002-8375-5729
title: Chase AI
date-released: 2022-05-21
url: https://github.com/Zhuagenborn/Chase-AI

GitHub Events

Total
  • Watch event: 1
  • Push event: 1
Last Year
  • Watch event: 1
  • Push event: 1

Committers

Last synced: 7 months ago

All Time
  • Total Commits: 6
  • Total Committers: 1
  • Avg Commits per committer: 6.0
  • Development Distribution Score (DDS): 0.0
Past Year
  • Commits: 5
  • Committers: 1
  • Avg Commits per committer: 5.0
  • Development Distribution Score (DDS): 0.0
Top Committers
Name Email Commits
Chenzs108 c****8@o****m 6

Issues and Pull Requests

Last synced: 7 months ago

All Time
  • Total issues: 1
  • Total pull requests: 0
  • Average time to close issues: 3 months
  • Average time to close pull requests: N/A
  • Total issue authors: 1
  • Total pull request authors: 0
  • Average comments per issue: 1.0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 0
  • Pull requests: 0
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Issue authors: 0
  • Pull request authors: 0
  • Average comments per issue: 0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
  • mrmingshengzhang (1)
Pull Request Authors
Top Labels
Issue Labels
Pull Request Labels

Dependencies

requirements.txt pypi
  • pygame *