Home   Help Search Login Register  

Author Topic: OFP String Parser  (Read 4621 times)

0 Members and 1 Guest are viewing this topic.

Bluelikeu

  • Guest
OFP String Parser
« on: 12 Jun 2005, 22:51:01 »
Hello everyone,

I've created a JAVA program that allows you to convert any given string into a "parsed" string.

For Example,
Hello, I am a string!

is then converted into:

["H","e","l","l","o",","," ","I"," ","a","m"," ","a"," ","s","t","r","i","n","g","!"]

The conversion turns the given string into an array of strings where each character is turned into a separate string. This program was designed to allow easier use of the TypeWriter script I made. It also has infinite other uses depending on how insane you are.

Enjoy.
Bluelikeu

PS: It's not a .jar file, and it's got its own executable, so no problems should occur. Just double click on the "OFP String Parser" in the main folder, and it should load up fine.
« Last Edit: 12 Jun 2005, 22:51:36 by Bluelikeu »

Offline RujiK

  • Members
  • *
  • KoKo Puh-Fizzles!
Re:OFP String Parser
« Reply #1 on: 13 Jun 2005, 03:58:39 »
A little late. I already have one of these however forgot where I got it. However I remember it was made by Colonel Clink.
I like your approach, lets see your departure.
Download the New Flashlight Script!

Offline Blanco

  • Former Staff
  • ****
Re:OFP String Parser
« Reply #2 on: 13 Jun 2005, 09:56:49 »
« Last Edit: 13 Jun 2005, 10:21:17 by Blanco »
Search or search or search before you ask.

Bluelikeu

  • Guest
Re:OFP String Parser
« Reply #3 on: 13 Jun 2005, 12:10:04 »
Darn it. Anyway, for those who don't like the other tool, you can use this one.

Is there anything else that people want to be automated for them?

Thanks,
Bluelikeu

BTW, this program allows the enter key to be used unlike the one mentioned.
+ less space than other program mine's about 16kb unpacked and about 3.5kb packed
« Last Edit: 13 Jun 2005, 12:14:23 by Bluelikeu »

Offline Blanco

  • Former Staff
  • ****
Re:OFP String Parser
« Reply #4 on: 13 Jun 2005, 14:03:21 »
A description.ext merger would be nice  :)
Search or search or search before you ask.

Bluelikeu

  • Guest
Re:OFP String Parser
« Reply #5 on: 13 Jun 2005, 15:39:42 »
Merger meaning combining two description.ext or merger as in description.ext wizard?

Offline Blanco

  • Former Staff
  • ****
Re:OFP String Parser
« Reply #6 on: 13 Jun 2005, 17:31:06 »
I mean merging two description.ext files into one.
« Last Edit: 13 Jun 2005, 17:32:19 by Blanco »
Search or search or search before you ask.

Offline RujiK

  • Members
  • *
  • KoKo Puh-Fizzles!
Re:OFP String Parser
« Reply #7 on: 13 Jun 2005, 18:21:17 »
I doubt this is possible however a .sqf to .sqs converter or vise versa.

I doubt this can be done though.
I like your approach, lets see your departure.
Download the New Flashlight Script!

Bluelikeu

  • Guest
Re:OFP String Parser
« Reply #8 on: 13 Jun 2005, 22:28:38 »
@Blanco

I'm not sure why you would want to merge two description.ext. How would you expect them to be merged?

@Rujik
Accually, it should be quite easy. However, making a .sqs into a function is not so easy. Certain commands cannot really be used in the function. Also, functions are quite easy to understand since they are basically the same thing other than variable declarations and a few other small details so i'm not sure as to how much effort it would take from someone. I suppose its use could be if you've got variables being created all over the place, and you need them to be organized so that they can be easily converted to what the function requires. Now there's an idea. Organization of variables.

Offline penguinman

  • Contributing Member
  • **
  • Money is worthless, just paper, ink, and threads
Re:OFP String Parser
« Reply #9 on: 16 Jun 2005, 06:59:14 »
i would like to see a program where when you make any changes to a mission and then save it, it will keep a copy of the privious version, incase you do somthing bad,

i spent a couple months on a mission once and the hit the clear button by mistake, the "are you sure message"  i dint recognise what it was at the time because i dint pay any attention to it so i clicked yes, then i saved all my work and went to give it one last lookover, i got a horible suprise.

a tool like that would be nice

Bluelikeu

  • Guest
Re:OFP String Parser
« Reply #10 on: 16 Jun 2005, 09:32:25 »
Thats possible. It would back-up the folder you are accessing every couple of minutes, or the entire missions folder, but that might be a bit much. Or If you wanted something like a redo button. I could move the mouse all-over your screen and repeat the clicks for you. I'm not sure if the program will be able to retrieve the data though, since OFP has the focus of the computer.

Offline General Barron

  • Former Staff
  • ****
  • Semper Fi!
Re:OFP String Parser
« Reply #11 on: 28 Jun 2005, 03:17:06 »
Looks good. I'll keep it around for when I need to make strings like this again. :)

Problem with Klink's utility is that it doesn't put it into OFP array format: it has no brackets, and spaces get translated into line breaks, meaning you have to manually edit the output. This program, though uglier :P, works better :).

BTW, a tidy way to package java files into a single windows executable is with "Executor":

http://mpowers.net/executor/

The free version will leave a DOS window open in the background, but if you shell out the $30 for the full version, there is no such window. Still, even the free version is neater than having a .jar / .bat file.


As for tool suggestions... I'll have to think about it. :)

« Last Edit: 28 Jun 2005, 03:34:48 by General Barron »
HANDSIGNALS COMMAND SYSTEM-- A realistic squad-control modification for OFP
kexp.org-- The best radio station in the world, right here at home! Listen to John Richards!

Bluelikeu

  • Guest
Re:OFP String Parser
« Reply #12 on: 28 Jun 2005, 13:28:29 »
Funny you mention such a program because I just recently, like 3 days ago downloaded a program similar to that. Its JexePack, I think that it was a bit more expensive, about $99.95, but it should be worth the money, has numerous other options too.

Offline haroon1992

  • Members
  • *
  • My life is hopeless...
Re: OFP String Parser
« Reply #13 on: 12 Aug 2010, 17:31:37 »
Sorry for digging up old thread.
Where can i download this tool?
If impossible,  where can i download similar tool?
Or script doing this for OFP?

Reminder
What's this utility do ?
Split a string in to a 1-character strings.
Input - "HELLO"
Output - ["H" "E" "L" "L" "O"]

Regards,
Haroon1992
Very busy with life, business, and other stuff. Away from OFP for months. Not sure if I could get back onto it. :(

Offline RKurtzDmitriyev

  • Former Staff
  • ****
Re: OFP String Parser
« Reply #14 on: 12 Aug 2010, 20:34:00 »
No idea where you could find a similar program. But in response to

Or script doing this for OFP?

Pretty sure OFP has no way to disassemble strings, so it would be difficult or impossible for OFP to do this by itself.
The OFP Editing Center wishes to remind you that the faithful COMREF will never threaten to stab you and, in fact, cannot speak.
However, in the event that it does speak, you are encouraged to heed its advice. ;)