Code Monkey home page Code Monkey logo

bitsy's People

Contributors

alexisdrain avatar ayolland avatar dependabot[bot] avatar equaa avatar le-doux avatar nashalexander avatar pirijuamps avatar ragzouken avatar samuelfine avatar seleb avatar slowlygoinground avatar tobiasvl avatar zachhixson avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

bitsy's Issues

auto-walk on reset

Hey, found a little bug in key-handling behaviour while working on some hack stuff.

Repro steps:

  1. start game
  2. press ctrl+r
  3. confirm
  4. press a direction key

Result: avatar automatically walks in the direction pressed as if you were holding the key down

Poked around for a few minutes and cause of the bug seems to be that the "r" from the reset gets added to the key list, but the up event is missed (confirm dialog is open at that point; bug fixes itself if you press "r" again while game is running). Could probably be fixed by preventing the "r" from getting added and/or clearing the list on reset.

Things go horribly wrong when there is no room with id 0

One of the most common problems we have to help people with is that bitsy stops functioning if you delete room 0. Despite that I just thought bitsy was broken for a few days before realising it happened to me.

I'm presuming that it would be a very small change to make Bitsy find an arbitrary room rather than specifically room 0, and it would help a lot of people

you can duplicate deleted sprites

Similarly if you delete a sprite the sprite still exists in the Find Drawing window. Then, if you click on a deleted sprite in the Find Drawing window and then click the duplicate button, the deleted sprite is 'duplicated' instead of the sprite that is actually open in the Sprite window.

https://itch.io/t/158872/bitsy-v40-bugs

Feature request: undo

I'm surprised no one else has requested this. The number of times I accidentally move an exit instead of an entrance, or accidentally move the avatar into a different room. An undo button would be amazing.

Feature Request: Adding some basic "nescessity," hacks natively into Bitsy

I know that Bitsy is supposed to be an engine where the goal is to limit you and let creativity shine, but I can't help but feel it's missing a couple of really small features that would still fit with that goal.

The features would be:

  • end / exit from dialog: The only place conditionals can be made is through dialog, so it's currently impossible to "unlock," the end of the game after completing a certain task. I believe this one is a must.
  • Extended logic operators: These would allow some more interesting dialog programming, and would give developers just a couple more choices on how they approached a situation. I'm kind of mixed on this one myself as to if it would fit or not, but still posting it here to see what you think.

These have been implemented as "hacks," but I feel like it's really difficult to make something interactive without them.

As a programmer who has already hacked into Bitsy quite a lot with my own games, I would happily work on these features myself (if possible, I haven't looked too deeply into the source yet) I just want to post here to make sure it fits with the future plans of Bitsy before I work on it.

Add a ReadMe / add a link to Itch.io?

Some may stumble across this before they stumble across it on Itch.io, it would be nice if it had a brief introduction or even just a link to Itch.io.

Feature Request: ‘Random’ List Type (like the old shuffle)

It came up in discussion that ‘shuffle’ lists now actually shuffle their list items instead of randomly selecting one. This is nice, makes dialogue a little more natural, and opens up new gameplay opportunities.

BUT many people were using the shuffle as a RNG in games, which it no longer works for, and there’s no really feasible way to add RNG back into Bitsy without hacks. It would great if there was a list type ‘random’ that had the old shuffle behavior, and just returned a random item.

Feature Discussion: Add / Remove object from dialog.

I think a way to add a remove objects from dialog would be nice. An example use case would be a door where you have to find a key. The door would be a sprite, and have a conditional dialog where

if hasKey
    {delete "keyDoor"}
else
    "The door is locked, and seems to require a key"

or

if hasIngredients
    {spawn "soup, 10, 5, roomName"}

I don't know if the GitHub is a good place ask this, but the discord seems more for the community and less for development so it's the best place I could find. If there is a better place, I will gladly post this there.

Basically I will happily program these features myself, but I want some feedback before I do so that I can implement them in a way that aligns with the goals of the developers.

Questions:

  • Should I allow deleting / spawning of items, or just sprites? Sprites would be easy, but removing items might require more input from the user since there might be more than one. The user might need to specify the X/Y location for example. I know Bitsy is built around "simple," so I don't want to make this too complex (unless you are fine with it). If no X/Y is specified, it could just delete the first occurrence.
  • Further, a "swap," function could be added to swap out one object for another. Once spawn / delete is added, this would just combine the two. Again, might not align with the "KISS," mentality of Bitsy though.

Bit larger sprites

Hmm.. say, 16x16 sprites, that would make porting old spectrum games for example to bitsy environment possible.

loading html files broken in version 6

In version 6, when I load a game downloaded as .html in an earlier version (saved last week), I just see the default new game room, so the loading seems to have failed.

Looking at the javascript console, I see the following:

bitsy.js:2065 Uncaught TypeError: Cannot read property 'pal' of undefined
at drawRoom (bitsy.js:2065)
at RenderMarkerSelection (room_markers.js:175)
at SelectMarker (room_markers.js:30)
at ResetMarkerList (room_markers.js:142)
at RoomMarkerTool.SetRoom (room_markers.js:109)
at resetGameData (core.js:521)
at newGameDialog (core.js:486)
at HTMLButtonElement.onclick (index.html:167)

The same thing happens when I subsequently start a new game. If I refresh the browser, and then either loading from an .html file or starting a new game works fine.

No `package.json`

hey adam! i noticed that 3ec59e3 removed the package.json which was being used for some electron stuff. would it be possible to add one back in which has just the basic metadata? e.g.:

{
  "name": "bitsy",
  "version": "6.1.0",
  "description": "make tiny games, worlds, and stories",
  "author": "Adam Le Doux"
}

idk if there's any intent to publish bitsy as a module, but the presence of a package.json with the bare minimum allows it to be used more easily with other tooling (e.g. you can use the npm CLI to install a github repository directly, but it still looks for the package.json)

there is also a license field, which would be an opportunity to address #5 if one is decided

Rooms without a defined palette break

pretty minor issue but may be confusing for folks who run into it: if you have a room defined in gamedata without a PAL entry, or a PAL defined that doesn't actually exist, bitsy will throw errors and fail to render (in both the editor and the exported game).

i noticed it while porting some old gamedata to a newer version of bitsy (guessing palette was optional in earlier versions?), but it can also happen if you're editing gamedata directly (which is currently the only way to delete palettes). it would probably be best to automatically assign the first palette to them in this case to avoid the error.

Touch controls on iOS are still broken

Swiping up or down will still scroll scroll the parent page before activating any Bitsy controls.
I do not have an Android device handy to test, but can confirm this is broken on iOS Chrome and Safari.

This is (AFAIK) because these browsers do not allow you to prevent the default touch event on the body element.

Borky's solution to this problem is to create a div in JS, inline-styled to be entire viewport and above the game canvas, and attach the eventListener to that. I'm sure there are other solutions too, ofc.

Link to video of current mobile behavior: Note the scrolling in the background and the 'popping' related to the top-bar.

https://www.dropbox.com/s/n0pwoyyti73wdpo/touch_controls.MP4?dl=0

Only game data is downloaded, rather than full game

When running Bitsy locally, the download game option exports only the game data that usually lives in the <script> section, rather than the fully functional HTML file required to actually run the game, as exported by the web version.

It's not clear whether this is a bug or a feature, however, or if there's a workaround or alternate setting that I've missed.

The data works perfectly when pasted into a game file created by the version on itch.io.

I'm running it in Chrome 65.0.3325.162 (Official Build) (64-bit) for Linux.

License

Hey, I noticed there's no license... =P

visual editing of greater than or equal to and less than or equal to broken in conditions in version 6

In addition to issue #14, visual editing of greater than or equal to and less than or equal seems to be broken in conditions.

If you create a condition such as "when variable a>=1", as soon as you edit a different sprite and come back to the previous sprite, the condition is changed to "when custom=1". See attached screenshot.

I believe what is happening is when ">=" is chosen, the dialog editor creates the code > =" rather than ">=", which later gets parsed back to a custom expression. For the above example, this is the log in the javascript console:

SERIALIZE ADVANCED DIALOG
editor.js:3555 SERIALIZE DIALOG SPR_0
script.js:1474 CREATE EXPRESSION --- a >= 1
script.js:1474 CREATE EXPRESSION --- a
script.js:1474 CREATE EXPRESSION --- = 1
script.js:1474 CREATE EXPRESSION --- 1
editor.js:3552 SERIALIZE ADVANCED DIALOG
editor.js:3555 SERIALIZE DIALOG SPR_0

and the code window shows:

I'm a cat{

  • a > = 1 ?
    hello
  • else ?
    goodbye
    }

When the code is parsed and the dialog editor repopulated upon changing sprites, the "> =" is not parsed as ">=", and the condition is shown as "custom".

XPsANP

a56Dy+

All black room/paint windows and no data after importing saved HTML file

Occasionally, Bitsy seems to be saving HTML files that run fine in the browser, but bug out the editor when imported back in.

Upon importing one of these files, the room window and paint windows show all black, and the game-data shows entirely blank. However, if you open up the html file, and copy the game-

data into the editor, the game is restored without any apparent issues. Saving the game after pasting in the game-data this way then creates a file with double closing script tag after the font-data script, however this new file still cannot be imported back into the editor.

Attached is an example of a bugged game file:
broken.html.zip

Editor changing tile ids when exporting game or copy/pasting game data

Sometimes the editor will add an extra letter to a tile within a room (typically a duplicate letter/number). The changed tile is usually one from the right side of the room.

Has happened both when exporting and when pasting game data into an html file. I've only tested it on chrome, so I'm not sure if it's an issue specific to that browser or not.

bitsy bug

Paint vs. Select modes for Map

In the map section, there could be a toggle to switch between two modes:

  • "paint" mode -- the current behavior where clicking a square places a thing (sprite/item/tile)
    • Would be helpful to show which thing is currently selected / going to be placed
  • "select" mode -- where clicking a square would select the thing, same as selecting it from find drawing
    • While in select mode, hovering over a thing could give its type and name. This could help solve #45.

Exits panel doesn't refresh when switching rooms

When I click "next room" or "previous room" in the rooms panel, and the exits & endings panel is open, that panel doesn't update and still shows an exit from the previously open room. It seems to update properly when I then click "next" and "previous" in it though.

This was confusing to me because I hadn't learned that the exits & endings panel only showed exits and endings of that room instead of throughout the game. Related suggestion about that: it might be nice to put a line of text in the exits & endings panel like "2 exits/endings involving this room" to make that clear and avoid the confusion I had of "where did my exits go? why are they only showing up sometimes?"

Thanks for making Bitsy! I'm really enjoying making a game for the soup bitsy jam! :)

>= operator is broken in 6.0

The Greater-than-or-equals operator is returning true in all cases. Of the logic operators in the editor, only '>=' appears affected.

Screen Shot 2019-04-17 at 9 40 16 AM

Errors thrown on every frame of touch input

when using touch controls in chrome, an error is thrown every frame on which there is touch input:
[Intervention] Unable to preventDefault inside passive event listener due to target being treated as passive. See https://www.chromestatus.com/features/5093566007214080. it doesn't seem to have any user-facing consequences since bitsy games are responsive and there's nothing to scroll, but it is pretty spammy.

you can fix it by adding touch-action: none; to the #game css, which tells it to ignore mobile gestures on the canvas (none of which bitsy uses afaik)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.