The Daily Click ::. Forums ::. Klik Coding Help ::. What is a string ? What does it do? How do I use it?
 

Post Reply  Post Oekaki 
 

Posted By Message

shoz bucket



Registered
  30/05/2003
Points
  22
9th June, 2003 at 04:51:07 -

What is a string ? What does it do? How do I use it? What does this mysterious string thing do?

 
n/a

Assault Andy

Administrator
I make other people create vaporware

Registered
  29/07/2002
Points
  5686

Game of the Week WinnerVIP Member360 OwnerGOTM JUNE - 2009 - WINNER!GOTM FEB - 2010 - WINNER!	I donated an open source project
9th June, 2003 at 05:18:52 -

String Computer Science - A set of consecutive characters.

A string is just a string of characters. In other words (lol words) text. So what i am typing now could be defined as a string of characters or more simply a string. You can change a string's alterable string, so that what it says changes.

i.e

Start of frame - String.Alterable string = "hello"

Then the string will change to say "hello". They can be simply used to communicate with the user of your program, or for more complex programming in which you need to store data for later use and such.

Chee that was a corny, joke (in other words)

-Andy


 
Creator of Faerie Solitaire:
http://www.create-games.com/download.asp?id=7792
Also creator of ZDay20 and Dungeon Dash.
http://www.Jigxor.com
http://twitter.com/JigxorAndy

Assault Andy

Administrator
I make other people create vaporware

Registered
  29/07/2002
Points
  5686

Game of the Week WinnerVIP Member360 OwnerGOTM JUNE - 2009 - WINNER!GOTM FEB - 2010 - WINNER!	I donated an open source project
9th June, 2003 at 05:20:10 -

I typed really posh then, that sounded gay.

 
Creator of Faerie Solitaire:
http://www.create-games.com/download.asp?id=7792
Also creator of ZDay20 and Dungeon Dash.
http://www.Jigxor.com
http://twitter.com/JigxorAndy

ShadowCaster

Possibly Insane

Registered
  02/01/2002
Points
  2203
9th June, 2003 at 06:23:38 -

Yep, a string is just a list of characters placed one after the other. But, to throw a spanner in the works, the following are also strings:

  f
  123

Depending on the context in which they are created.

I just thought I'd try and confuse you a bit

Mike

 
"Now I guess we're... 'Path-E-Tech Management'" -Dilbert

Jenswa

Possibly Insane

Registered
  26/08/2002
Points
  2722
9th June, 2003 at 06:33:30 -

Hmm I always thought that girls wear such a thing uh string.

 
Image jenswa.neocities.org

DeadmanDines

Best Article Writer

Registered
  27/04/2006
Points
  4758
9th June, 2003 at 07:11:21 -

It makes more sense when you think about how computers first 'evolved', and how they work.

Your computer has pretty much just one basic way of storing data: Bytes (there are variations on this, but that's pretty much it). A byte can hold a number between 0 and 255 (usually), but people wanted to use *text* on computers, not just numbers. Various methods were developed, but the one that is most widely used today is ASCII, or 'American Standard Code for Information Interchange'.

The way it worked was that every character in the alphabet (as well as a few commands, such as delete, carriage return, line feed, tab, and so on) was given a number (between 0 and 255 - see the connection?). That value was then assigned to a standard byte, and voila! You get what we now know as 'Plain Text', or Notepad's good ol' .txt file.

All text is, you see, is a 'string' of bytes one after the other. The expression makes perfect sense when you think of it this way (or at least I hope it does).

There are plenty of old-fashioned words still used in computers today. Another example is 'print', from way back in the days before computers had monitors, and data was litterally printed out onto paper rather than appearing on a screen.
----

However, I'm guessing you want to know what the 'String Object' is, not just what the term 'String' means. As you can guess from the name, it is a text thing. Its sole purpose is to be able to display text. You can give it multiple paragraphs, and switch between paragraphs in-game.

You can also use its 'alterable string', which can be changed at any time during the game. The string object can use fonts and text colour, but it is only plain text, so you can't make some words bold and others not.

It's often used for the speech in games. Any text that you don't want the user to edit manually can be done using this.

 
191 / 9999 * 7 + 191 * 7

Shen

Possibly Insane

Registered
  14/05/2002
Points
  3497
9th June, 2003 at 07:26:56 -

A string is a word array

 
gone fishin'

shoz bucket



Registered
  30/05/2003
Points
  22
10th June, 2003 at 00:14:35 -

so is a string basically a piece of text that can be editied from the event editor? so could I use this in an rpg type game with lots of text? or should I use the normal text object??

 
n/a

Assault Andy

Administrator
I make other people create vaporware

Registered
  29/07/2002
Points
  5686

Game of the Week WinnerVIP Member360 OwnerGOTM JUNE - 2009 - WINNER!GOTM FEB - 2010 - WINNER!	I donated an open source project
10th June, 2003 at 01:13:40 -

Yep that's basically it. You can use it in an rpg to do that. But for rpgs it's best when combined with an ini or something. Check my example under muz's question, about conversation editors.

 
Creator of Faerie Solitaire:
http://www.create-games.com/download.asp?id=7792
Also creator of ZDay20 and Dungeon Dash.
http://www.Jigxor.com
http://twitter.com/JigxorAndy
   

Post Reply



 



Advertisement

Worth A Click