Jump to content

double quote in strings


Recommended Posts

Posted

Hello,

 

Maybe some of the papyrus scripters knows that out of the box. Searching with google was not helpful.

I want to build a command string for the console and want to store that in a string.

 

As an example the command string for the console should look like this:

Getini "fOverShoulderPosZ:Camera"

 

This string can be executed in the console, while :

Getini fOverShoulderPosZ:Camera

leads to an error.

 

so the definition in papyrus starts like:

string sCmd = "Getini

but how to put the doublequote itself now into the papyrus string ??

 

Regards

 

 

Posted

Dunno if it works with Papyrus, anywhere else you'd escape the quotes with a backslash.

In your case I'd try

string sCmd ="Getini \"fOverShoulderPosZ:Camera\""

 

(Maybe you need to escape the colon too.)

Posted (edited)

Ok,

 

Thank you very much. It is possible to compile the script and the result is exactly how it should be :)

 

I  was more familar with Delphi, where string handling is different. But my question can be considered as solved now.

Now some other problems ae waiting for me regarding the Fallout 4 Consoleutil.dll, where this command and some others are needed.

Edited by Kanlaon

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...