Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

various fixes #27

Merged
merged 7 commits into from
Feb 25, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 5 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,9 @@ Burntime is a remaster and expansion of Max Design's PC strategy game 'Burntime'

## Get the Game

Download it from [Releases](https://github.com/jakobharder/burntime/releases).

## Changes

See [Changelog.md](./resources/Changelog.md).
- Download: [Releases](https://github.com/jakobharder/burntime/releases)
- Recent changes: [Changelog.md](./resources/Changelog.md)
- Issues & requests: [GitHub issues](https://github.com/jakobharder/burntime/issues) or [Burntime.org (German forum)](https://www.burntime.org/forum/viewtopic.php?t=323)

## Features

Expand Down Expand Up @@ -96,11 +94,8 @@ Enemies are more aggressive.
## Build and Debug

- open `source/Burntime.sln` in Visual Studio
- build solution (it will generate a `bin/burntime` folder)
- mark `Burntime` as the start-up project
- start

You can also mark the `Launcher` as start-up project to change settings and debug that part.
- mark `Burntime.MonoGame` as the start-up project
- build & start

## Credits

Expand Down
15 changes: 15 additions & 0 deletions resources/Changelog.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,20 @@
# Burntime Changelog

## 0.10 - Fixing (2024-02-25)

### Changes

- Added ropes to a few traders to sell
- Added info scene wide background

### Fixes

- Fixed AI player's shadow remaining after death
- Fixed doctors not healing stationed NPCs
- Fixed New Village name, rooms etc.
- Fixed radio construction
- Fixed Nob Hill room background

## 0.9 - Balancing and some graphics remaster (2023-11-05)

### 0.9.1
Expand Down
2 changes: 1 addition & 1 deletion resources/game/classic/construction.txt
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ class=technician
[item_two_way_radio]
items=item_defective_two_way_radio item_electrical_odds_and_ends item_batteries
dialog=508
dialog_items=item_defective_two_way_radio
main_items=item_defective_two_way_radio
class=technician

[item_protective_suit]
Expand Down
2 changes: 1 addition & 1 deletion resources/game/classic/lang/en/BURN.TXT
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ Nameless Town}
Nirvana}
Right End}
Anif}
38}
New Village}
39}
40}
Mercenary}
Expand Down
27 changes: 27 additions & 0 deletions resources/game/classic/maps/MAT_005.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
rooms = 4

water_refresh = 5
water_capacity = 6
city = false
danger = danger@radiation??45

[room0]
type = normal
title = burn?661
image = raum_0.pac

[room1]
type = normal
title = burn?661
image = raum_0.pac

[room2]
type = normal
title = burn?661
image = raum_0.pac

[room3]
type = water
title = burn?665
image = raum_4.pac

14 changes: 7 additions & 7 deletions resources/game/classic/maps/MAT_038.txt
Original file line number Diff line number Diff line change
Expand Up @@ -15,30 +15,30 @@ way_lengths = 3
[room0]
type = normal
title = burn?661
image = raum_01.pac
image = raum_1.pac

[room1]
type = normal
title = burn?661
image = raum_01.pac
image = raum_1.pac

[room2]
type = normal
title = burn?661
image = raum_01.pac
image = raum_1.pac

[room3]
type = normal
type = water
title = burn?665
image = raum_05.pac
image = raum_5.pac

[room4]
type = normal
title = burn?661
image = raum_01.pac
image = raum_1.pac

[room5]
type = normal
title = burn?661
image = raum_01.pac
image = raum_1.pac

43 changes: 23 additions & 20 deletions resources/game/classic/trader.txt
Original file line number Diff line number Diff line change
@@ -1,53 +1,56 @@
[trader]
'Mad Marty
'Mad Marty, Neu Sandez area
179=item_meat item_knife item_loaded_rifle item_snake_trap item_broken_pump item_hose item_protective_overall

'Chuck
180=item_meat item_batteries item_wire item_screws item_rags item_boots item_tools
'Chuck, Sana area
180=item_meat item_batteries item_wire item_screws item_rags item_boots item_tools item_rope
'180=item_meat item_batteries item_wire item_screws item_rags item_boots item_tools

'Jack the Nepper
'Jack the Nepper, Stove Vent area
181=item_snake item_meat item_empty_canteen item_knife item_axe item_snake_trap item_wire item_woodpile item_ammunition

'Sharky
'Sharky, Dead Wood area
182=item_meat item_empty_canteen item_pitchfork item_woodpile item_screws item_gas_mask item_tools

'Lester
'Lester, Hard Mens Dead area
183=item_meat item_empty_wineskin item_axe item_snake_trap item_screws item_tin item_spring

'Wolf
'Wolf, Right End area
184=item_meat item_pitchfork item_wire item_gloves item_leather_jacket item_sweater item_pants

'Ralf Gier
185=item_snake item_meat item_empty_canteen item_pitchfork item_woodpile item_screws item_tin item_gas_mask
'Ralf Gier, Snake Hills area
185=item_snake item_meat item_empty_canteen item_pitchfork item_woodpile item_screws item_tin item_gas_mask item_rope
'185=item_snake item_meat item_empty_canteen item_pitchfork item_woodpile item_screws item_tin item_gas_mask

'Holger
'Holger, Sherwood area
186=item_meat item_empty_canteen item_knife item_broken_pump item_screws item_tin item_boots

'Zocker Joe
187=item_snake item_meat item_empty_wineskin item_axe item_snake_trap item_batteries item_wire item_protective_overall
'Zocker Joe, Kloster area
187=item_snake item_meat item_empty_wineskin item_axe item_snake_trap item_batteries item_wire item_protective_overall item_rope
'187=item_snake item_meat item_empty_wineskin item_axe item_snake_trap item_batteries item_wire item_protective_overall

'Django
'Django, Raststätte area
188=item_meat item_axe item_batteries item_wire item_screws item_rags item_protective_suit

'Don Camillo
'Don Camillo, Paradise Camp area
189=item_meat item_knife item_electrical_odds_and_ends item_wire item_screws item_tin item_iron_pipe

'John
'John, Nirvana area
190=item_snake item_meat item_empty_wineskin item_pitchfork item_snake_trap item_spare_parts item_hose item_iron_pipe

'Monkey
'Monkey, Dead Wood area
191=item_snake item_meat item_knife item_woodpile item_screws item_hose item_rags item_gas_mask

'Kaiser
'Kaiser, One Man's Heaven area
192=item_meat item_knife item_broken_pump item_wire item_woodpile item_tin item_hose

'Trademan
'Trademan, Acit Town area
193=item_meat item_water_bottle item_empty_wineskin item_pitchfork item_spare_parts item_wire item_woodpile item_rags item_iron_pipe

'Black Eye
'Black Eye, Gold Town area
194=item_snake item_meat item_empty_wineskin item_axe item_wire item_woodpile item_rags item_gold item_tools

'Iceman
'Iceman, Lost Hope area
195=item_meat item_knife item_industrial_pump item_broken_pump item_wire item_woodpile item_tin item_spring

'Donald
Expand Down
2 changes: 1 addition & 1 deletion resources/game/classic_de/lang/de/BURN.TXT
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ Nameless Town}
Nirvana}
Right End}
Anif}
38}
New Village}
39}
40}
Kämpfer}
Expand Down
Binary file modified resources/game/classic_newgfx/gfx/backgrounds/info.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified resources/game/classic_newgfx/gfx/items/gst.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion resources/game/classic_newgfx/newgfx.txt
Original file line number Diff line number Diff line change
Expand Up @@ -163,4 +163,4 @@ mat_082.raw=maps/mat_082.burnmap
maps/mat_000_tiles.png=pngsheet@maps/mat_000_tiles_2x.png?{0}?64x76

[noscale]

sprite_scale=1x1
24 changes: 8 additions & 16 deletions source/Burntime.Remaster/Logic/Character/Character.cs
Original file line number Diff line number Diff line change
Expand Up @@ -302,7 +302,7 @@ public bool IsLastInCamp
{
if (location == null)
return false;
List<Character> camp = Location.CampNPC;
List<Character> camp = Location.CampNPC.Take(2).ToList();
return (camp.Count == 1 && camp[0] == this);
}
}
Expand Down Expand Up @@ -565,21 +565,9 @@ public virtual void Turn()
}
}

if (Food == 0)
health -= 25;
if (Water == 0)
health -= 25;

bool doctorAvailable = false;

if (Player != null && location == null)
{
for (int i = 0; i < Player.Group.Count; i++)
{
doctorAvailable |= (Player.Group[i].Class == CharClass.Doctor);
}
}

// TODO move location healing to location
bool doctorAvailable = Player?.Group.Any(chr => chr.Class == CharClass.Doctor) == true ||
Location?.CampNPC.Any(chr => chr.Class == CharClass.Doctor && chr.Player == Player) == true;
if (doctorAvailable)
{
if (health >= 50)
Expand All @@ -593,6 +581,10 @@ public virtual void Turn()

if (health > 100)
health = 100;
if (Food == 0)
health -= 25;
if (Water == 0)
health -= 25;

if (health <= 0)
{
Expand Down
3 changes: 3 additions & 0 deletions source/Burntime.Remaster/Logic/Generation/GameCreation.cs
Original file line number Diff line number Diff line change
Expand Up @@ -250,7 +250,10 @@ void AddPlayer(ClassicGame game, NewGameInfo Info, Burntime.Data.BurnGfx.Save.Sa
foreach (Player p in game.World.Players)
{
if (p.Type == PlayerType.Ai)
{
p.IsDead = true;
p.Character.Die();
}
}

foreach (Burntime.Framework.Network.GameClient client in app.Server.Clients)
Expand Down
16 changes: 3 additions & 13 deletions source/Burntime.Remaster/Logic/Location.cs
Original file line number Diff line number Diff line change
Expand Up @@ -49,19 +49,9 @@ public StateLinkList<Character> Characters
set { characters = value; }
}

public List<Character> CampNPC
public IEnumerable<Character> CampNPC
{
get
{
List<Character> l = new List<Character>();
foreach (Character ch in characters)
{
if (ch.Player != null)
l.Add(ch);
}

return l;
}
get => characters.Where(chr => chr.Player != null);
}

StateLink<DroppedItemList> items;
Expand Down Expand Up @@ -181,7 +171,7 @@ public Production.Rate GetFoodProductionRate(Production? production = null)
int trapsInRooms = Rooms.Sum(room => room.Items.Where(item => item.Type.Production == production).Count());
int trapsOnNPCs = CampNPC.Sum(npc => npc.Items.Where(item => item.Type.Production == production).Count());

return production.GetRate(trapsInRooms + trapsOnNPCs, CampNPC.Count);
return production.GetRate(trapsInRooms + trapsOnNPCs, CampNPC.Count());
}

public Production.Rate AutoSelectFoodProduction(bool onlyIfStarving)
Expand Down
10 changes: 2 additions & 8 deletions source/Burntime.Remaster/Logic/WaterSource.cs
Original file line number Diff line number Diff line change
Expand Up @@ -87,17 +87,11 @@ public int GetBoost()

if (pump)
{
if (water == 1)
boost = 5;
else
boost = water / 2;
boost = System.Math.Max(5, water / 2);
}
else if (handPump)
{
if (water == 1)
boost = 2;
else
boost = water / 4;
boost = System.Math.Max(2, water / 4);
}

return boost;
Expand Down
2 changes: 1 addition & 1 deletion source/Burntime.Remaster/Logic/World.cs
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ public virtual void Turn()
{
if (Locations[j].Player == Players[i])
{
List<Character> list = Locations[j].CampNPC;
var list = Locations[j].CampNPC;
foreach (Character ch in list)
ch.Dismiss();
}
Expand Down
Loading
Loading