Skip to content

Behind The Mask

Compare
Choose a tag to compare
@RhenaudTheLukark RhenaudTheLukark released this 25 Dec 03:20
· 18 commits to master since this release

Hey, it's Christmas and I think y'all deserve a gift, so here it is!

You were waiting for masks and now they're IN! Have fun remaking your waves with them now lol

IMPORTANT NOTE: If you're upgrading from v0.6.3, please copy the new Default AND Mods folders over your current ones.

Also, text objects including the ones used by enemies when they speak may behave differently, so what used to fit on v0.6.3 may not in v0.6.4 because we fixed them a lot.

Scroll to the bottom for downloads.

Major Changes:

The Sprite Object
  • Added a basic masking system through sprite.Mask, which forcefully masks or cookie-cuts a sprite's children based on one of 5 different modes
  • Added* a third argument to CreateSprite for the purposes of choosing a sorted position in the given sprite layer
The Player Object
  • Added* the Game Event BeforeDeath(), which executes just as the Player is being killed, and allows you to execute code on the Player's death and even prevent the Game Over sequence from starting
  • Player.SetAttackAnim now can take a third argument, in the same manner as sprite.SetAnimation (contributed by @deonix37)
  • Made Player.maxhp settable for ease of access compared to using Player.SetMaxHPShift
The Input Object
  • Added Input.MouseScroll, which allows you to track the scroll wheel movement supplied by the user's mouse or trackpad
The Text Object
  • Text.xscale/Text.yscale/Text.Scale now functions the same at ANY time, compared to v0.6.3!
  • Text.SkipLine() now takes playerskipdocommand into account
File Manipulation
  • Added Misc.DirExists, Misc.CreateDir, Misc.MoveDir and Misc.RemoveDir to the Misc object for folder manipulation
  • Added function File.Move to the File object (contributed by @deonix37)
  • Added File.Copy for copying files!
  • Added File.filePath to get the full path to the opened file on the user's computer!
  • The File Object can now have the "b" attribute in its mode, which fetches a file's bytes rather than characters, and lets you read from and write to files with bytes and specific encodings
    • Added the property file.encoding, which lets you choose the file encoding method used to read from and write to files in byte mode
The Misc. Object
  • Added Misc.MonitorWidth and Misc.MonitorHeight, which always return the size of the user's monitor regardless of settings or fullscreen status
  • Added Misc.SetWideFullscreen, which removes the left and right black pillars when in fullscreen if the player's aspect ratio is wider than 4:3. Can only be used in battles, and resolution resets on battle end.
The Audio and NewAudio objects
  • Changed several Audio-related functions: they no longer display a warning if an audio file could not be loaded; instead, they return a boolean representing if the file was successfully loaded or not (meaning you can now test for if given audio files exist!)
    • Audio.LoadFile
    • Audio.PlaySound
    • NewAudio.PlayMusic
    • NewAudio.PlaySound
    • NewAudio.PlayVoice
  • Added a second argument to NewAudio.GetAudioName which lets you get the actual name you'd enter into PlaySound/LoadFile and such, without the prefix
The Script Object
  • Added* Script.scriptname to the script object, for getting the name of a script object's source lua file
Misc. Functions
  • SetAction now has an extra use while in the state ACTIONSELECT: manually moving the Player onto the 4 different buttons
Monster Scripts
  • Added a special variable dialogueprefix to monster scripts, which can be used to prefix text to the beginning of all monster dialogue. Especially useful for text effects (contributed by @deonix37)
  • Added defensemisstext and noattackmisstext, which when set, will change the damage text displayed when dealing no damage to the enemy and not pressing Z to attack the enemy, respectively (contributed by @Shiftenas)
Text Commands
  • Added* [texteffect:x,intensity], which allows for multiple different text effects in the same line of text
  • Added* [mugshot:x] for use in the Overworld
  • You may now use [charspacing:default] to reset a text manager's character spacing to its original value
The Engine
  • In the Lua folder, you now only require an "Encounters" folder to load your mod
  • Error messages are now automatically formatted to be more friendly to new users, pointing out which numbers are line numbers and which indicate characters on a line
  • If your encounter text or battle dialog would go to 4 lines or longer, then the text will now move slightly upwards to compensate
  • The disclaimer screen will from now on always say the current version of CYF
The Overworld (long)
  • Cleaned up and organized the Overworld. It's now in its best state ever since CYF's creation!
  • You no longer have to restart CYF completely when you get an error in the overworld! Pressing Escape will take you back to the initial disclaimer screen.
  • Changed the way you access a certain secret so you no longer have to edit code to reach it
  • Added the utility functions Event.Exists, Event.GetSpeed, Event.isMoving and Event.isRotating
  • Added General.EndDialog, which can be used from parallel process event functions to forcefully close the dialog box at any time
  • Added Player.ResetMaxHP() which resets the player's max hp to what it would be based on their LV
  • You can use a second argument in General.EnterShop() to skip the fading screen transition
  • The second argument for General.SetBattle has been changed to a string. Use it to make the battle start animation play out normally, play out fast like Undyne's sequence in Undertale, or enter the battle instantly with no transition!
  • You can use an argument* in General.Save() to instantly save the game without the player's knowledge
  • Added support for playerskipdocommand in both Event scripts and shop scripts
  • Made CreateSprite, CreateText and CreateLayer all usable in the Overworld, exactly the same as in battles
  • Misc.ResetCamera() resets the camera to the player's position in the Overworld instead of moving the camera to (0, 0)
  • The game now keeps track of your play time in the overworld instead of always saying 0:00
  • Retrocompatibility mode now gets forcefully disabled whenever you enter the Overworld, to keep things compatible
  • Added a more descriptive and helpful save file tester for CYF
    • If you have an incompatible Overworld save, you can now press "R" on the error screen to remove the save file without needing to remove it manually
Overworld Shops
  • You can now set items to be marked as "SOLD OUT" after buying - there's an example of this in Examples 2/Lua/Shops/Dummy.lua.
  • You can now mark items as unsellable in the engine's internal item database by setting their sell price to 0.
  • Changed the way FailSell works, because it now has 2 error cases, not just one.
  • Made shops play the proper sound effects that play in Undertale for buying, selling, and failing to sell items.
The Documentation
  • Added a new feature indicator that will appear when something has changed since the last version of CYF
  • Removed the "Create Your Frisk's new features" section and moved the items inside of it to more fitting sections
  • Replaced the "Wave scripts" page with "The Arena Object", and moved its singular function and variable to "Misc. Functions" and "Special Variables" where they belong

*(These features were already in the engine, but undocumented)


Removed Stinkies (bug fixes and minor improvements):

Engine
  • Fix missing Lua folders causing the Error scene to be disabled completely
  • Fixed a bug where entering fullscreen with a non-widescreen resolution (such as a square or portrait resolution) would incorrectly cut off the left and right sides of the screen
  • All textures now have mipmapping disabled. Up to now, sprites scaled down certain amounts would start to display with much less detail because of this
  • Fixed the famous "fullscreen bug", where upon entering blurless fullscreen, the player was able to see past the intended 640x480 area if they entered fullscreen at the exact same time as loading a mod. This behavior got moved to the new function Misc.SetWideFullscreen
  • Fixed the FPS counter becoming desynced from the debugger so at least one of the two would always be visible in some cases
Audio and Sounds
  • Fixed a bug causing a + character anywhere in the full path to a mod's Audio or Sound files preventing said files from loading
  • Fixed a bug where loading a song using NewAudio.PlayMusic with loop as false would force the song to not loop whenever played with Audio.LoadFile
Special Variables
  • Fixed a bug where the variable waves will be set to an empty table on encounter start and after a wave ends, and Wave is nil at encounter start. The intended behavior is that the variable Wave should be set to an empty table in these events, rather than waves.
Sprites
  • Fixed sprite.Dust forcing sprite objects to move to (0.5, 0.5) pivot
Bubbles
  • Changed the <wideness> tag in Speech Bubbles to <width> for clarity (but bubbles with only <wideness> set will still work the same)
  • Fixed Text Object speech bubbles having less width than the entered maximum text width
  • Fixed Text Object speech bubble tails having reversed directions when entering a number as opposed to a percentage
  • Fixed Text Object speech bubble tails having a 10-pixel offset on any given side
  • Fixed being unable to override the engine's dialogue bubbles in a mod in the same way you usually do for Default sprites
Functions & Events
  • OnHit and Update no longer execute in the reverse order as they did in v0.6.3
  • No more error message when using CreateLayer if a sprite layer already exists
  • Fixed calling State in DefenseEnding causing the new state to be entered twice
  • Fix ability to enter "ACTMENU" with empty command list through State (contributed by @deonix37)
  • Fixed errors in WaveEnding not providing a script name
The Player Object
  • Fixed Player.SetMaxHPShift behaving oddly towards the player's regular (yellow) hp
  • Fixed a bug where reviving the player through BeforeDeath cancels invincibility frames they would have received
  • Fixed a bug where setting the Player's hp to 0 or less in BeforeDeath would remove the player
Text Managers (encounter text, battle dialogue, enemy speech bubbles, text objects and overworld dialogue)
  • Fixed a bug where the second column of the ACT and ITEM menu had its x position altered by Misc object properties that move the camera
  • Fixed using State with some states immediately in EncounterStarting sometimes leading to huge errors because the battle text manager didn't have a font set yet
  • Fixed text effects in BattleDialog and encountertext persisting into other game states
  • Fixed an infinite loop when placing a single [ at the end of any Text Object's text
  • Fixed a lot of issues with the "autolinebreak" system:
    • Text managers no longer allow 1 character past their width limit in certain conditions
    • Fixed an inconsistency where automatic line breaks would move an extra character down to the new line when it wasn't actually going past the width limit
    • Fixed multiple infinite loops possible through passing very long words or lines to various text managers
Text Commands
  • Fixed a compatibility problem where [waitall:0] worked in Unitale but froze text completely in CYF
  • Fixed a bug where using [health:kill] from BattleDialog would move the battle TextManager to a different scene entirely and have it be invisibly typing and producing sounds even in the mod selection screen
  • Fixed an engine freeze when trying to skip text with certain arrangements of commands at the end
  • Fixed [lettereffect:shake] not returning letters to their starting positions after each frame, causing them to fly away infinitely
Text Objects
  • Fixed a bug where giving a text object a sequence such as {"[instant]ONE", "[instant]TWO", "[instant]THREE"} would always instantly delete the text object when going to the next line
  • Fixed a bug where using SetFont before SetText would ignore the SetFont call
  • Fixed a bug where using [func:x] to call SetPause on a text object would still show the next character, regardless of speed
  • Text.SkipLine() now takes playerskipdocommand into account
The Misc. Object
  • Fixed a bug where, when ending a battle with a displaced camera, for 1 frame the camera will move back to (0, 0) which can cause unwanted graphical behavior
The Overworld (long)
  • Fixed error messages in the Overworld for good!
  • Removed, edited and formatted some Overworld player names
  • Even though CreateSprite was said to be added to the Overworld in CYF v0.6.3, it actually wasn't. So it's been added. For real this time. ಠ_ಠ
  • Even though CreateText was added to the Overworld, it created the text object in a completely different scene than it was supposed to, so it was never seen anyway. This has been fixed, too.
  • Fixed the player's speed getting set to 2/3rds of the intended speed whenever using the character selector
  • Fixed the pivots of shared sprites between Overworld scenes and encounters being different depending on which occurence was seen first
  • Fixed General.Save()'s undocumented boolean argument freezing code execution if used
  • Fixed auto-interacting with events on the same frame as closing a text box opened from the menu (such as the cell phone text)
  • Fixed SetDialog recognizing a Z press the same frame you start an event, which could combine with [instant] to skip a line immediately
  • Fixed being able to press Z to activate confirm events during map transitions and during the fade in while loading your save
  • Fixed a frame-perfect softlock if you open the menu the frame after closing it
  • Fixed the overworld text manager always keeping the last effect applied through [effect:x]. Now it resets automatically whenever using your menu, calling General.SetDialog, and calling General.SetChoice
  • Fixed General.SetChoice changing the overworld text manager's character spacing even after the choice dialogue has ended
  • Fixed soul in menu sometimes becoming black
  • Fixed invalid face sprites in SetDialog not showing an error
  • Fixed face sprites in the Overworld not resetting between lines of text
  • Fixed the Overworld camera always being 0.5 pixels off of where it should be vertically on big maps
  • Attached Debugger to Overworld camera when using Misc.cameraX, Misc.cameraY and related functions
  • Fixed the Overworld game over text being at the wrong height
  • Fixed General.GameOver behaving strangely with no arguments
  • Fixed Player.SetHP(0) erroring instead of triggering game over
  • Fixed Player.GetMaxHP() returning only the max hp offset instead of the player's total max hp
  • Fixed Player.SetMaxHP() being able to push the player into negative hp
  • Fixed the player's EXP resetting to their LV's minimum required EXP upon exiting a battle to the Overworld
  • Fixed the player's Max HP resetting to their LV's default Max HP when exiting a battle to the Overworld
  • Events can now only have one of each type of C# coroutine active, per type of coroutine. You can have both MoveToPoint and Rotate active at the same time, for instance, but only one of each at a time per event object that gets moved/rotated.
  • Fixed Event.Rotate always assuming its argument waitEnd was set to true, even if it was set to false
  • Fixed events moving different distances based on your frame rate which could lead to them getting stuck in walls and the player.
  • Fixed Event objects only being able to execute one "auto" page per event
  • Fixed an invisible buildup of game objects every time you open the box UI
  • Un-blurred many things, including the item box menu background, most maps and overworld sprites, and "press z or enter"
  • Fixed errors involving NewAudio channels in the overworld
Overworld Shops
  • Fixed the Shop scene's music sometimes starting at the play time of the Overworld music
  • Fixed shops always displaying the Talk text for option 1, regardless of which option you pick
  • Fixed shops not having a debugger and, as such, making your FPS display stuck on screen if you press F9, and making DEBUG useless in Shops
  • Fixed Text Objects appearing in the wrong scene when created in Shops
  • Fixed being able to press C for an error message and weird behavior while exiting the shop
  • Fixed being able to mash Z during the fade-out transition to stack up lots of screen transition objects
MoonSharp (Advanced Lua users only)
  • Fixed the second argument in error(message, level) being completely ignored. (ixjf on GitHub: One, Two, Three)
  • Fixed a bug where using debug.getinfo(n, "l") - where n is any number - would still only return the line number as if n was 1
  • After 3 years, error messages now properly display the name of the erroring file instead of chunk_2
  • Fixed debug.getinfo(..., "S") not retrieving the name of the source. It can now properly retrieve the name of the current lua file
  • Fixed a bug where some string library functions would match all characters that have the same lower byte as the character you are trying to match. (masaedw on GitHub)