Skip to content

Commit

Permalink
Prep 1.07
Browse files Browse the repository at this point in the history
Originally intended to just rebalance "Maximum Insanity", this ended up fixing bug(s) that were missed in 1.06.
  • Loading branch information
ChallengeSY committed Sep 29, 2023
1 parent baa70f2 commit cd3abf1
Show file tree
Hide file tree
Showing 23 changed files with 520 additions and 479 deletions.
93 changes: 11 additions & 82 deletions NNLocal.bas
Original file line number Diff line number Diff line change
Expand Up @@ -4,26 +4,21 @@ sub local_gameplay
dim as short LevelClear, PassInput, InstruAlpha, InstruBeta, InstruGamma, Phase, AboveLine, HeadingUpwards, RotationFrame, _
ProhibitSpawn, WepCooldown, DebugConsole, FreezeStr, ScoreTick, MinPlayHeight, ShowTopUI, RecalcGems
dim as integer LoadErrors, BarrierStrength, MPAlternate, ScoreFilling, GracePeriod, ModdedHiScore
dim as double LastPlayed, DispTime, MusicPitch, DifficultyRAM(4)
dim as double LastPlayed, DispTime, MusicPitch
dim as string ScoreRef, DiffName, GameInfo, TimeStr, DebugCode
NumPlayers = 1
Player = 1
GamePaused = 0
SpeedMod = 100
InstruAlpha = 4

Player = 1
apply_diff_specs

DesireX = 512
PaddleHealth = 6600
ShowTopUI = 60

BulletStart = 1
DQ = 0
destroy_ammo
destroy_capsules
destroy_balls
ShuffleList(1) = 1
PlayerSlot(1).PerfectClear = 1
fix_first_level
if QuickPlayFile = "" then
LoadErrors = load_settings
else
Expand All @@ -37,7 +32,6 @@ sub local_gameplay
SubsequentExtraLives = 0
ExplodingValue = 8
SecretLevels = 2
load_level(1)
end if
with NewPlrSlot
.DispScore = 0
Expand All @@ -52,15 +46,7 @@ sub local_gameplay
end if
empty_hand(0)
end with
copy_wall
for PID as ubyte = 1 to 4
DifficultyRAM(PID) = PlayerSlot(PID).Difficulty
PlayerSlot(PID) = NewPlrSlot
PlayerSlot(PID).Difficulty = DifficultyRAM(PID)
fresh_level(PID)
next PID
rotate_back(1)
reset_paddle
begin_local_game(0, 1)

if LoadErrors then
exit sub
Expand All @@ -85,7 +71,6 @@ sub local_gameplay
next LsrID

NewPlrSlot.Lives = StartingLives + (ExtraBarrierPoint * CampaignBarrier)
FrameTime = timer
InPassword = "--------"
do
PlayerSlot(0).Difficulty = max(PlayerSlot(1).Difficulty,max(PlayerSlot(2).Difficulty,max(PlayerSlot(3).Difficulty,PlayerSlot(4).Difficulty)))
Expand Down Expand Up @@ -2526,37 +2511,11 @@ sub local_gameplay
dim as short TestNum = 2, Result
do
ActualPassword = check_level(TestNum)
if (ActualPassword = InPassword AND InPassword <> "++++++++") OR _
(InPassword = "++++++++" AND TestNum = PlayerSlot(Player).LevelNum) then
setmouse(,,0,1)
LevelDesc = 0
Player = 1
rotate_back
DQ = 0
Instructions = "Level "+str(TestNum)+" successfully loaded!"
rotate_music
InstructExpire = timer + 7

destroy_balls
PlayerSlot(Player).PerfectClear = 1
load_level_file(CampaignFolder+"/L"+str(TestNum))
NewPlrSlot.LevelNum = TestNum
copy_wall
for PID as ubyte = 1 to NumPlayers
PlayerSlot(PID) = NewPlrSlot
PlayerSlot(PID).Difficulty = DifficultyRAM(PID)
fresh_level(PID)
next PID
generate_cavity
for Bull as ubyte = 1 to MaxBullets
Bullet(Bull).Y = -20
next Bull
for HID as byte = 1 to 10
HighScore(HID).NewEntry = 0
next HID
reset_paddle
render_hand
if (ActualPassword = InPassword AND InPassword <> "++++++++") then
begin_local_game(NumPlayers, TestNum)

Instructions = "Password successful"
InstructExpire = timer + 5
exit do
end if

Expand Down Expand Up @@ -2751,36 +2710,8 @@ sub local_gameplay
if total_lives = 0 then
for PID as ubyte = 1 to 4
if InType = str(PID) AND InPassword = "--------" then
DQ = 0
FrameTime = timer
reset_paddle
shuffle_levels

Player = 1
NumPlayers = PID

for HID as byte = 1 to 10
HighScore(HID).NewEntry = 0
next HID
destroy_ammo
destroy_balls
setmouse(,,0,1)
begin_local_game(PID, 1)

LevelDesc = 0
PlayerSlot(Player).PerfectClear = 1
load_level(1)
generate_cavity
reset_paddle
NewPlrSlot.LevelNum = 1
copy_wall
for PDID as ubyte = 1 to NumPlayers
PlayerSlot(PDID) = NewPlrSlot
PlayerSlot(PDID).Difficulty = DifficultyRAM(PID)
fresh_level(PDID)
render_hand
next PDID
rotate_music
rotate_back
Instructions = ""
InstructExpire = timer
end if
Expand Down Expand Up @@ -2894,7 +2825,7 @@ sub local_gameplay
TotalXP += int(.Score * .Difficulty * 2)
high_score_input(Player)
if FileExists(CampaignName+".flag") = 0 then
'Intentionally empty file; simply use it to record campaigns which have been truly won
'Intentionally empty victory file
open CampaignName+".flag" for output as #21
close #21
end if
Expand Down Expand Up @@ -2960,5 +2891,3 @@ sub local_gameplay
end if
setmouse(,,0,0)
end sub


57 changes: 57 additions & 0 deletions NNLocal.bi
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,12 @@ sub ui_element(Text as string, XPos as short, YPos as short, Length as short = 0
gfxString(Text,XPos,YPos,5,5,3,Coloring)
end if
end sub
sub fix_first_level
with PlayerSlot(1)
.PerfectClear = 1
.SetCleared = 0
end with
end sub
sub reset_paddle(OnlyGoods as byte = 0)
apply_diff_specs
render_paddle(StandardSize)
Expand Down Expand Up @@ -213,6 +219,7 @@ sub destroy_balls
TotalBC = 0
end sub
sub destroy_ammo
BulletStart = 1
for MSID as ubyte = 1 to MaxBullets
with Bullet(MSID)
.Y = -100
Expand Down Expand Up @@ -1597,6 +1604,56 @@ sub transfer_control(GameEnded as ubyte = 0)
render_hand
end sub

sub begin_local_game(InitPlayers as byte, InitLevel as short)
setmouse(,,0,1)
DQ = 0

Player = 1
NumPlayers = max(InitPlayers,1)
reset_paddle
destroy_ammo
destroy_balls
destroy_capsules
LevelDesc = 0

for HID as byte = 1 to 10
HighScore(HID).NewEntry = 0
next HID

if InitPlayers > 0 then
if InitLevel = 1 then
shuffle_levels

fix_first_level
load_level(1)
else
fix_first_level
load_level_file(CampaignFolder+"/L"+str(InitLevel))
end if
rotate_music
else
load_level(1)
end if
rotate_back
generate_cavity

NewPlrSlot.LevelNum = InitLevel
copy_wall
for PDID as ubyte = 1 to 4
DifficultyRAM(PDID) = PlayerSlot(PDID).Difficulty
PlayerSlot(PDID) = NewPlrSlot
PlayerSlot(PDID).Difficulty = DifficultyRAM(PDID)
fresh_level(PDID)
if PDID > InitPlayers then
PlayerSlot(PDID).Lives = 0
end if
next PDID
render_hand


FrameTime = timer
end sub

sub capsule_message(NewText as string, AlwaysShow as byte = 0)
if DisableHints = 0 OR AlwaysShow then
Instructions = NewText
Expand Down
28 changes: 28 additions & 0 deletions NebEdit.bi
Original file line number Diff line number Diff line change
Expand Up @@ -886,6 +886,20 @@ sub draw_brushes(BrushID as byte)
line(32+(BrushX-1)*24,96+(BrushY-1)*24)-_
(31+(BrushX)*24,95+(BrushY)*24),.PColoring,bf

if retrivePrimary(.PColoring,RGBA_ALPHA) >= 224 then
for OffsetY as byte = 0 to 2 step 2
for OffsetX as byte = 0 to 2 step 2
printgfx(PrintChar,40+(BrushX-1)*24+OffsetX,102+(BrushY-1)*24+OffsetY,2,rgb(0,0,0))
next OffsetX
next OffsetY

if SelectedBrush = BrushID then
printgfx(PrintChar,41+(BrushX-1)*24,103+(BrushY-1)*24,2,rgb(255,255,0))
else
printgfx(PrintChar,41+(BrushX-1)*24,103+(BrushY-1)*24,2,rgb(255,255,255))
end if
end if

if SelectedBrush = BrushID then
line(33+(BrushX-1)*24,97+(BrushY-1)*24)-_
(30+(BrushX)*24,94+(BrushY)*24),rgb(255,255,255),b,&b1110011001100111
Expand All @@ -911,6 +925,20 @@ sub draw_brushes(BrushID as byte)
line(32+(BrushX-1)*48,96+(BrushY-1)*24)-_
(31+(BrushX)*48,95+(BrushY)*24),.PColoring,bf

if retrivePrimary(.PColoring,RGBA_ALPHA) >= 224 then
for OffsetY as byte = 0 to 2 step 2
for OffsetX as byte = 0 to 2 step 2
printgfx(PrintChar,52+(BrushX-1)*48+OffsetX,102+(BrushY-1)*24+OffsetY,2,rgb(0,0,0))
next OffsetX
next OffsetY

if SelectedBrush = BrushID then
printgfx(PrintChar,53+(BrushX-1)*48,103+(BrushY-1)*24,2,rgb(255,255,0))
else
printgfx(PrintChar,53+(BrushX-1)*48,103+(BrushY-1)*24,2,rgb(255,255,255))
end if
end if

if SelectedBrush = BrushID then
line(33+(BrushX-1)*48,97+(BrushY-1)*24)-_
(30+(BrushX)*48,94+(BrushY)*24),rgb(255,255,255),b,&b1110011001100111
Expand Down
2 changes: 1 addition & 1 deletion Nebunoid.bas
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ if ScreenCreated = 0 OR FileExists("FS.ini") then
bload(MasterDir+"/gfx/banner.bmp",TitleBanner)
end if
end if
windowtitle "Nebunoid 1.06"
windowtitle "Nebunoid 1.07"

'Foreground assets
SoftBrickPic = ImageCreate(48,24)
Expand Down
28 changes: 27 additions & 1 deletion Nebunoid.bi
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ dim shared as integer LastActive, Result, OrigX(1), DesireX, JoyButtonCombo, Exp
dim shared as single JoyAxis(7)
dim shared as short TotalBC, FrameSkip, PaddleCycle, ExplodeCycle, KeyboardSpeed, JoyKeySetting, ProgressiveBounces, BlockBrushes
dim shared as double ProgressiveQuota, InstructExpire, MisnExpire, TimeRem, Reminder = -1, _
FrameTime, PaddlePercent
FrameTime, PaddlePercent, DifficultyRAM(4)
dim shared as string InType, ScoreFile, Instructions, CampaignFolder, BackList(BackCount), DiffTxt

dim shared as BackSpecs BackSlot(BackCount)
Expand Down Expand Up @@ -971,6 +971,32 @@ function disp_wall(FrameTick as short, DispSetting as byte = 0) as integer
line(32+(XID-1)*48,96+(YID-1)*24)-_
(31+(XID)*48,95+(YID)*24),.PColoring,bf
end if

if DispSetting = 2 AND retrivePrimary(.PColoring,RGBA_ALPHA) >= 224 then
if PlayerSlot(Player).TileSet(XID,YID).BrickID < 10 then
PrintChar = str(PlayerSlot(Player).TileSet(XID,YID).BrickID)
else
PrintChar = chr(55+PlayerSlot(Player).TileSet(XID,YID).BrickID)
end if

if CondensedLevel then
for OffsetY as byte = 0 to 2 step 2
for OffsetX as byte = 0 to 2 step 2
printgfx(PrintChar,40+(XID-1)*24+OffsetX,102+(YID-1)*24+OffsetY,2,rgb(0,0,0))
next OffsetX
next OffsetY

printgfx(PrintChar,41+(XID-1)*24,103+(YID-1)*24,2,rgb(255,255,255))
else
for OffsetY as byte = 0 to 2 step 2
for OffsetX as byte = 0 to 2 step 2
printgfx(PrintChar,52+(XID-1)*48+OffsetX,102+(YID-1)*24+OffsetY,2,rgb(0,0,0))
next OffsetX
next OffsetY

printgfx(PrintChar,53+(XID-1)*48,103+(YID-1)*24,2,rgb(255,255,255))
end if
end if
elseif PlayerSlot(Player).TileSet(XID,YID).BrickID <> .HitDegrade AND .CalcedInvulnerable < 2 then
Count += 1
end if
Expand Down
18 changes: 9 additions & 9 deletions campaigns/official/extreme/L10.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,41 +7,41 @@ LEVEL DATA FILE - MAXIMUM INSANITY LEVEL 10
Level Name := Obstacle Course
Level Description :=
Level Password := ++++++++
Level game number := 4099
Level game number := 3
Level time limit := 0
Number of Brushes := 8
Brush 1 Color := &h80FFFF00
Brush 1 Score Value := 10*
Brush 1 Hit Degrade := 0
Brush 1 Increase Speed:= FALSE
Brush 1 Increase Spd := FALSE
Brush 2 Color := &h80FFFF20
Brush 2 Score Value := 10*
Brush 2 Hit Degrade := 0
Brush 2 Increase Speed:= FALSE
Brush 2 Increase Spd := FALSE
Brush 3 Color := &h80FFFF40
Brush 3 Score Value := 10*
Brush 3 Hit Degrade := 0
Brush 3 Increase Speed:= FALSE
Brush 3 Increase Spd := FALSE
Brush 4 Color := &h80FFFF60
Brush 4 Score Value := 10*
Brush 4 Hit Degrade := 0
Brush 4 Increase Speed:= FALSE
Brush 4 Increase Spd := FALSE
Brush 5 Color := &h80FFFF80
Brush 5 Score Value := 10*
Brush 5 Hit Degrade := 0
Brush 5 Increase Speed:= FALSE
Brush 5 Increase Spd := FALSE
Brush 6 Color := &h80FFFFA0
Brush 6 Score Value := 10*
Brush 6 Hit Degrade := 0
Brush 6 Increase Speed:= FALSE
Brush 6 Increase Spd := FALSE
Brush 7 Color := &hB0FFD700
Brush 7 Score Value := 10*
Brush 7 Hit Degrade := 7
Brush 7 Increase Speed:= TRUE
Brush 7 Increase Spd := FALSE
Brush 8 Color := &hB0CD7F32
Brush 8 Score Value := 2
Brush 8 Hit Degrade := 7
Brush 8 Increase Speed:= FALSE
Brush 8 Increase Spd := FALSE

Level Grid 11111111112
12345678901234567890
Expand Down
Loading

0 comments on commit cd3abf1

Please sign in to comment.