Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Wordward Draw (managore.itch.io)
50 points by lardass on July 29, 2023 | hide | past | favorite | 18 comments


Late to the party, here is some code to solve the path between each word, just requires numpy and a txt file of 4 letter words "words.txt" separated by lines

    import numpy as np
    with open("words.txt") as f:
        words = f.read().splitlines()
        f.seek(0)
        chars = np.array(list(ord(c) for c in f.read() if c != '\n')).reshape((-1, 4))

    word_to_index = dict(zip(words, range(len(words))))

    char_flip = np.sum(chars[:, None, :] != chars[None, :, :], axis=2) == 1
    chars_sorted = np.sort(chars, axis=1)
    char_shuffle = np.all(chars_sorted[:, None, :] == chars_sorted[None, :, :], axis=2)

    adj = char_flip | char_shuffle
    np.fill_diagonal(adj, False)
    # import itertools

    def path_recursive(current, end, adj, path, depth):
        if depth <= 0:
            return []
        if current == end:
            return [[*path, end]]
        
        # all_paths = []
        for neighbor in adj[current]:
            if neighbor in path:
                continue
            _path = path_recursive(neighbor, end, adj, [*path, current], depth - 1)
            # all_paths.append(_path)
            if _path:
                return _path

        
        # return list(itertools.chain(*all_paths))
        return []

    def binary_shortest_dist(start, end, adj):
        depth = 1
        adj_n = np.eye(adj.shape[0])
        while depth < 20:
            depth += 1
            adj_n = adj_n @ adj
            if adj_n[start, end]:
                return depth


    def path(start, end, adj):
        start = word_to_index[start.upper()]
        end = word_to_index[end.upper()]
        depth = binary_shortest_dist(start, end, adj)

        print(depth)

        adj = [[i for i in np.nonzero(_adj)[0]] for _adj in adj]

        paths = path_recursive(start, end, adj, [], depth)
        return [[words[i] for i in path] for path in paths]

    path("disc", "zero", adj)


What am I missing? I type "worm", and then that's it. There's nowhere to type, nothing to do with the mouse, etc.


The next word it is directing you to is "word". Type that, then hit return.


ahh, thanks. not to spoil anyone's fun, but i grabbed the word list from source if someone wants to cheat like me. https://pastebin.com/A4yTMvWE


Excellent game. I haven't finished it yet (though I got what I'm pretty sure is the hardest picture word) but the key strategy seems to be to pick a (hard) target word, sketch out some chains from there to some easier ones and then try to reach one of those.

Minor suggestions: better contrast in the tab screen for not-yet-founds, have all instructions in the supporting text (i.e. Tab and backspace too). Maybe allow hyperspacing to any word you've previously got to, although that's maybe a bit radical.

Personally I find the dance-ey style of graphics a bit tiring to look at, but that's just me.

EDIT: I'm finding that I tend to fixate too much on single-char replacements and not enough on anagrams. Curious whether that's just me.


4-letter word list helped me a lot to build paths to goal words. Also, I collected all words from code, so I can chase nearest goal.

PS.

Game works better in Firefox.


Clever and funny game. As a non-native speaker, it took me two hours to finish the game. The last word was a bit difficult to find!

It would be great to highlight the unfound and revealed words on the tab screen. It is hard to find and eye tiring. Background colors are sometimes too flashy and there is some contrast issue between the text and the background color.

It would be great to have the picture in along with the text in the tab screen.

Sometimes I am a bit frustrated when a word is revealed, and I know I was at one letter of this earlier in the game. I am not sure how this frustration could be reduced.


Words that are words, backwards, are a favorite "go to sleep" puzzle for me. My boss will also participate.

deer; drab; tun; part; trap; gab; gut; etc.

Obviously, you could just write a script, but it's more fun to dream them up!


Reminds me of an interview with the composer Elliott Carter, where he said that to fall asleep, he would conjugate Greek verbs in their various moods and tenses. It actually works, and in very short time.


For anyone looking at it on mobile, you can play in the browser on desktop.


For anyone looking at it on desktop and wondering how to play it: make the browser window wider.

Window width as a determining characteristic of a mobile? Come on.


It’s how most of “responsive design using CSS” tutorial teaches you.


Normally I would agree, but for some reason, the width threshold for going from desktop -> mobile is really wide (1280px) which could genuinely be larger than some laptop screens depending on zoom or scaling.


Looking forward to playing this!

My brother and I were brainstorming ideas for a new wordle-like game recently and we hit upon this same idea. We looked it up and learned that Lewis Carroll "invented" this game back in the 1800s. He called it "Word Ladders."


Woof. Solved them all. Some of them felt damn tricky to get to, but I got there.


This is really well done. Great concept and execution. I love the Baba Is You style.

Only issue for me is that the instructions did not pop up fast enough.


I gotta say, the sound effects are very satisfying.


Could not compile vertex shader: null :(




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: