Welcome aboard Visitor...

Daily Screenshot

Server Costs Target

Time running out!

94% of target met.

Latest Topics

- I will no longer be hosting this server »
- Anyone still playing from a decade ago or longer? »
- Game still active. NICE! »
- help me »
- Password resett »
- Darkspace Idea/Opinion Submission Thread »
- Rank Bug maybe? »
- Next patch .... »
- Nobody will remember me...but. »
- 22 years...asking for help from one community to another »

Development Blog

- Roadmap »
- Hello strangers, it’s been a while... »
- State of DarkSpace Development »
- Potential planetary interdictor changes! »
- The Silent Cartographer »

Combat Kills

Combat kills in last 24 hours:
No kills today... yet.

Upcoming Events

- Weekly DarkSpace
11/02/24 +1.9 Days

Search

Anniversaries

23th - Starfleet.
8th - Cyber999

Social Media

Why not join us on Discord for a chat, or follow us on Twitter or Facebook for more information and fan updates?

Network

DarkSpace
DarkSpace - Beta
Palestar

[FAQ
Forum Index » » Basic Scripting Discussion » » /n?
 Author /n?
Barthezzz
Fleet Admiral

Joined: May 31, 2001
Posts: 5630
From: The Netherlands
Posted: 2003-02-09 04:36   
Yeah a q about scripting, In the Pushchat function in the tutorial you see /n every now and then.

Some lines of text have it at the start and end some dont have it at all and some have it either at the front or end. (See axamples below)

What does it do? (Cant find it in the scripting ref)


Quote:
pushChat( "Press the ENTER key to begin the tutorial.n" );



Quote:
pushChat( "nPress the ENTER key to continue.n" );



Quote:
pushChat( "nFor this training we will give you this free ECCM (Please do give it back afterwards =P)" );


_________________


  Goto the website of Barthezzz
chris aka sunshine
Cadet

Joined: May 29, 2001
Posts: 1649
From: Germany
Posted: 2003-02-09 04:39   
n will result in an line-break..


pushChat( "Press the ENTER n key to continue.n" );


looks like:

Press the ENTER
key to continue


_________________
Christian 'sunshine' Weyand





  Email chris aka sunshine   Goto the website of chris aka sunshine
Barthezzz
Fleet Admiral

Joined: May 31, 2001
Posts: 5630
From: The Netherlands
Posted: 2003-02-09 04:40   
Ah tnx

But if i have this:
Quote:
pushChat( "To counter the K'luth cloak you 0 need ECCM. ECCM can be bought at a starport and placed in a Special slot on your ship." );
pushChat( "nECCM raises the signature of all ships nearby. K'luth need a signature of 0 if they want to be able to fly around unseen." );
pushChat( "nFor this training we will give you this free ECCM (Please do give it back afterwards =P)" );



The pushchat things are all in diffrent lines, do they still need the /n?

_________________

Website || Fleetpage

[ This Message was edited by: Barthezzz on 2003-02-09 04:41 ]
_________________


  Goto the website of Barthezzz
Shigernafy
Admiral

Joined: May 29, 2001
Posts: 5726
From: The Land of Taxation without Representation
Posted: 2003-02-09 06:55   
I think different pushchat automatically has a line break after it. So if you have multiple pushChat()s, it would have line breaks between them.. its just an option between whether you want to have have one long pushChat(something /n something /n something) or multiples to make it a bit more readable.

So basically, assume an invisible /n at the end of the pushChat().
_________________
* [S.W]AdmBito @55321 Sent \"I dunno; the French had a few missteps. But they're on the right track, one headbutt at a time.\"

  Email Shigernafy
Barthezzz
Fleet Admiral

Joined: May 31, 2001
Posts: 5630
From: The Netherlands
Posted: 2003-02-09 07:28   
cool.
_________________


  Goto the website of Barthezzz
Chromix
Cadet

Joined: June 29, 2001
Posts: 3052
Posted: 2003-02-09 08:43   
Another difference is: Lines by pushChat() are logical blocks, so when you write a single block with 30 lines it disappears from the screen quite fast, but if you use pushChat for every single line they'll disappear one by one.
_________________


  Email Chromix
Page created in 0.009371 seconds.


Copyright © 2000 - 2024 Palestar Inc. All rights reserved worldwide.
Terms of use - DarkSpace is a Registered Trademark of PALESTAR