|
Post by Guilect on Dec 28, 2006 18:15:05 GMT -5
just wanted to show people that with the next release of Brutus2D you can write console programs. This demo only uses a few of the 20 or so available console commands. The demo is self running and lasts about 2 minutes. It is a port of someone elses code. Download and unzip to its own directory. (~ 250k) brutus.pewtersoftware.com/upload/files/god.zip
|
|
|
Post by matthew on Dec 28, 2006 18:57:55 GMT -5
^^ Nice. ;D
In the past I've written a few command-line programmes in Dev-C++.
In the future I'll be able to write them in Brutus2D. ;D
|
|
|
Post by hartnell on Dec 28, 2006 23:50:16 GMT -5
As soon as I wake up, this makes front page news on my site. LOL - hartnell
|
|
|
Post by hartnell on Dec 29, 2006 9:45:49 GMT -5
Is there any chance that we can get a preview of the new method names? -hartnell
|
|
|
Post by Guilect on Dec 29, 2006 19:08:45 GMT -5
'PROPERTY Caption 'Gets or sets the caption of the console Window GetTitle()
setTitle (newCaption)
'PROPERTY CursorX 'Gets or sets the current x position of the cursor GetCursorX()
SetCursorX (NewX)
'PROPERTY CursorY 'Gets or sets the current y position of the cursor GetCursorY()
SetCursorY (NewY)
'PROPERTY OvrMode 'Gets or sets overwrite mode 'In overwrite mode, the cursor size will be 50% of the character space 'instead of 25% in normal mode GetOvrMode()
SetOvrMode (NewMode)
'PROPERTY CursorVisible 'Gets or sets the visibility of the cursor GetCursorVisible()
SetCursorVisible (NewVisible)
'PROPERTY EchoInput 'Gets or sets whether input should be shown or not GetEchoInput()
SetEchoInput (NewEcho)
'PROPERTY BackColor 'Sets the text backcolor SetBackColor (NewColor) 'BACKGROUNDCOLOR
'PROPERTY ForeColor 'Sets the text forecolor SetForeColor (NewColor) 'FOREGROUNDCOLOR
'PROPERTY hWnd 'Returns the handle of the console window GethWnd()
'METHOD WriteLine 'Write a line of text to the console WriteLine (sWhat)
'METHOD WriteString 'Writes a string to the console WriteString (sWhat)
'METHOD WriteTo 'Writes a string to the console at a specific location WriteTo (sWhat, X , Y )
'METHOD WriteCenter 'Writes a string in the horizontal center of the console WriteCenter (sWhat)
'METHOD WriteRight 'Writes a string on the right of the console WriteRight (sWhat)
'METHOD ReadLine 'Asks the user for a line of input ReadLine()
'METHOD MoveCursor 'Moves the cursor to a specific location MoveCursor(X , Y )
'PROPERTY WindowWidth 'Retrieves the width of the window GetWindowWidth()
'PROPERTY WindowHeight 'Retrieves the height of the window GetWindowHeight()
'METHOD Clear 'Clears the console Clear()
Initialize()
Resize(NewWidth, NewHeight)
Terminate()
|
|
|
Post by hartnell on Jan 2, 2007 0:29:37 GMT -5
How long before we get to use it? -hartnell
|
|
|
Post by Guilect on Jan 2, 2007 20:24:31 GMT -5
Available right now. See official announcements.
|
|
|
Post by matthew on Jan 2, 2007 21:32:42 GMT -5
Great, I'm just about to Download. ;D
|
|
|
Post by Guilect on Jan 2, 2007 21:53:09 GMT -5
Realized that the code for the console demo was not included in the release of V1.6 so it is attached here.
|
|
|
Post by Guilect on Jan 2, 2007 21:55:07 GMT -5
sample code for using the console object.
(also found in the New->temp_console template directory.
|
|
|
Post by OddChild on Jan 10, 2007 15:37:59 GMT -5
lol made a consol program, to convince my friend that he was hacking... lol it deleted his college account (not really just simulated it)...
VERY funny
|
|
|
Post by Guilect on Jan 10, 2007 16:37:13 GMT -5
^^ looks like you got your PC back up and running.
Ya, console programs can look like some low level system program that is running. I wish I could have seen the look on your college friends face.
|
|