Skip to content

Commit

Permalink
Merge pull request #88 from boltgolt/dev
Browse files Browse the repository at this point in the history
Version 1.4.0
  • Loading branch information
boltgolt authored Oct 20, 2023
2 parents 2d45af1 + 062908e commit b477492
Show file tree
Hide file tree
Showing 11 changed files with 1,388 additions and 1,998 deletions.
16 changes: 8 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<div align="center">
<img src="https://i.imgur.com/VxEv6oI.png" alt="Boltobserv logo" /><br /><br />
<strong>Giving CSGO observers a powerful new radar.</strong><br />
<span>Easy to read, infinitely resizeable, and with tons of features the default CSGO radar does not have.</span><br /><br />
<strong>Giving CS observers a powerful new radar.</strong><br />
<span>Easy to read, infinitely resizeable, and with tons of features the default Counter-Strike radar does not have.</span><br /><br />
<img src="https://i.imgur.com/ydc2Hf9.gif" />
</div>

Expand All @@ -13,7 +13,7 @@ Player dots show more than just the location of the player. With 6 different dot

| Dots | Type | Description |
|----------------------------------------|-------------------|-------------------------------------------------------------------------------------------------------------------------|
| ![](https://i.imgur.com/rS7z3Hh.png) | Default | Player dots as seen on the normal CSGO radar, normally with a slot number on them. |
| ![](https://i.imgur.com/rS7z3Hh.png) | Default | Player dots as seen on the normal CS radar, normally with a slot number on them. |
| ![](https://i.imgur.com/qCqMGfY.png) | Flashed | Flashed players have a semi-white glow. This only shows when players are fully flashed (white screen). |
| ![](https://i.imgur.com/QNhkhlV.png) | Active | A ring is shown around players that the observer selects to show the POV from. |
| ![](https://i.imgur.com/lemRnpz.png) | Shooting | Muzzle flashes when a player fires a shot with any weapon. Shows for 1 frame for each shot. |
Expand All @@ -33,7 +33,7 @@ The radar images used are made in close cooperation with [simpleradar](https://r

When only a few players are alive most of the radar is just empty and only a very small part contains all the action. Boltobserv has an autozoom feature that fixes this. The radar image can automatically pan and zoom according to where the players are located, and smoothly follows the action.

Autozoom tries to keep the action in the middle, with a safe padding around any players so they can never accidentality run off the radar image. it also has a minimal zoom level, so that the radar only zooms in when the action is concentrated in a small part of the map.
Autozoom tries to keep the action in the middle, with a safe padding around any players so they can never accidentally run off the radar image. it also has a minimal zoom level, so that the radar only zooms in when the action is concentrated in a small part of the map.

### Advisories

Expand All @@ -55,7 +55,7 @@ All possible advisories are (with increasing priority):
Because Boltobserv runs as an external application, it can be resized to be whatever size you want, and be moved to any display you want.
Running without window borders enables it to dedicate as much space as possible to the radar.

It can even [run in a browser](https://github.com/boltgolt/boltobserv/wiki/Opening-radar-in-browser), allowing you to view the radar over the network. This also means that the radar can be added as a browser source in applications like OBS with ransparent background.
It can even [run in a browser](https://github.com/boltgolt/boltobserv/wiki/Opening-radar-in-browser), allowing you to view the radar over the network. This also means that the radar can be added as a browser source in applications like OBS with a transparent background.

### And much more

Expand All @@ -72,14 +72,14 @@ It can even [run in a browser](https://github.com/boltgolt/boltobserv/wiki/Openi
## Installation

1. Download the latest .zip form the [releases](https://github.com/boltgolt/boltobserv/releases) page and unzip it.
2. Launch `Boltobserv.exe`, it should ask you to automatically install the .cfg file. If it doesn't, copy the `gamestate_integration_boltobserv.cfg` file from the .zip to your CSGO config folder (the same folder you'd put an `autoexec.cfg`).
3. You're done! (Re)start CSGO and Boltobserv should automatically connect.
2. Launch `Boltobserv.exe`, it should ask you to automatically install the .cfg file. If it doesn't, copy the `gamestate_integration_boltobserv.cfg` file from the .zip to your CS config folder (the same folder you'd put an `autoexec.cfg`).
3. You're done! (Re)start CS2 and Boltobserv should automatically connect.

Please report any bugs or feature requests here on Github.

## Configuration

Most functions of Boltoberv are configurable. To make your own config, go to `/resources/app/config` and either edit the `config.json5` file directly or duplicate it and rename the copy to `config.override.json5`. Using a override file will allow you to move your settings to a different machine or version without breaking the base config file.
Most functions of Boltobserv are configurable. To make your own config, go to `/resources/app/config` and either edit the `config.json5` file directly or duplicate it and rename the copy to `config.override.json5`. Using a override file will allow you to move your settings to a different machine or version without breaking the base config file.

## Special thanks

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "boltobserv",
"version": "1.3.0",
"version": "1.4.0",
"_whatisthis": "Older versions of Boltobserv used this file to check for updates, so it can't be deleted. The real package.json is in /src"
}
40 changes: 36 additions & 4 deletions src/css/map.css
Original file line number Diff line number Diff line change
Expand Up @@ -206,22 +206,33 @@ div.label.dead {
position: absolute;
border-radius: 100%;
opacity: .8;
box-sizing: border-box;
transform-origin: center;
background: #9F9D9D;
border: #D7D7D7 solid .6vmin;
overflow: hidden;
border-color: #D7D7D7;
transform: translate(-50%, 50%);
transition: opacity .3s;
}

#smokes > div::before {
content: '';
display: block;
height: 100%;
width: 100%;
border: transparent solid .6vmin;
border-color: inherit;
border-radius: 100%;
box-sizing: border-box;
}

#smokes > div.CT {
background: #678FAA;
border: #77C5F6 solid .6vmin;
border-color: #77C5F6;
}

#smokes > div.T {
background: #CCBA7D;
border: #F1D369 solid .6vmin;
border-color: #F1D369;
}

#smokes > div.hide {
Expand All @@ -232,6 +243,27 @@ div.label.dead {
transition: opacity 1.8s;
}

#smokes > div > div {
height: 100%;
width: 100%;
border: transparent solid .6vmin;
border-color: inherit;
border-radius: 100%;
background-color: #364254;
transform: translate(-0.6vmin, 0.6vmin);
position: absolute;
opacity: 1;
transition: background-color .15s, opacity .8s;
}

#smokes > div > div.flash {
background-color: #fff;
}

#smokes > div > div.fade {
opacity: 0;
}

#infernos {
position: absolute;
height: 100%;
Expand Down
4 changes: 2 additions & 2 deletions src/detectcfg.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ module.exports = {
if (result && result.game && fs.existsSync(result.game.path)) {
console.info("Found installation in", result.game.path)

let configPath = path.join(result.game.path, "csgo", "cfg", "gamestate_integration_boltobserv.cfg")
let configPath = path.join(result.game.path, "game", "core", "cfg", "gamestate_integration_boltobserv.cfg")

if (fs.existsSync(configPath)) {
let foundHeader = fs.readFileSync(configPath, "utf8").split("\n")[0]
Expand All @@ -33,7 +33,7 @@ module.exports = {

install: (target) => {
let template = path.join(__dirname, "gamestate_integration_boltobserv.cfg")
let dest = path.join(target, "csgo", "cfg", "gamestate_integration_boltobserv.cfg")
let dest = path.join(target, "game", "core", "cfg", "gamestate_integration_boltobserv.cfg")
fs.copyFileSync(template, dest)

console.info("Installed config file as", dest)
Expand Down
15 changes: 8 additions & 7 deletions src/gsi.js
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ function handleRequest(req, res) {
for (let nadeID in game.grenades) {
let nade = game.grenades[nadeID]

if (nade.type == "smoke" && nade.velocity == "0.000, 0.000, 0.000") {
if (nade.type == "smoke" && nade.effecttime != '0.000') {
let pos = nade.position.split(", ")
let owner = game.allplayers[nade.owner]

Expand All @@ -146,7 +146,7 @@ function handleRequest(req, res) {

grenades.smokes.push({
id: nadeID,
time: nade.effecttime,
time: parseFloat(nade.effecttime),
team: team,
position: {
x: parseFloat(pos[0]),
Expand All @@ -156,7 +156,7 @@ function handleRequest(req, res) {
})
}

else if (nade.type == "flashbang" && parseFloat(nade.lifetime) >= 1.4) {
if (nade.type == "flashbang" && parseFloat(nade.lifetime) >= 1.4) {
let pos = nade.position.split(", ")
grenades.flashbangs.push({
id: nadeID,
Expand All @@ -176,9 +176,10 @@ function handleRequest(req, res) {
for (var i = 0; i < flamesNum; i++) {
let pos = Object.values(nade.flames)[i].split(", ")
flamesPos.push({
x: parseFloat(pos[0]),
y: parseFloat(pos[1]),
z: parseFloat(pos[2])
// BUG: CS2 has the coords doubled for some reason
x: parseFloat(pos[0]) / 2,
y: parseFloat(pos[1]) / 2,
z: parseFloat(pos[2]) / 2
})
}

Expand All @@ -190,7 +191,7 @@ function handleRequest(req, res) {
}
}

else if (nade.type != "decoy" && nade.velocity != "0.000, 0.000, 0.000") {
else if (nade.type != "decoy" && nade.velocity != "0.000, 0.000, 0.000" && (nade.type != "smoke" || nade.effecttime == '0.000')) {
let pos = nade.position.split(", ")
let owner = game.allplayers[nade.owner]

Expand Down
6 changes: 3 additions & 3 deletions src/html/waiting.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html lang="en" dir="ltr">
<head>
<title>Boltobserv - Waiting for CSGO</title>
<title>Boltobserv - Waiting for CS</title>
<meta charset="utf-8">
<link rel="icon" href="/img/icon-64x64.png" sizes="64x64" type="image/png">

Expand Down Expand Up @@ -41,7 +41,7 @@
<div id="connectgameline" class="statusline">&rsaquo;</div>

<div id="connectgame" class="statusbox">
<strong>CSGO</strong>
<strong>CS2</strong>
<span>Disconnected</span>
<div>Still waiting for Boltobserv</div>
</div>
Expand All @@ -51,7 +51,7 @@
<div id="connectserver" class="statusbox">
<strong>Match server</strong>
<span>Disconnected</span>
<div>Waiting for CSGO to connect first</div>
<div>Waiting for CS to connect first</div>
</div>
</div>

Expand Down
Loading

0 comments on commit b477492

Please sign in to comment.