Sunday 31 January 2010

Tutorial: Customizing the PocketPlane - Part 2

This information applies to Innodil's Pocket Plane version 2.0 or higher only!
In this tutorial you'll learn how to completely customize where all containers and NPCs are located. Those pesky number to specify the locations... they're not that hard to get, especially after this, hopefully useful, tutorial. There is a way to do this without the toolset installed, but it is very cumbersome to say the least... For this article, I'm going to stick to the toolset version.

IMPORTANT NOTE: You should do customizations before using the pocketplane to store items. As soon as containers contain items and you remove or place them somewhere else, all your items will be lost when you reload the area layout. You can however still add new/additional NPCs and containers after you start using the pocket plane. If you want a custom layout, I advise you to create it before really starting to play!

Getting Started

This tutorial involves editing (M)2DA files. There are 2 ways to edit those files:
  1. If you have the toolset installed and know how to use ExcelProcessor.exe: Download the 2DA Sources and edit them as usual. Note: in the remaining tutorial screenshots of GDApp are used. The tutorial also applies to using Excel to edit the 2DA sources of course.
  2. If you don't have the toolset. Please download GDApp and extract it somewhere. Next, Download the GDA files and also extract them somewhere.
For those using the 2DA Sources, all the 2DA files are in 1 excel file for easy editing: inno_pp_custom_2da.xls

The screenshots shown in this tutorial are from the toolset, if you don't have it installed, go get it first: Download Dragon Age: Origins Toolset

An important note about the "mod's install dir"
You will have to copy files to the mod's core/override folder. In all tutorials, I will use my own paths on a Windows 7 machine. If you use another OS like Windows Vista or Windows XP, the first part of the folder might differ. It is always in your User Folder under My Documents or Documents on some operating systems. If you really don't know where this folder is, do a search on your C:\ drive for the folder called inno_pp. This folder is the mod's install folder and I will always refer to a folder inside this install path.
In all tutorials I will refer to this folder as  [My Documents]\BioWare\Dragon Age\AddIns\inno_pp. 

Getting the numbers...

The easiest way is basically to just design your area in the toolset, and punch in the numbers acquired that way in the inno_pp_layout M2DA file. You might ask, can't I just replace the area by exporting it to the override folder? Well, you can try :-) But since Dragon Age stores areas in your savegame, you won't see any updates. This is the main reason Innodil's Pocket Plane was build with all the 2DA files: to circumvent this "update issue".
Fire up the toolset, open a module of your choice, but:
  • make sure it is not the Single Player Campaign
  • make sure your module extends the core game resources
Next, create a new area by clicking File -> New -> Area in the menu, give it a name, it doesn't matter, something like test_area will do for example. In the object inspector on the bottom left of the toolset, set the Area Layout property to den308d. You should see something similar to the screenshot below.

So with the area ready, follow the next steps, the number correspond to the numbers in the next screenshot.
  1. In the Palette Window select the placeables filter
  2. Select the container your want to place. Note that if you are getting coordinates for a chest, you should actually select a chest. For an armorstand, pick that placeable. In this example, I'll go for a wooden crate.
  3. Next place the placeable object in the area in a spot of your choosing
  4. Using the move and rotate buttons, place your object exactly in the right spot and angle
  5. Write down, or copy/paste the numbers of both orientation and position
Great, so we've got a bunch of numbers. Well actually, there are some notes about them I can make:
  • Both numbers are actually vectors. They consist of an X, Y and Z coordinate and are printed as X,Y,Z like you see them in the toolset
  • For the orientation only one of the coordinates (normally the X) will have a significant number, other small values can be ignored
  • In the position vector, the Z coordinates is usually 0. Don't let the 1.49012e-008 fool you since that's exactly the same as 0.0000000149012 which is basically just 0 for the sake of positioning...
Taking the above notes into account, we are left with these numbers:
  • orientation: 97.4612
  • position X: -14.6057
  • position Y: 0.172061
  • position Z: 0
You might want to place container on top of props, all the already available "furniture" in the area: don't waste your time, it won't work :) Most of those don't have what they call collision planes meaning "you can't stand or put stuff on them". The platform in the area is the only exception to that. Note that in the toolset you can actually place them on top of whatever you like, but the Z coordinates won't be accepted when spawning an item after loading the layout M2DA file, resetting it to ground level, or inside the prop you were trying to place it on.

Using the numbers

So now we have a bunch of numbers, we can go ahead and edit the inno_pp_layout M2DA. You can basically just adjust an existing row's numbers, or you can create a complete new layout from scratch. For the tutorial, we will create a layout from scratch. Just follow these rules when editing the M2DA file:
  • If you just want to change the location of an existing container/NPC in the Pocket Plane, you don't need to change the tag
  • If you want to completely start from scratch, change all the tags except the ones for the merchant NPCs
  • Changing tags means the previous object is destroyed, everything IN it will also be destroyed!
  • Basically, if you are editing the M2DA and your changes don't appear, you most likely forgot to update tags, and the loading script doesn't notice your changes...
So open up inno_pp_layout.gda with GDApp and delete all rows in there, except the INVALID one. Next add a new line, choose an object, a tag and punch in the numbers.

Finishing up

To test, save the GDA, copy it to [My Documents]\BioWare\Dragon Age\AddIns\inno_pp and fire up the game. Go the the Pocket Plane, talk to the keeper and ask to reload the layout. Leave the Pocket Plane and when you go back, the only thing there should be your new object from the GDA file. (Note that the keeper and a few other things are always there!).

3 comments:

  1. Thanks for the tutorial, it's very helpful..

    I've been trying unsucessfuly to modify the Shadow Armor set for Warriors and Rogues. is there any way to modify it so it appears to be light armor? i hate how it looks on my rogue..

    ReplyDelete
  2. First, great tutorials. I do have one question for you:

    Say I wanted to add, for example, a treasure pile somewhere. What would I put under the resource column for that? I noticed you have inno_pp_storage.utp for the chest, but I do not see anything for a treasure pile. Would I just add the genip_treasure_pile.utp for the resource to make it work?

    ReplyDelete
  3. Shadow armor: this is a left over artifact that isn't really part of the mod. I suggest you just create your own custom armor, there isn't a way to customize the own in the mod. There are a lot of tutorials on making custom items so just google for that. What you CAN do is make the items appear in one of the merchants by editing the inno_pp_merch* GDA files (well one of them)

    Custom placeable models: Anything in DAO that is of type container (should have (Container) after it's name) can be used as a placeable in the pocket plane. Indeed in the resource you can put genip_treasure_pile.utp

    ReplyDelete

Please note that I will only provide limited support in the comments section. If you need help, please check the "discussions" tab on the Project site.