Skip to main content

Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines

ahmwma

386
Posts
7
Topics
270
Followers
214
Following
A member registered Mar 18, 2017 · View creator page →

Creator of

Recent community posts

(1 edit)

Here's an at-a-glance selection of some ways to refer to different kinds of stored data in basic widgets, using attributes:

Buttons: .value (boolean true/false)

Fields: .text (plain text) .value (rich text) .data (LOVE data) or .images (images only) 

(it's a little visually chaotic but an interactive example of the difference between these four can be found here)

Canvases: .copy[] and .paste[]

Sliders: .value (the number it's currently set to)

Grids: .value (for the whole table), .rowvalue and .cellvalue

---

And to refer to a .value attribute of a widget on the same card:

widgetname.value

Or to refer to a .value of a widget on another card:

othercardname.widgets.widgetname.value

And if things have less script-friendly names you can refer to them with square brackets:

deck.cards["Silly Card Name"].widgets["I'm a Widget"].value

---

I hope this helps point you in the right direction!

Beautiful 🤍

I've poked around a little bit and I suspect you got a version of Font Importer from this font pack that coral nulla imported. (Just connecting the dots for the curious)

This is a long post for a relatively short process, I promise.

Preparing your image of your font:

• To import from an existing image of a font you'll need your image to be plain black pixels on white.

An anti-aliased version of the font (where there's gray or semi-transparent pixels to soften edges and corners) just won't import well -- there will most likely be strange or missing pixels as Decker will have to decide how to interpret those grays into black and white.


• The image of your font should also ideally be able to fit on a card.

Without modifying the font editor deck to be bigger I'd say the easiest maximum width to import directly onto the Sheet card would be 370 pixels wide. Up to 500 pixels wide is okay if you're importing on a second empty card and then copying them over to the Sheet editor after importing them.

If the current image you have is bigger than that maybe you can take a slightly narrower sample of your font (not by resizing the glyphs, just by arranging it into more rows and fewer columns). Or alternatively maybe you could cut your source image into several smaller images which all fit on a card and then copy and drag them into the correct position inside Decker.

The last thing we're going to need as preparations are the measurements of the size of a glyph inside the font. 

We need the absolute maximum dimensions that any glyph will ever need for the width and height. This might include accents above letters, descenders below letters for lower case characters or the full width of the dark rectangle of a blackout version of a letter. (Or not including those things, if your font doesn't need them)

You can measure this in another program using your source image, or measure it inside of Decker once you've imported an image. If your font doesn't use accented characters or have separate glyphs for lower case then just pick a size that works for the characters you do need.

Slightly larger than needed is easier to work with than slightly too small.

----

On measuring in Decker:

This an example of measuring a glyph of the Menu font in Decker. I'm getting the information about my selection box using [View > Show Cursor Info] . The first pair of numbers is the location of the top left corner of the selection on the card (not important for what we're doing) and the second pair of numbers is the size of the selection box. So I might set this font to be at least 12x12 if I was editing it. That's probably a little too wide but it's an okay place to start and gives me a little extra white space to work with. (Actually it seems like this font is 13x16! Huh! Good to know! Definitely give yourself a little extra space.) Your font will probably be a little bigger than this.

Again... a pixel or two bigger than the ideal size is easier to work with than making it too small.

The last thing is a bit of a tangent but I wonder if it would be easiest to start by importing the non-blacked out font first, and then you'd have the option of creating a blacked out version easily inside decker rather than going through the import process again. It's up to you though, and I'll come back to the idea of making your own version of the blacked out font at the end of this post.

----

Okay, let's go into examples/fonts.deck, and click the Font Editor button.

The first step would be to make a New Font and name it something recognizable.

If you already have your glyph measurements you can enter them now on the main Font Editor card and click the 'Set Grid Overlay to Font Dimensions' button. 

If you need to measure it after importing a image of your font then you can come back and do this once you have it.

Clicking on "Sheet" shows us an example of glyphs in a grid, probably using Decker's Menu font by default (unless you've previously erased or replaced it).

If we go into Widget mode on this card we'll also see there is a widget (it's an empty button) surrounding the area of the card with the font in it. This empty button widget is the guide Decker uses to define the area of the workspace, so it can identify where your glyphs are and turn them into a font. You can see how the letters fit inside the grid overlay and the grid overlay matches the size of the working area here:


We're going to use the Grid Overlay to make it easy to fit the characters of your font into this work space. The order of glyphs will matter, but we'll make a guide for that soon too. And you don't need to do anything about accented characters if you don't have any of them in your project.

I'd recommend turning on the Toolbars because we'll be adjusting things in Drawing Mode at first and it makes all of the relevant tools more available. You can do this with [Decker > Toolbars]

We'll mostly need the selection tools, but also the top two buttons (pointing hand and button) will switch us into interact and widget modes when we need to go to them. I just find it really easy to use that while working, so I always recommend it.

----

When importing your font image:

Drag an image from your file system onto your open Decker window or use [ File > Import Image... ] in the menu.

While it's still in the first selection box after being imported -- if it seems smaller than it should be -- you can use [Edit > Resize to Original ] to make sure it's at the original full size. 

We're going to want to import your font image into the empty space at bottom of the Sheet editor, or make a new card if you need more space to work with it before arranging it on the Sheet.

If you haven't measured the maximum size of a single glyph yet, do that now. Plug those measurements into the UI on the main Font Editor page and click the 'Set Grid Overlay to Font Dimensions' button. We're about to use the Grid Overlay.

----

Setting up the working area:

Go into the [ View ] menu and select [ Show Grid Overlay ] to make the dot grid appear.

We'll set up the working area widget with [ View > Snap to Grid ]

Go in to Widget mode and select the workspace-marking empty button widget and move it a little so the top left corner is lined up on a grid dot. Because of Snap to Grid the widget will position itself that way whenever you move it, but you do need to move it once to force it to snap into alignment. 

Resize the widget, giving yourself a comfortably big workspace without bumping into the other UI elements or going off the side of the card. Again, this widget will snap its dimensions to the grid because 'Snap to Grid' is active.

Count how many columns this is and we'll use that number make an easy guide for glyph placement.

This is the character list for the DeckRoman character set in order.

 !"#$%&'()*+,-./0123456789:;<=> @ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~…ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖØÙÚÛÜÝÞßàáâãäåæçèéêëìíîïðñòóôõöøùúûüýþÿĀāĂ㥹ĆćĒēĘęĪīıŁłŃńŌōŐőŒœŚśŠšŪūŰűŸŹźŻżŽžȘșȚțẞ¡¿«»€° 

Keep in mind that the first glyph in the first row is an empty space!

If your working area has 15 columns, then you can copy that list of characters and split it into 15 character long strings to give you a guide for positioning your glyphs. 

 !"#$%&'()*+,-.
/0123456789:;<=
>?@ABCDEFGHIJKL
MNOPQRSTUVWXYZ[
\]^_`abcdefghij
klmnopqrstuvwxy
z{|}~…

The original font that was there on the card won't be set to your grid size. It's still an accurate guide for the order, but not the for exact placement in the grid overlay.

----

Okay! Whew! 

• We have a nice big area that fits a grid overlay that can contain our glyphs! 
• We have the images of our glyphs! 
We have a guide for their positions!

Everything gets so much easier from here.

Time to move the glyphs into the grid overlay.

Some optional adjustments you might want to make while moving things around:

You may want to turn [View > Snap to Grid] off now, so you can choose the size of your selection boxes while you're moving things. (Or you can use ctrl + p to toggle this on and off, if needed)

You may want to turn [Style > Transparency] ON so that the background white of the card will be treated as a clear transparent white while you're moving things around. (Or use Ctrl + T to toggle this on and off, if needed) 

And remember that you can 'nudge' selections by a single pixel at a time with your arrow keys.

----

Set up is done! Time to arrange some letters.

Just use the selection box tool (or selection lasso, if you prefer) to move your glyphs into the right locations, according to your guide. You'll be working in Drawing mode until you're done with this process.

If they're not lined up perfectly inside their section of the grid overlay don't stress out too much. It's very easy to adjust that later in the Glyph editor. Getting the glyphs in the right grid overlay spots is the most important thing right now.

Got them all in place? Switch to Interact mode and click the "Apply" button on the right side of the Sheet card.

Congrats, you have a font! I'd recommend saving your progress now, if you haven't!

(By saving the deck from the menu, like normal)

You can take a peek at the font as it currently exists in the field on the bottom right of this card. Some letters may be too high or low or otherwise weirdly spaced. You can adjust their placement here on the sheet and "Apply" it again OR you can adjust them in the Glyph editor. Either way is fine.

----

Glyph  Editing:

Everything in the Glyph tab is used in Interact Mode.

You can move to specific letters with the "Go to Char..." button, or by scrolling with the 'characters' slider that's just below it on the UI.

Usually Glyphs start along the left side of the glyph editor box. but you may prefer more space because of the blackout version of this font. You can adjust the whole glyph's position within the area with the buttons on the sides.

And you can narrow the area of letters that take up less space with the 'width' option in the top left of this card.

(Like "I" vs "W", if you don't intend for your font to be monospace -- I'm not sure if you do or not.)

If you narrow a letter too much and snip off a pixel of it, you might need to draw it back on after re-widening it. You can click squares in the glyph preview (still in Interact Mode) to edit the pixels of your glyphs if you need to.

----

Okay, yay. That's one font possibly done.

So let's talk about a way to make the blackout version without going through that process again... while also making it match pixel-perfectly with the first one.

On the main 'Font' tab of the font editor, "Clone" your existing font and give the clone a new but related name.

Go to the Sheet Editor and click 'Load' -- this will pull the currently existing versions of your glyphs into the grid overlay in the correct locations for you.

In drawing mode, create selection boxes and use [ Edit > Invert ] (or ctrl + i on your keyboard) to create the blackout effect where you want it on your letters. Possibly just replicating their locations on your original font.

Click 'Apply' to apply these changes to your second font.

And now you have two fonts. Neato.

Save the deck again.

Go back to your actual project, drag and drop fonts.deck onto your open Decker project and transfer your two new fonts into it.

And then... hopefully enjoy your fonts? If you're confused about anything here I'm happy to try explaining it again.

WHOA! That's amazing!! I'm so happy to see the tool used for something so cool.

Not currently! Though the idea gets talked about sometimes.

I don't know if this would help but there's also Phinxel's Field Notes which a bit more colorful and conversational. It covers some of the same information that's in the manual but it presents it in a different way.

Click 'options' (above the crop button) on the drawing screen and enable 'Transparency Mask' by clicking this checkbox. 

The mask marker will be available on the drawing screen (under the color markers) when you go back to it.


---

A little more explanation, for the curious: the mask marker is always on the drawing screen, it's just hidden. The checkbox in the options menu changes the mask marker's visibility from "none" to "transparent" and changes the wiggly drawing canvas from "solid" to "transparent" which reveals the pattern on the card underneath it. So now you can tell the difference between the the transparent areas and the opaque white of the mask marker when you're drawing. :)

Yep, pretty much. Either by dragging and dropping another deck file onto your current project or by choosing a deck file when you're already inside the Font/DA mover you can move a variety of resources between decks (including fonts).

If you're editing one of the basic fonts that are always in Decker (body, menu, mono) it's probably best to copy them (inside the font editor deck, with the button option there) and give them a new name so they're easier to transfer over.

(And there's also another sneaky way to move fonts between projects. If you use a font in a field inside of the text editor deck and copy the field into your project, the new fonts it needs should come with it into your project too.)

It definitely doesn't need to be inverted! 

I think the second card was black in the example just to make the difference more obvious, but the contraption will use the appearance of the second card as it is. Whether it's normal 1-bit, inverted from your original or in color... anything should work just fine.

So, yes, using the dragable contraption as a magnifying glass to detect the small differences is absolutely a way you could use it!

(1 edit)

This isn't exactly what you were asking for (I think IJ has answered the actual questions, as asked) but here's some supplemental information and ideas.

Millie's (excellent and beloved) ColorText contraption isn't needed to color text in fields anymore. As of version 1.58 we're able to do it through the menus. (We're on version 1.63 now, so if you downloaded it recently this should be true in your copy) The drop shadow version of the contraption you linked to is still the best way to get a drop shadow effect though!

You can change the default color of a whole field by selecting it and using [ Widgets > Pattern... ], then select the color you want. You can change the color of a specific span of text by selecting it within the field and using [ Text > Pattern... ] to change the color for only that selection. You can also change fonts and create links using the Text menu. 

I think the exact things you were asking for are tricky in Decker because of the nature of unlocked fields. But the concept of revealing distorted text or uncovering hidden text is absolutely possible by other methods.

For example, this is an alternate approach to the concept of 'user interactivity to reveal text'... but have you looked at the Interior Contraption
If the 'true' version of the text is on another card it could be revealed by your player dragging something over it. This might give it a similar tactile experience to highlighting text -- but you also might need to explain what it is they're dragging around.

Or if you think of some other concept we might be able to help you build something to make it real.

Please do continue asking questions as they come up! It's always welcome and I'm very interested to see how your project develops.

The first issue that I see is that there is a 'Credits' button that doesn't give credit to the people who actually made the various decker examples and resources that you've combined into this deck. 

I suspect you don't have permission to republish these works but even if you did  have that permission I would consider proper attribution and a link to the origins of each component to be mandatory. It's irresponsible to make yourself appear to be the only source of a resource you're unable to maintain. 

Internet Janitor made the majority of the components of this, though other credits should go to woodring and to tangentstorm. (And to Millie Squilly and I , too. Some of our artwork has been copied in as well...)

My main feedback is that you should get proper permission to do this kind of project. 

My secondary feedback is that you should take some time to understand the things you've copied in their original context because Millie is correct, many things are broken because they're missing some component or they've been connected together incorrectly.

Have you made things yourself in Decker? It would genuinely be more exciting to see what you've made yourself.

Could you show examples of what's gone wrong? A screenshot of the layout problem, or an explanation of the parts that aren't functioning.

I'm very curious to know if it's something that can be fixed.

If it can't be fixed, then I'm sure someone here can help you get an older version to finish your current project.

I'm just drawing in normal Decker! There's a bunch of art tools built in to it.

The easiest way to use them for drawing is to turn on the Toolbars (In the menu: Decker > Toolbars)

When that's on your drawing tools will be on the left side of your window, and your current palette will be shown on the right side. 

You can switch between the 1-bit (pattern) palette and the 16 color palette by using the menu too (Style > Color). You'll need to have a drawing tool active to see the Style menu. (If this is confusing I'm happy to explain it again in a different way)

There's also this project over here which talks about how lots of different things work in Decker and it has a section about art and drawing which might point you to some other drawing features that you'll find useful.

People yearn for halftones and dithers! Thank you so much for checking it out.

I really hope this works out for you! If you have any trouble with the tool feel free to reach out. I suspect this thing will go through a couple waves of improvement over time.

Oh, gosh, um. Wow! No obligation to credit even if you do use this but if you wanted to be thorough you could say  something like "some brushes created with Dither Lab" with a link back here so people could use it in their own projects if they wanted to? That might be neat.

Good luck with your future projects :D

Really cool story structure! I played several times to see how different choices played out.

Absolutely superb presentation. I always love what you do in Decker but above and beyond that admiration I have for your craft this was just really good as an essay and as a presentation of the concept interwoven with the text. 

Thank you for sharing your end of year! 

Begone, shame box! It's time for fun and whimsy.

What a journey! And a fantastic collection of pogs.


(Good to see you, Loke!)

This is very beautifully written and presented. I hope and believe that you'll find what you're looking for.

Oh dang the look and feel of this. Stunning.

This is so tender and charming. I wish to protect this cookie.

I loved tilting to look at the art! I love everything. Really beautiful work.

Yay! You're so very welcome! Thank you for checking it out!

I love them all so much, and I love your stories about them. These are friends.

Extremely accurate, thank you for confirmation of my ducksona.

Yayy! I'm also really excited to try using this for stuff!

(1 edit)

Got mine done before the end, woohoo.... it's a temporary decker brush maker that's focused on patterns and ordered dithers.

I'm very excited to check out all the other projects.

Also, if anyone was almost there but didn't quite finish before the jam ended... Decker jams traditionally have a grace period of a day or two. 

After your project is up on itch you can reach out to Internet Janitor for a late submission link for the jam.

Thank you for reading!! Good luck with all of your projects!


Thank you for all of your help!


It's definitely break time now! Thank you so much for reading.

Thank you very much!! Good luck with your projects!

Oooooh :D love these.

A really fun deck! Buddy is a good dog, and that's the fax.

(1 edit)

I think the issue is just your parentheses () placement.  If we look at this line:

elseif (p.hour+1>10) & (p.hour+1<20)

You only need the parentheses to be around p.hour and your +1 adjustment to the time. Putting it in it's own set of parentheses makes sure that this part is done first before the script checks if the number is in the correct range . So you could change that line to be like this instead:

((p.hour+1) >10) & ((p.hour+1) <20)

Hopefully that makes sense?

Optionally, another way to do this would be to modify what p.hour is at the beginning of your script like this:

p:"%p" parse "%e" format sys.now 
utc_offset:1 
p.hour:24%utc_offset+p.hour

The first line is the same as what you have now.

The second line defines a new variable called utc_offset which I'm going to use to say how many hours off from utc your time zone is. (1)

And the third line sets p.hour to be p.hour plus your utc_offset. The 24% in this line keeps the result consistent with 24 hour time. So if the math it was doing for p.hour was 23+1 it would go back to 0 instead of up to 24.

If  this version makes sense to you then you could put this at the beginning of your script and just refer to p.hour for the rest of it without needing to modify it again, because it's already been modified.

I'm so glad it's useful! I hope you have fun with Decker!

I'm looking forward seeing what people make too!

Thank you so much for checking it out!

Fffff snow indeed! (I say, fearing its arrival)