About | Current Release |
---|---|
Version | v0.8.11 |
Date | May 7, 2017 |
Platforms | macOS |
Targets | macOS, iOS, emscripten, linux |
- Requires a Mac with Xcode and the iOS SDK.
- Plasmacore comes with an embedded copy of the Rogue language; you do not need to install Rogue separately.
To bootstrap a new Plasmacore-based project, open a Terminal in your new project folder and copy and paste the following command:
curl -O https://raw.githubusercontent.com/AbePralle/Plasmacore/master/Bootstrap.mk && make -f Bootstrap.mk
The command will fetch a bootstrap makefile which in turn will git clone
the latest Plasmacore repo in a temporary folder and copy all the files into the current folder.
There is some Rogue documentation here: https://github.com/AbePralle/Rogue/wiki
There is no Plasmacore documentation yet. You can manually browse the Libraries/Rogue/Plasmacore
files.
A sample Plasmacore game project is available here: https://github.com/AbePralle/PlasmacoreDemos
- Run the bootstrap command or manually clone the Plasmacore repo and copy everything except the
.git
folder into your project folder. - At the command line run
make ios
. The first build will take a while as intermediate files are compiled. - Open
Platforms/iOS/iOS-Project.xcodeproj
in Xcode and run on the simulator or a device. You should see a blue screen. - Edit
Source/Main.rogue
and add more game code. - Either run
make ios
again or just compile and run in Xcode again as a build phase automatically runsmake ios
. If you get an error in Xcode and you can't tell what it is, runmake ios
on the command line and you will see the compiler error message. - Add images to Assets/Images and load them by name -
Image("img.png")
,Font("SomeFont.png")
, etc.
make update
will update your current project to the latest version of Plasmacore (via git
and rsync
) without touching any game-specific files.
Plasmacore is released into the Public Domain under the terms of the Unlicense.
- [Dim.rogue] Added missing file Dim.rogue to repo.
- [Box] Added
Box.operator*(XY)
andBox.operator/(XY)
that scales both the position and the size of the box by the argument. - [Asset Compiler] Eliminated edge-tinting artifacts produced by resizing images in the image compiler (and class Bitmap). Before, fully transparent e.g. black pixels were being averaged in with neighboring pixels. Now fully transparent pixels are not averaged in at all.
- [Rogue] Updated to Rogue v1.1.38 with fixed-size list creation (e.g.
Dim<<Int32>>(3,4)
).
- [Image Filter] Plasmacore's image filter system which filters available images based on a wildcard path. New functionality includes
Plasmacore.clear_image_filters
andPlasmacore.add_image_filter("...")
, which can be used to specify multiple filters.Plasmacore.image_filter = "..."
works as before and is equivalent to callingPlasmacore.clear_filters.add_filter("...")
. - [View] Added
View.reload_images
. This finds all properties of the current view that are instanceOf eitherImage
orImage[]
and reloads them, unloading unused textures and loading new textures. As an example, sayPlasmacore.image_filter = "1024x768"
and you create aImage("BG.png")
- this might load the texture "1024x768/BG.png". If you change the image filter to be2048x1536
and callreload_images()
, first the texture1024x768/BG.png
will be unloaded (if it is now unreferenced)and then the texture
2048x1536/BG.pngwill be loaded. Note that the
ImageInfo` associated with each image is changing as a result of the updated filter and the image reloading, which is "how it knows" what to replace with what. - [Image] Fixed crash when an image isn't found. Now a message prints out and the image is loaded as a 16x16 opaque image.
- [Font]
Font.measure()
no longer attempts toload()
the font because that could result in attempting to load the font image hundreds or thousands of times ifmeasure()
was called fromon(PointerEvent)
rather thanon_update()
oron_draw()
. UpdatedSystemFont
andDefaultFont
to define their measurements without having to load their bitmap data. - [Rogue] Updated to Rogue v1.1.34.
- [GGList] Added a collection API to GameGUI
GGList
-list.count
andlist[0]
now work etc. - [GGList] GameGUI
GGList
is now available in a template form.GGList<<X>>
returns item typeX
fromget(index:Int32)
.GGList
may be used without a template parameter and the item type defaults toGGComponent
. The item type of the templated form must extendGGComponent
. - [GGList] Added
has_edge_bounce=true
property; set to false for hard scroll stops at edges. - [Font] Added optional
&visual
flag tomeasure()
methods that will measure pixel width instead of character spacing width.
- [AssetCompiler] Added
italic
option that can be applied to bothcreate
(font) andvarfont
to generate a font that is algorithmically italicized.
- [ImageManifest] Added
varfont
optionspacing:'{before:"-1:ABC",after:["-1:XY","-2:Z"]}'
to tweak before and after spacing for individual characters. - [XY] Removed
operator+(Real64)
andoperator-(Real64)
as it was usually called accidentally; there are few scenarios in which developers would want to increase or decrease bothx
andy
by the same amount.
- [Font]
load
is now automatically called at the beginning ofmeasure
. - [GGList] Smoother start to scrolling; does not jump as the pointer passes the movement threshold.
- [Rogue] Updated to Rogue v1.1.32.
- [AssetCompiler] Fixed AssetCompiler compile errors introduced in previous release.
- [Rogue] Updated to Rogue v1.1.31.
- [Makefile] Makefile now includes
Custom.mk
as well asLocal.mk
, allowing custom build targets that can be committed to the repo. - [Rogue] Updated to Rogue v1.1.30.
- [Swift] Tweaked Swift source to remove warnings due to language update.
- [Main.rogue] Removed vestigial testbed code.
- [Canvas] Render-to-texture is now supported through the
Canvas
class.Canvas
extendsImage
and is created at an arbitrary pixel size, e.g.Canvas(64,48)
. CallDisplay.set_render_target(Canvas)
to configure the Display to render to the canvas -Display.size
will then reflect the canvas dimensions, etc. - and thenDisplay.remove_render_target()
when finished. - [Display,RenderTarget] Split
Display
intoDisplay
andRenderTarget
. The former is still the interface and the latter is used internally to model the main display target as well as canvas/offscreen buffer display targets. - [Clipping Region]
Display.push_clipping_region(Box)
has been changed toDisplay.push_clipping_region(Box?,&replace)
. If the existing and new clipping regions are both non-null then the updated clipping region is the intersection of both, unless&replace
flag is specified, in which case the new region replaces the old. Pushingnull
will clear the clipping region, but popping will still restore the previous clipping region if it existed. - [XY] Added global convenience method
XY.zero()->XY
that returnsXY(0,0)
. - [Quad] Renamed class
Corners
toQuad
. - [Rogue] Updated to Rogue v1.1.28.
- [Update Cycle] Reworked update cycle regulator. The
Display.on_render
message can now send arefresh_rate
(default 60) parameter which is stored inDisplay.refresh_rate
. This is used in conjunction withDisplay.updates_per_second
(default and recommended setting 60) to ensure the specified number of updates per second independent of the display refresh rate.
- [UpdateTimer] Reworked the update mechanism to have a consistently smooth 60 FPS.
- [Display] Added
updates_per_second
which will be 60 in most cases. This reflects the fixed screen refresh rate and does not fluctuate over time. - [Display] Added
update_scale_factor
which will be 1.0 in most cases. Ifupdates_per_second
were 120 thenupdate_scale_factor
would be 0.5 etc. - [Circle]
draw()
andfill()
are now higher-resolution operations by default and create smooth circles on Retina displays. - [Pointer] Fleshed out Pointer class. The positions of active presses are now tracked with
positions:XY[]
.position:XY
now reflects the position of the first active press (if one or more) or of the last active press (if no active presses). - [GGList] Removed vestigial reference to
PointerEvent.id
.
- [Display] Fixed initialization bug that had the transformation matrix slightly wrong on the first rendered frame.
- [Image] Custom
render_mode
settings now work correctly again. If you set arender_mode
that includes a blending mode then your render mode will be used as-is. If you don't include a blending mode then any render mode flags you set (likeRenderMode.POINT_FILTER
) will be merged with an automatically chosen render mode. - [Circle] Fixed
Circle.intersects(Circle)->Logical
. - [SystemFont]
snap
pixel positioning now enabled by default. - [macOS] macOS default window now 1024x768, centered.
- [macOS] Right mouse button events now sent correctly on macOS.
- [Keyboard] Key events now correctly set
Keyboard
flags forKeyboard.is_key_pressed(keycode:Int32)->Logical
. - [Events] Some light refactoring and cleaning up of pointer and scroll event code.
- [OverlayLog/SystemFont] OverlayLog now uses a cloned copy of SystemFont to isolate changes to SystemFont opacity etc.
- [Image Compiler] Renamed image attribute
rescale
toscale
(rescale
still works for compatibility). Addedresize
image attribute. - [Image Compiler] Added
display_size:WxH
image attribute. - [Makefile] Removed outdated filepaths in
clean
target.
- [RichText] Added new class RichText for composing and displaying text with multiple colors.
RichText(font).set(color).print("...").set(color).print("...")
to create and.draw(position:XY)
to draw. Can set the.anchor
; defaultAnchor.TOP_LEFT
. - [Web/Linux] Added simple and customizable
Main.cpp
toPlatforms/Web
andPlatforms/Linux
that calls a new object-oriented launcher for a simple way to define window title and display size. - [SDL] Replaced the STL code with custom classes in the SDL library files for a 10% JS code size savings in the Web target.
- [PlasmacoreMessage.swift] Fixed bug in
set(String,[UInt8])
. - [Circle] Added
Circle
class withdraw(Color)
,fill(Color)
, and variousintersects()
methods. - [Corners] Added various
intersects()
methods. - [Line] Added
Line
class withdraw(Color)
,fill(Color)
, and variousintersects()
methods. - [Triangle] Added
Triangle
class withdraw(Color)
,fill(Color)
, and variousintersects()
methods.
- [Build] Consolidated ImageCompiler and SoundCompiler into single AssetCompiler.
- [Build] Asset compiler now tags images
is_opaque:true
if appropriate. - [Image] Now using image info
is_opaque
instead of textureis_opaque
since the latter was hardly ever true for image sheets. - [Image] Removed
Image.search_paths:String[]
in favor ofPlasmacore.image_filter:String
.Plasmacore.image_filter = "iPadRetina"
will constrain image loading based on partial filepaths to only those filepaths containing the wordiPadRetina
. Wildcard patterns may be used. - [Display] Fixed error on initial uv buffer capacity (possible crash issue).
- [Display] Added
world_transform
as an intermediate matrix for 3D support. - [Display] Fixed order of object transform multiplication.
- [Display] Renamed
default_unit_z
andunit_z
todefault_z
andz
. - [Display]
z
is now explicitly rather than implicitly negative. - [Angles] Renamed compound
Rotation
toAngles
. - [SystemFont] Restored black letter outlines by shifting call to
Bitmap.convert_gray_to_alpha
out of the ImageSheetBuilder and intoDefaultFont
which is the only font the call is necessary for. - [Shader] Switched built-in shader definitions to use verbatim strings for clarity and simplicity.
- [Shader] Reorganized image shaders as globals under the Image class -
TextureShader
is nowImage.TEXTURE_SHADER
and so forth. - [Web] Plasmacore now includes <emscripten.h> by default for EM_ASM() support.
- [Web] Makefile now reads project name from Settings.mk, creating that file if it doesn't exist and using the folder name as the project name by default. [Web] If Platforms/Web contains a file called
index.html
, that file is copied into the build folder alongside the generated .html file. - [Web]
Platforms/Web/HTMLAssets
folder is now copied, if it exists, toBuild/Web
. - [Web/SDL] Renamed
Libraries/Plasmacore/SDL/*
files to beUpperCamelCase
instead ofunderscore_names
. - [Plasmacore] Renamed
data_folder()->String
touser_data_folder()->String
and addedapplication_data_folder()->String
.
- [Publish] Correcting master/develop sync issue.
- [Random] Changed
Random.realcolor()->Color
toRandom.color()->Color
.
- [iOS] Renamed project template from
iOS-Project
toProject-iOS
. - [macOS] Renamed project template from
macOS-Project
toProject-macOS
. - [Web] Renamed target
emscripten
toWeb
- usemake web
to compile. - [Web] Fixed
DefaultFont
/hello world transparency issue. - [Web] Removed embedded JPEG library (for now?) to reduce generated code size.
- [emscripten] Plasmacore now supports an "empscripten" asm.js target through "make emscripten" (produces JavaScript game).
- [linux] Plasmacore now supports a "linux" target. Uses SDL. Type "make linux" on Linux; may have to manually install any libraries reported as missing.
- [TextEvent] Separated the concepts of keypresses and text input.
KeyEvent
no longer containsunicode
values. A newTextEvent
has been added that containscharacter:Character
,text:Characters
, and a charactercount()->Int32
. Displays, Views, Layers, and States now have bothKeyEvent
andTextEvent
handlers. - [ScrollEvent] Separated the concept of a ScrollEvent (mouse scroll wheel) from PointerEvent.
- [Layer] Added a "Layer" system to
View
. Views now have a list of layers; each layer is automatically hooked into the event chain when it is added to a view withView.add(Layer)
. Most events such ason_update
andon_draw
are sent to layers in a first-added order; pointer and key events are dispatched in reverse order. - [Layer] Layers have an
is_visible
property which defaults to true and can be affected byLayer.hide()
andLayer.show()
. A hidden layer does not receive update, draw, or input events. - [ActionCmd] Added constructor
ActionCmd(callback:Function(Real64),duration:Real64,progress_fn:Function(Real64))
. - [GameGUI] Added base classes for the "GameGUI" user interface system. A
GameGUI
class is a Layer that various GGComponents can be added to. - [CompositeImage] Restored CompositeImage class (was commented out).
- [Image] Images can now have a drawing callback:
Image.on_draw(Function(Box))
is used to set the callback. The callback function is called after the basic image is drawn and while various transformations and settings are still in effect. Particularly useful for composite images. - [Image] Fixed premultiplied alpha issue with images (premultiplication was happening twice on iOS and macOS).
- [ProgressFn] Added the full set of standard easing functions to
ProgressFn.rogue
. Convention is e.g.ProgressFn.BOUNCE
,ProgressFn.BOUNCE_OUT
,ProgressFn.BOUNCE_IN
. - [DefaultFont] Added new built-in font called
DefaultFont
. The font is a 34 pixel high Arial Bold. - [XY] Added
XY.or_larger(XY)
andXY.or_smaller(XY)
the return the largest/smallestx
and largest/smallesty
between the context value and the parameter value. - [Box] Added
Box.relative_to(Anchor)->Box
. - [Messaging] Changed
Application
message names toApplication.on_launch
,Application.on_start
,Application.on_stop
, andApplication.on_save
. Renamed messageDisplay.render
toDisplay.on_render
. - [Display] Added
Display.push_clipping_region(Box)
andDisplay.pop_clipping_region()
. Pushed clipping regions operate as an intersection with the current clipping region. - [State] Modified behavior of
queue_state()
to perform the state chaining itself if its view is null rather than having the current Display perform the chaining. - [Sound] Added global property
Sound.mute:Logical
. No sounds play when this is set totrue
. - [Sound] Fixed
Sound.duration()->Real64
. - [SoundGroup] SoundGroup now extends Sound so that sound groups can be added to other sound groups. SoundGroup now accepts the flag
&replay_last
which will keep replaying the last sound in the sequence once all other sounds have played; callSoundGroup.reset()
to start the next play from the first sound. - [Image Compiler] Added optional
monospace
andmonospace:numbers
attributes tocreate image:...font:
directive. - [Build System] Actually fixed IDE flag to be passed properly.
- [OpenGL] Fixed OpenGL rendering crash bug by switching dynamically sizing vertex buffers to be fixed size.
- [OpenGL] Added new
OpenGL
wrapper singleton with a methodmax_texture_size()->Int32
. Will shift other embedded OpenGL code there over time. - [OpenGL] Shaders now use
highp
precision if the max texture size is >= 2048 and OpenGL supports it. - [Rogue] Updated Rogue to v1.1.23.
- [Libraries] Deleted now-unused embedded FreeType and HarfBuzz libraries.
- [Build System] Fixed IDE flag to be passed properly to roguec from Makefile and BuildScriptCore.rogue.
- [Build System] Fixed ImageCompiler BuildScript to use project
roguec
instead of globalroguec
. - [View] Added a
state
setter than performs achange_state()
call to avoid an incongruent error. - [State] Added a
change_view()
method for symmetry withView
'schange_state()
. - [Rogue] Updated Rogue to v1.1.14.
- Fixed command line error invoking the Sound Compiler.
- [Rogue] Rogue program now compiles to
.mm
for iOS and macOS which allows inline ObjectiveC to be used in addition to inline C++. SeeLibraries/Rogue/Plasmacore/iOS.rogue
for an example. - [iOS] Added
iOS
class with global methodstatus_bar_height()->Int32
(pixels).
- [ImageCompiler] Added command to generate font strip images from local or system fonts. Syntax:
create image:<image_name.png> font:<"Font Name.ttf"> height:<pixels> [characters:"ABC..." unicode:[32-127] ...]
. The image compiler will find the font by searching folders in the following order:Assets/Fonts/
,/Library/Fonts/
,/System/Library/Fonts/
. - [ImageCompiler] Moved Image Compiler off of vendored (local) PNG, JPEG, and FreeType libraries. Now uses Brew-installed versions of those libraries. Added companion
Libraries/ImageCompiler/BuildScript.rogue
to automatically manage the Brew-installed libraries during build. - [BuildScript] Renamed
Build.rogue
toBuildScript.rogue
andBuildCore.rogue
toBuildScriptCore.rogue
. - [Bitmap] Converted
Bitmap(width:Int32,height:Int32)
to be a global constructor to make it easy to call from the native layer. - [Bitmap] The default fill color of a Bitmap is now transparent black instead of opaque black.
- [ImageIO] Removed the "ImageIO" library from both iOS and Mac projects. Now using Core Graphics to load images for a 25% speed boost.
- [Rogue] Updated to Rogue v1.1.13.
- [OverlayLog] Fixed overlay log messages to be single spaced instead of double spaced.
- [Swift] Added
PlasmacoreMessage.getDictionary(name:String)
. - [Messaging] Added
Message.send_rsvp(response_message_type:String,callback:Function(Message))
. Rather than awaiting a formal reply to this specific message likeMessage.send_rsvp(callback)
does, this version installs a global one-time message listener to call the callback; the listener is not actually associated with this message at all. - [Rogue] Updated to Rogue v1.1.12.
- [Makefile] Created variables
REPO
andBRANCH
that can be overridden during an update, e.g.make update BRANCH=develop
.
- [Message] Added helper methods for sending and receiving JSON-encoded
Value
objects using the message passing system: Message.send(name,Value), .value(name), .table(name), and .list(name).
- [Rogue] Detailed Rogue error messages now show up in Xcode and can be jumped to by clicking on the error.
- [XY] Fixed error in
XY.magnitude()
(was incorrectly made into a[macro]
). - [Image] Added constructors for
Image(Color,[size=Display.size:XY])
andImage(Colors,[XY])
. - [Box] Added
Box.fill(Colors)
to complement existingBox.fill(Color)
. - [Plasmacore] Removed
Plasmacore.launch_window_name
. - [ImageCompiler] Fixed bug that in some cases prevented image sheets from being reduced in pixel size as much as possible.
- [System] Augmented
System
class with global methodsSystem.is_desktop()->Logical
andSystem.is_mobile()->Logical
. - [Colors] Removed ambiguous constructor
Colors(Color*4)
that was already covered byColors(Color*4,Int32=4)
. - [Rogue] Added appropriate
Desktop
orMobile
target to each compile for use with conditional compilation directives. E.g.$if ("Mobile") ...
. - [Rogue] Updated to Rogue v1.1.11.
- [Swift] Renamed
PlasmacoreMessageHandler
toPlasmacoreMessageListener
to match Rogue-side name. - [Swift] Converted
Plasmacore.singleton.addMessageListener(...)
toPlasmacore.addMessageListner(...)
; same forremoveMessageListener
.
- [Mac Project] Added missing
Build/Mac/Assets
folder reference to Mac Project.
- [Plasmacore] Added
on_resize()
andafter_resize()
toView
andState
, called beforeupdate
anddraw
events when the Display.size has changed. - [Plasmacore] Improved and streamlined the update and draw event API, removing the
on(UpdateEvent)->on_update
chain in favor of callingon_update
directly; same withon_draw
.
- [Mac] Added Mac project.
- [OverlayLog] Overlay text now never scales below 1.0.
- [Makefile] Changed
make update
to use HTTPS instead of SSH for thegit clone
operation.
- [Image] Added
original_size
property that tracks the image's original display size.
- [Plasmacore] Fixed
Display.clipping_region
to work on iPhone Plus with regular and zoomed displays.
- [Image Compiler] A non-"." image group that does not have a wildcard in the path now compiles correctly.
- [iOS Project] An
Application.save
message now gets sent onapplicationWillResignActive
instead ofapplicationDidEnterBackground
andapplicationWillTerminate
. - [Rogue] Updated to Rogue v1.1.4
- [Rogue] Fixed bug in
Value.to_json()
wherefalse
would print asnull
.
- [Rogue] Fixed fatal compile error bug in 0.4.1 release.
- [Rogue] Updated Rogue to v1.1.3.
- [Plasmacore] Image compiler meta-info output format and corresponding Plasmacore image info loading system reworked for massive savings. File sizes are reduced by half and runtime object counts are reduced by a factor of 10.
- [Box] Creating a
Box
from aValue
withBox(Value)
now works with value lists -Box(@[3,4])
is equivalent toBox(&size=XY(3,4))
andBox(@[1,2,3,4])
is equivalent toBox(&position=XY(1,2),&size=XY(3,4))
. - [iOS] Now displays correctly on iPhone Plus - glViewport needs physical pixels (1080x1920) while the rest of the rendering system needs the internal display buffer size (1242x2208).
- [App Lifecycle] Added State/View
on_app_start/stop/save
methods based on globalApplication.start/stop/save
events. Timers and such should be stopped and started with those methods.save()
is called when the app may or may not resume execution and should save its state.
- [Image Compiler] Fixed bug where the same image being copied+resized more than once starts with the original image each time.
- [Rogue] Updated to Rogue v1.1.2.
- [Display] Added
Display.clipping_region:Box?
which sets up the "scissor test" that clips any drawn images to the given bounds. Assign a valid box to define and enable the clipping region ornull
to disable it. - [Image System] Removed kludgy
Plasmacore.default_asset_folder
in favor of a global propertyImage.search_folders:String[]
. Modify the folders as you like by adding e.g.iPadRetina
to thesearch_folders
list, allowingImage("Name.png")
to be used rather thanImage("iPadRetina/Name.png")
etc. - [Image System] Any path-shortened form of an image can now be used to load the image. For example,
Image("iOS/BG.png")
can now be loaded asImage("BG.png")
.
- [Sound] Added
Sound.duration()->Real64
that returns the duration in seconds. - [Sound] Added
Sound.is_finished()->Logical
that returnstrue
if a sound is not playing and not paused. - [Sound] Added
Sound.is_playing()->Logical
. - [Sound] Added
Sound.is_repeating:Logical
. - [Sound] Added
Sound.pause()
that stop a sound without rewinding it.play()
orresume()
will play the sound again. - [Sound] Added
Sound.play(is_repeating:Logical)
in addition toSound.play()
. - [Sound] Added
Sound.position:Real64
that specifies a sound's playback position in seconds. - [Sound] Added
Sound.resume()
that resumes playing a sound only if it has been previously paused. - [Sound] Added
Sound.set_volume(Real64)
that accepts an argument between 0.0 and 1.0. - [Sound] Added
Sound.stop()
that stops a sound and rewinds it to the beginning. - [SoundGroup] Created new
SoundGroup
class to manage a set of related sounds, like multiple copies of a single sound effect or multiple variations of a sound. - [SoundGroup] Added constructor
SoundGroup.init(sound_name:String,channels=1:Int32,&is_music)
. - [SoundGroup] Added constructor
SoundGroup.init(&random,&random_order,&autoplay)
. The&random
flag picks a sound randomly each time.&random_order
is similar but it plays all sounds in a random order before repeating any of them, reshuffling each time before another pass.&autoplay
automatically plays another sound when each sound is finished - noteSoundGroup.play()
must be called once to start the process. - [SoundGroup] Added
SoundGroup.add(Sound)
which adds another sound to the group. - [SoundGroup] Added
SoundGroup.play()
that plays the next sound from the group. - [SoundGroup] Added
SoundGroup.pause()
that pauses all sounds in the group. - [SoundGroup] Added
SoundGroup.resume()
that resumes all paused sounds in the group. - [SoundGroup] Added
SoundGroup.stop()
that halts playback of the group.
- [Sound Compiler] Added new Sound Compiler that works similar to the Image Compiler. It is automatically invoked during an Xcode build or you can manually
./scom iOS
to run it. It uses theAssets/Sounds/SoundConfig.txt
build script, creating a default version necessary. - [Sound] Added
Sound
class. Create a sound withSound(name:String,[channels=1:Int32])
.name
should be a filename inAssets/Sounds/
; you can omitAssets/Sounds/
as well as the extension.channels
is the number of times that sound can play concurrently - each additional number ends up creating a new sound player underneath so don't use more than 1 channel if you don't need to. - [Sound] Call
Sound.play()
to play a sound. Additional sound API calls will be added later. - [AVFoundation Framework] You must manually add the
AVFoundation
framework to any existing projects. - [Image Compiler] Renamed
imageCopy
command tocopy
.
- [Image Compiler] Improved wildcard matching for
group
specifications. - [Image Compiler] Changing
Assets/Images/ImageConfig.txt
no longer causes an image sheet recompile due to timestamp difference. If you need to recompile existing images with new settings, do amake clean
first. - [TargetValue] Changed original initializer to default to
ProgressFn.QUADRATIC
instead ofLINEAR
. - [TargetValue] Added new initializer
init(initial_value,duration_fn,progress_fn=ProgressFn.QUADRATIC)
.duration_fn
should be of typeFunction($DataType)->(Real64)
, accepts a delta interval, and should return the desired duration for that interval. TheTargetValue
will automatically adjust the duration as new target values are set, effectively allowing a rate-limited rather than time-basedTargetValue
.
- [Image Compiler] Changed convention of Image Compiler to use
camelCase
commands withserpent_case
arguments, like Rogue. - [Image Compiler] Added
resize:WxH->WxH
option to Image Compiler'simageCopy
command. - [Image Compiler] Removed vestigial reference to 'freetype-2.6.3' folder in Image Compiler's Makefile.
- [iOS Xcode Project] Added missing Swift files to iOS template project.
- [Image Compiler] Replaced complex Asset Manager (
AM
) with simple Image Compiler (ICOM
) that works off the scriptAssets/Images/ImageConfig.txt
. ICOM will automatically create a default config script if that is missing. ICOM is automatically run as part of themake ios
build.
- [Bootstrap] Instead of copying all hidden files, now copies only
.gitattributes
and.gitignore
and uses the--ignore-existing
rsync option. - [ActionCmd] Added
ActionCmd(Function())
constructor that creates an action command that calls the given function when invoked. - [Image]
Image(existing:Image,subset:Box)
now works correctly even when theexisting
image hasn't been loaded yet. - [Image] Renamed
alpha
toopacity
(controls master opacity, defaults to1.0
). - [Image] Fixed
opacity
to work correctly with opaque images (was previously not enabling blending). - [Font] Renamed
alpha
toopacity
; opacity now actually applied to font drawing. - [TargetValue] Consolidated
TimeLimitedTargetValue
andRateLimitedTargetValue
into single classTargetValue
. - [TargetValue] A
start_time
of 0 now signals a finished state internally; once target value is reached thenstart_time
is set to 0 to avoid subsequent duration changes "restarting" animation. - [XY] Added
operator==(XY)
to provide a better implementation than the current Rogue-generated default.
- [Bootstrap] Added bootstrap mechanism detailed in README.
- Initial release.