Problems while editing OXP

Discussion and information relevant to creating special missions, new ships, skins etc.

Moderators: winston, another_commander

Post Reply
User avatar
Sarin
---- E L I T E ----
---- E L I T E ----
Posts: 264
Joined: Sat Sep 13, 2008 11:26 am
Location: Out there, searching for truth

Problems while editing OXP

Post by Sarin »

Well...I've been messin with neolite-companion to create my personal, modded Mussurana that could keep up a bit with ships like Kirin or Caduceus, but ran into some problems.

First, texture. For a test, I replaced mussurana_auv.png in textures folder by my own, modifed. I did reload the OXPs with shift, but for some reason, it did not change.

Second, shipdata.plist . I changed energy banks, worked, changed top speed, worked, missile slots, worked, beam color, worked. But when I inserted lines for weapon power, it didn't work. Also, what is entry (if any) for shield power?

I tried looking through latest log, no error related to mussurana makes it even more weird.
User avatar
CheeseRedux
---- E L I T E ----
---- E L I T E ----
Posts: 827
Joined: Fri Oct 02, 2009 6:50 pm

Post by CheeseRedux »

According to the Wiki, weapon_energy only affects missiles and the forward weapon of NPC ships.
(I learned this yesterday while the BBS was down...)
It can also be used to set the power of turrets.
(I learned this the day before yesterday while the BBS was up...)
"Actually this is a common misconception... I do *not* in fact have a lot of time on my hands at all! I just have a very very very very bad sense of priorities."
--Dean C Engelhardt
User avatar
Lestradae
---- E L I T E ----
---- E L I T E ----
Posts: 3095
Joined: Tue Apr 17, 2007 10:30 pm
Location: Vienna, Austria

Re: Problems while editing OXP

Post by Lestradae »

Sarin wrote:
But when I inserted lines for weapon power, it didn't work. Also, what is entry (if any) for shield power?
Weapons power for player ships is hardcoded so that it can't be edited via oxps.

Shield power is always the same for players (NPCs don't even have shields, game-engine-internally). Only things that change that are boosters and/or military shields.

Hope that helps.
User avatar
Commander McLane
---- E L I T E ----
---- E L I T E ----
Posts: 9520
Joined: Thu Dec 14, 2006 9:08 am
Location: a Hacker Outpost in a moderately remote area
Contact:

Re: Problems while editing OXP

Post by Commander McLane »

Sarin wrote:
Well...I've been messin with neolite-companion to create my personal, modded Mussurana that could keep up a bit with ships like Kirin or Caduceus, but ran into some problems.

First, texture. For a test, I replaced mussurana_auv.png in textures folder by my own, modifed. I did reload the OXPs with shift, but for some reason, it did not change.
A possible reason is that there may be another OXP that re-changes the texture. Are you sure that the Mussurana you want to change is only contained in one single OXP?
Sarin wrote:
Second, shipdata.plist . I changed energy banks, worked, changed top speed, worked, missile slots, worked, beam color, worked. But when I inserted lines for weapon power, it didn't work. Also, what is entry (if any) for shield power?
Are you talking about a player ship? weapon_energy has no effect on player ships, it only works for NPCs. Otherwise it would be too easy to create an über-player ship.

The strength of your shields is hard-coded. You only can modify it by installing a shield booster or shield enhancer, either by default or by buying them.

By the way: Generally information like this can be found in the documentation. It is a good idea to use it when playing with Oolite's inner workings.
User avatar
Sarin
---- E L I T E ----
---- E L I T E ----
Posts: 264
Joined: Sat Sep 13, 2008 11:26 am
Location: Out there, searching for truth

Re: Problems while editing OXP

Post by Sarin »

Commander McLane wrote:
Sarin wrote:
Well...I've been messin with neolite-companion to create my personal, modded Mussurana that could keep up a bit with ships like Kirin or Caduceus, but ran into some problems.

First, texture. For a test, I replaced mussurana_auv.png in textures folder by my own, modifed. I did reload the OXPs with shift, but for some reason, it did not change.
A possible reason is that there may be another OXP that re-changes the texture. Are you sure that the Mussurana you want to change is only contained in one single OXP?
Good question. On a second thought, neoMussurana might be also in Personalities, but I am pretty sure that the one that appears in the market is the one from neolite companion, and I am changing that.

Well, I have a feeling that weap energy worked for player ships some time ago, after all, I dissected Isis OXP (Vampires) for it. I see no reason for it to be left out cause of cheating, there are still ways how to cheat...after all, that's both strength and flaw of opensource, easy editing. Pity...I guess I'll just go for Caddy then.
User avatar
Cmdr Wyvern
---- E L I T E ----
---- E L I T E ----
Posts: 1649
Joined: Tue Apr 11, 2006 1:47 am
Location: Somewhere in the great starry void

Post by Cmdr Wyvern »

Like others have said, you can't change the power output of the player's mounted laser(s). So sorry, no death beam that can slice a Kirin in half with a single burst for any of us. That leaves plenty of other dangerous toys to play with, though.

The rest of the shipdata is fairly easy to tweak, once you get the code syntax down. Have at it. :)

Custom textures though take a different approach. The .dat model file is in reality a simple text file; it can be read and modified in your text editor. There you'll find several references to the texture the model loads by default. Rename these references to point to your custom texture, and to avoid conflicts and mixups, rename the .dat file as well to something unique.

If your computer has enough horsepower to turn on shaders, then you can modify shader textures without having to fiddle around with the .dat file, or creating a custom texture.
Running Oolite buttery smooth & rock stable w/ tons of eyecandy oxps on:
ASUS Prime X370-A
Ryzen 5 1500X
16GB DDR4 3200MHZ
128GB NVMe M.2 SSD (Boot drive)
1TB Hybrid HDD (For software and games)
EVGA GTX-1070 SC
1080P Samsung large screen monitor
User avatar
Sarin
---- E L I T E ----
---- E L I T E ----
Posts: 264
Joined: Sat Sep 13, 2008 11:26 am
Location: Out there, searching for truth

Post by Sarin »

Bloody hell, this is getting seriously annoying.

I tried another experiment. I copied mussurana's .dat from models, renamed, opened and replaced all entries of texture with name of new, modified texture. Opened shipdata.plist, under mussurana-player I replaced both texture and model entries with modified ones, saved, flushed cache, no error...but NO CHANGE.

All actions done in Notepad++, so hopefully no parsing error. Checked latest.log, no error related to mussurana found.

And I can't turn on shaders until ATI (if ever) fixes that damn OpenGL error. I don't dare to mess with unofficial driver fixes with brand new laptop, if I was forced to reinstall system it would void the varranty. So that is a no-go for me.
User avatar
Commander McLane
---- E L I T E ----
---- E L I T E ----
Posts: 9520
Joined: Thu Dec 14, 2006 9:08 am
Location: a Hacker Outpost in a moderately remote area
Contact:

Re: Problems while editing OXP

Post by Commander McLane »

Sarin wrote:
Well, I have a feeling that weap energy worked for player ships some time ago, after all, I dissected Isis OXP (Vampires) for it.
No, weapon_energy does not do anything for player ships, and at no point in the version-history of Oolite has it done anything to player ships, regardless of your feelings.

You may have seen other OXPs using non-existing code, but that doesn't change the fact that the code is non-existing. It only means that you have seen a buggy OXP.

Some OXP writers in the past have written hilarious things in their shipdata, things that never existed outside their own imagination, and they even have managed to hallucinate themselves into thinking that their random nonsense commands actually have an effect. But programming/scripting doesn't work that way.
User avatar
LittleBear
---- E L I T E ----
---- E L I T E ----
Posts: 2876
Joined: Tue Apr 04, 2006 7:02 pm
Location: On a survey mission for GalCop. Ship: Cobra Corvette: Hidden Dragon Rated: Deadly.

Post by LittleBear »

<owns up>

Do you have Random Hits installed? Please note that the models and textures for the OXP ships it uses are included in the Random Hits OXP Models and Textures folders. So it will overwrite the change you are making if you haven't changed the name of the massurana's texture and .dat files and you are modding an OXP which is loaded before Random Hits. As the OXP you are modding (M for mussurana) is alphabetically higher than R for RandomHits then what'll be happening is your changes are being read, but the model and texture in Random Hits will be switching it back to the normal unmodified neo-oolite one. Renaming RandomHits to aaaaRandomHits should avoid this though. :wink:

As a general tip for fiddeling with Oolite, test with only your OXP installed. If it doesn't work, then you know that the bug is down to your changes. If you mod somthing (or write something from scratch) it generally saves wear and tear on your nerves to name all your variables, roles textures etc something unique like little_bear_filename (or whatever), that way you know that its defenatley gonna be your version that Oolite uses. :) Naturally, I should have done this with the random hits texture names! :oops:
OXPS : The Assassins Guild, Asteroid Storm, The Bank of the Black Monks, Random Hits, The Galactic Almanac, Renegade Pirates can be downloaded from the Elite Wiki here.
User avatar
Diziet Sma
---- E L I T E ----
---- E L I T E ----
Posts: 6311
Joined: Mon Apr 06, 2009 12:20 pm
Location: Aboard the Pitviper S.E. "Blackwidow"

Post by Diziet Sma »

Sarin wrote:
if I was forced to reinstall system it would void the varranty. So that is a no-go for me.
WTF?? since when? I've never heard of that.. that's WHY the manufacturer provides an install-disk or a recovery partition.. so you can rebuild your system if it gets trashed by, for instance, a virus.. who told you a re-install voids the warranty?
Most games have some sort of paddling-pool-and-water-wings beginning to ease you in: Oolite takes the rather more Darwinian approach of heaving you straight into the ocean, often with a brick or two in your pockets for luck. ~ Disembodied
Post Reply