I need an example

Discussion forum for all Windows batch related topics.

Moderator: DosItHelp

Post Reply
Posts: 1
Joined: 18 Oct 2019 08:49

I need an example

#1 Post by Bubeboi » 18 Oct 2019 08:53

So, I am trying to achieve a little open world RPG game in batch. I need an example where i can control the guy with the arrow keys and can change how the character looks. Thanks! (Also I am brand new so please tell me if this has already been asked)

Posts: 16
Joined: 15 Sep 2019 05:33

Re: I need an example

#2 Post by Maylow » 20 Oct 2019 07:10

Not sure what you want or how you want it exactly. More specifications of your goal might help.
What do you mean with 'the guy'? Is this a set of characters which together look like a guy, like in ASCII art?
How do you see 'control'? As in 'move' the set of characters?
There are many ways to achieve what you want.

For example, cursor positioning can be done with PROMPT and ANSI escape sequences:

Code: Select all

prompt $E[3A
This will jump the cursor 3 positions up. You could then output the set of characters resembling the guy for instance.
See https://docs.microsoft.com/en-us/window ... -sequences for a list of ANSI escape sequences.

I am no pro in batch code language, I might give you wrong or inefficient answers.
Others on this forum might provide better solutions.

Anyway, I think there are indeed some threads about this on this forum :)
The SNAKE script might have the solution you are looking for:
For instance viewtopic.php?f=3&t=4741&hilit=snake

I hope this helps.

Posts: 5
Joined: 26 Nov 2019 10:02

Re: I need an example

#3 Post by Yellow_13 » 27 Nov 2019 10:39

Thanks, I'm not the OP, but it helps. I was working on a small DOS based game as well, and these resources really put me on the right track!

Post Reply