Sign up Calendar Latest Topics
 
 
 


Reply
  Author   Comment  
Shadowrgamer

Registered:
Posts: 12
Reply with quote  #1 
Newish to scripting, but I do not know XML, been using the mission editor.  Is there a way to add a line break to a text field, like a pop up message or a scan descriptor? 

Thanks for your help!
Shadowrgamer
Xavier Wise

Registered:
Posts: 1,058
Reply with quote  #2 
Off the top of my head, I think you use the ^ symbol for a new line. Try it and see if it works.
__________________
Fleet Captain Xavier Wise - TSN Sabre
Link to TSN RP Community website
Darrin

Registered:
Posts: 86
Reply with quote  #3 
Quote:
Originally Posted by Shadowrgamer
Newish to scripting, but I do not know XML, been using the mission editor.  Is there a way to add a line break to a text field, like a pop up message or a scan descriptor? 

Thanks for your help!
Shadowrgamer


If you're using the Mission Editor, then you can put in line breaks wherever you like with just the {Enter} key. The text fields inside the editor allow line feeds/return carriages. When the Mission Editor saves the mission as an XML file, it converts the line breaks into ^ characters. If you want to edit the XML file directly, then you can add more line breaks by adding more ^^^ characters. In the Comms screen right-hand panel, it will display a portion of the first line of a message with the ^ intact, although if you click on it to view it in the middle panel, the ^ will be displayed as line feeds. 

The same carat ^ character can be used in the scan descriptions. However, although you can set a scan descriptor on pretty much all named objects, it doesn't work with monsters/wrecks, as those have a a default scan description that overrides any other description. Also, I think the 2nd scan description only works on shielded ships, as that's the only type of object that you can scan twice.

I frequently like to hide clues, hints, and puzzle solutions on wrecks and monsters, but it's easier to do that with tags, which gives you two text fields to work with. 

Shadowrgamer

Registered:
Posts: 12
Reply with quote  #4 
Thanks for the quick replies,

In text messages to the comms station this works fine. Also in ship description fields this works. 

What I am trying to do is to have a pop up message display on the main screen so that I can give options to the captain that he can then relay to comms for them to use the appropriate button. 

When using the mission editor, when I press enter in that message box it closes the message box, if I use the ^ then it just puts that symbol in the message.  

I also opened the xml in notepad++ and tried to modify it that way and the ^ symbol just displays as is.  

Thanks again for the help. 
Shadowrgamer. 
Xavier Wise

Registered:
Posts: 1,058
Reply with quote  #5 
I think to have multiple lines in the pop up box, you would simply create multiple pop up messages in the correct order, rather than just a single message. Each new message would be another message transmitted, and would 'stack' on top of the previous message in the pop up window.
__________________
Fleet Captain Xavier Wise - TSN Sabre
Link to TSN RP Community website
Newcommerin

Avatar / Picture

Registered:
Posts: 160
Reply with quote  #6 
Quote:
Originally Posted by Xavier Wise
I think to have multiple lines in the pop up box, you would simply create multiple pop up messages in the correct order, rather than just a single message. Each new message would be another message transmitted, and would 'stack' on top of the previous message in the pop up window.


Yes that should do it. But in the mission editor you must have them in order from down to up - cause each new message will be displayed above the previous. 

__________________
Sorry, English is not my native language, I am German.
(* I wish I would live in America, I wish I would... *)
Any mistakes you can find, you can keep and with the spelling mistakes you can cook you an alphabet soup.

My Artemis Homepage: https://star-ship-academy.jimdo.com/
Xavier Wise

Registered:
Posts: 1,058
Reply with quote  #7 
Indeed. The newest message appears on top of the old message, pushing the old message further down. I believe there is an old sandbox created by Arrew that used multiple pop-up messages for giving specific information about key commands. It should be somewhere on this forum, though I don't think the script has been updated in a while.
__________________
Fleet Captain Xavier Wise - TSN Sabre
Link to TSN RP Community website
Darrin

Registered:
Posts: 86
Reply with quote  #8 
Be careful about putting more than one pop-up message in the same event, as I believe it will crash the server. One pop-up message per event.
Shadowrgamer

Registered:
Posts: 12
Reply with quote  #9 
Thanks for the help guys,  I will try playing around with this. 

Shadowrgamer
Newcommerin

Avatar / Picture

Registered:
Posts: 160
Reply with quote  #10 
Quote:
Originally Posted by Darrin
Be careful about putting more than one pop-up message in the same event, as I believe it will crash the server. One pop-up message per event.


Ah, that might explain my problem. My server does not crash, but regardless of what I do it shows the pop-ups on just one console.

__________________
Sorry, English is not my native language, I am German.
(* I wish I would live in America, I wish I would... *)
Any mistakes you can find, you can keep and with the spelling mistakes you can cook you an alphabet soup.

My Artemis Homepage: https://star-ship-academy.jimdo.com/
Darrin

Registered:
Posts: 86
Reply with quote  #11 
Quote:
Originally Posted by Newcommerin


Ah, that might explain my problem. My server does not crash, but regardless of what I do it shows the pop-ups on just one console.


Actually, I think that's a known bug... something to do with the networking code and how the server sends info to the clients, it's very inconsistent with how it determines which clients are which. I believe it's one of those things that Artemis 3.0 was supposed to fix.

 
Previous Topic | Next Topic
Print
Reply

Quick Navigation:

Easily create a Forum Website with Website Toolbox.