Author Topic: Script to copy your Battle Report to the Wiki easily  (Read 845 times)

Gabanus family

  • Board Moderator
  • Mighty Duke
  • *
  • Posts: 1322
    • View Profile
I've made a script a while back to make it very easy to put battle reports on the wiki to save them for all times. A few things to mention

1) It's in VBA, so you need to have microsoft word on your computer. If you don't, sorry.
2) I've described step by step how to use it, but if anything is unclear just hit me up here or on Discord:
https://discordapp.com/channels/386317706158276610/386317706695016462

The script to do it and step by step guide:
http://wiki.battlemaster.org/wiki/Battle_Reports#Code_to_paste_in_module:

*Updated version, the battle report now also autofills most of a military infobox to make it even cooler.
** Update 7-6-2018: Managed to finish the second part of the infobox, so it now shows it completely
« Last Edit: June 07, 2018, 02:06:23 PM by Gabanus family »
New account active chars:
Garas: First Oligarch - Goriad: Astrum - Goriad II: Obia'Syela

Medron Pryde

  • Noble Lord
  • ***
  • Posts: 240
    • View Profile
Very nice dude.

Wimpie

  • Developer
  • BM Dev Team
  • Mighty Duke
  • *
  • Posts: 1504
    • View Profile
I appreciate the work mate! Looks very nice and useful.

If not just for recording historical facts for your character/realm, you can also use this to save a battle report which you need for a bugreport. Battle reports will expire after a time, so uploading them to wiki using this and linking them on the bugreport will also help us as developers a lot.

Thanks again! Looking forward to the second part as well.
Jeames (Vix Tiramora, EC), Osgar (Thalmarkin, BT)
Nasgar (Avernus, DWI), Jari (Outer Tilog, COL)

Gabanus family

  • Board Moderator
  • Mighty Duke
  • *
  • Posts: 1322
    • View Profile
Your welcome and on your suggestion I finished the InfoBox first, so it now shows everything. Second script is also coming along, but not yet ready:

** Update 7-6-2018: Managed to finish the second part of the infobox, so it now shows it completely
New account active chars:
Garas: First Oligarch - Goriad: Astrum - Goriad II: Obia'Syela

Andrew

  • M&F's Anaris
  • Administrator
  • Noble Lord
  • *
  • Posts: 286
  • Sometimes, With A Bopping Stick
    • View Profile
Gabanus, any chance of you doing this in something I can host on a website, in PHP perhaps?
The music choice of the week is: "幼女戦記 ED / 『Tanya Degurechaff (CV: Aoi Yuki) - Los! Los! Los!』ENG SUB"
Quote from: Tom
I'd consider you crazy. But what else would I do? Keep it?
Quote from: Andrew
I knew a long time ago I was!

Wimpie

  • Developer
  • BM Dev Team
  • Mighty Duke
  • *
  • Posts: 1504
    • View Profile
Gabanus, any chance of you doing this in something I can host on a website, in PHP perhaps?

As far as I am aware, this is in VBA script.
Jeames (Vix Tiramora, EC), Osgar (Thalmarkin, BT)
Nasgar (Avernus, DWI), Jari (Outer Tilog, COL)

Anaris

  • BM Dev Team
  • Honourable King
  • *
  • Posts: 7838
    • View Profile
As far as I am aware, this is in VBA script.

Kill it with fire!
Timothy Collett

"The only thing you can't trade for your heart's desire...is your heart." "You are what you do.  Choose again, and change." "One of these days, someone's gonna plug you, and you're going to die saying, 'What did I say? What did I say?'"  ~ Miles Naismith Vorkosigan

Andrew

  • M&F's Anaris
  • Administrator
  • Noble Lord
  • *
  • Posts: 286
  • Sometimes, With A Bopping Stick
    • View Profile
As far as I am aware, this is in VBA script.

While yes, I could just host the script, I was thinking of something like a text box you put a battle report in, press submit, and get it reformatted for forum or wiki or whatever. All I'd really need is code that can parse a text input and generate a text output. I can build the form and everything else myself.
The music choice of the week is: "幼女戦記 ED / 『Tanya Degurechaff (CV: Aoi Yuki) - Los! Los! Los!』ENG SUB"
Quote from: Tom
I'd consider you crazy. But what else would I do? Keep it?
Quote from: Andrew
I knew a long time ago I was!

Wimpie

  • Developer
  • BM Dev Team
  • Mighty Duke
  • *
  • Posts: 1504
    • View Profile
Kill it with fire!

I for one like a solution for this, even if it's with a technology that not everyone can use or is an admirer of.
Jeames (Vix Tiramora, EC), Osgar (Thalmarkin, BT)
Nasgar (Avernus, DWI), Jari (Outer Tilog, COL)

Anaris

  • BM Dev Team
  • Honourable King
  • *
  • Posts: 7838
    • View Profile
I for one like a solution for this, even if it's with a technology that not everyone can use or is an admirer of.

As do I; I have hopes of being able to provide something more official in the medium-term future.
Timothy Collett

"The only thing you can't trade for your heart's desire...is your heart." "You are what you do.  Choose again, and change." "One of these days, someone's gonna plug you, and you're going to die saying, 'What did I say? What did I say?'"  ~ Miles Naismith Vorkosigan

Gabanus family

  • Board Moderator
  • Mighty Duke
  • *
  • Posts: 1322
    • View Profile
Gabanus, any chance of you doing this in something I can host on a website, in PHP perhaps?

I'm afraid that my knowledge on that end is somewhat limited.

The initial purpose of these scripts were to have actual challenges for me to expand my knowledge on coding. I'm not entirely sure how you would transform a VBA script into something webbased.

In the case of BM itself for instance I would imagine it may even be easier to just take a look at the part of the script that gives the layout of a battle report and in turn give a second option to change that layout to a wiki friendly one. In the BM code you already have the different variables after all, which I now had to retroactively reproduce as the source code was just a piece of text, void of the variables used to create it.

If you have specific questions or suggestions on how to do this and think I may be able to aid feel free to let me know though. So far I've only really been focussing on VBA and SQL though, so my knowledge on any other language is limited at best. Do plan on adding php within a few months, but will focus on SQL properly first.
New account active chars:
Garas: First Oligarch - Goriad: Astrum - Goriad II: Obia'Syela

MTYL

  • Noble Lord
  • ***
  • Posts: 230
  • No personal text here, sorry.
    • View Profile
Gabanus is right. It's very much possible to translate his script to php, js or anything web-usable really. In fact with all the variables already there for battle reports it shouldn't even be that much effort to make it part of bm official. And since it already uses wiki heavily I don't see why not.
_____
New family - Arnickles Renodin: Maura(OS), Myr(LN)
Old family - The (dead) Bennets: Max(SF), Joran(VT), Jarra(OS)