This forum is in archive mode. You will not be able to post new content.

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - shroudedaether

Pages: [1]
1
Scripting Languages / Re: Quick list trick [Windows].
« on: July 18, 2011, 07:53:39 AM »
Sure most of you know this already, but...

Mapping a virtual drive to a directory:
In the command prompt, you can map a directory to an unused drive letter (T: for instance) with
Code: [Select]
subst <drive> <path>
Example: subst t: c:\Users\Admin\Desktop
In the command prompt or in explorer(My Computer, specifically), you will be able to access the drive(T in the example) and it will redirect you to the path you set. Useful for shortening paths and... use your imagination here. Mine's drawing a blank. (In Win7 and probably Vista, this will not work in My Computer if you ran CMD as an administrator.) You can reverse this with:
Code: [Select]
subst /D <drive>
Backups:
Instead of using some third party backup software, you can use a built in command in your command prompt, robocopy, to back up your files.
Code: [Select]
robocopy <source> <destination> /copyall /r:0 /dcopy:t /mir
Example: robocopy C:\Users\Desktop\LuaVoice F:\Backup\LuaVoice /copyall /r:0 /dcopy:t /mir
This will copy everything, subdirectories included, to the destination from the source (with 0 retries, preserving file information and timestamps.) This only works for Windows Vista and Windows 7. For XP and older, you can do this similarly with XCOPY
Code: [Select]
xcopy C:\Users\Desktop\LuaVoice F:\Backup\LuaVoice /c /d /e /h /i /k /q /r /s /x /y
"Godmode" (Win7 only[maybe]):
In Windows Explorer(even on your desktop), right click, go to new > folder. Insert the following as the folder name:
Code: [Select]
GOD Mode.{ED7BA470-8E54-465E-825C-99712043E01C}This should give you a directory of administrative tools and options. (Credits to whoever I stole this from... don't remember where.)

2
C - C++ / Re: terminology help? WTF does this mean?
« on: July 18, 2011, 06:34:53 AM »
int is a datatype for a variable. In this case, integer.

endl inserts a newline character(\n), and in buffered streams, flushes the buffer. The ; at the end ends the line.

cout is an object of the ostream class which prints text/data out to the terminal/command prompt.

cin takes input from the user via the terminal/command prompt.

std refers to the standard library. Usually, things like cout would have this prefaced (std::cout), but if using namespace std; is included, you can leave out the std:: and just use cout to echo.

>> is the extraction operator. It performs an input operation on a stream.

<< is an insertion operator. Does the opposite of >>. I'm sure you can figure it out.

<iostream> is used after an #include to include the file "iostream" from the compiler's include directory (<> specify the compiler include dir.) Iostream provides input and output functionality using streams.

DoPrint() is used to call the function DoPrint, which I assume is somewhere in your code.


As well, I'm going to take this time to link you to a few websites that may help you learn this, and a few books as well.

Websites:
learncpp.com
Not overly familiar with the website myself, but saw a good review on it and skimmed over it. Seems decent.

http://cplusplus.com/
Not a bad website. Has a decent reference. A bitch to navigate IMO, however.

(Note on the websites: A lot of these websites don't exactly teach the best practices. While excellent for learning at the beginning, they won't teach you everything, and take everything you read with a grain of salt.)

Books:
C++ Primer
Great for beginners. I'd honestly recommend it.
http://www.demonoid.me/files/details/2231948/63090872/
http://www.amazon.com/Primer-Plus-4th-Stephen-Prata/dp/0672322234

Pages: [1]


Want to be here? Contact Ande, Factionwars or Kulverstukas on the forum or at IRC.