Home   Help Search Login Register  

Author Topic: The crate from hell  (Read 2724 times)

0 Members and 1 Guest are viewing this topic.

brsseb

  • Guest
The crate from hell
« on: 14 Sep 2002, 21:20:36 »
Hi everyone

Im making my first addon for OFP & its a crate. Yes, a simple box with some crate textures. But it wont work properly in OFP.

Ive read the online tutorials & thought I should be able to make such a simple static object. But anyway, heres is what I did:

Ive installed oxygen with Bulldzer viewer. Made a simple box-structure (F7 with 2 in x/y/z dimensions). Used TexView to convert some crate-textures into pac, applied them & the thing looks quite nice in the viewer (for a crate, at least).

Then I created a box again, about 95% of the original`s x/y/z dimensions & applied some weight to it to use it as the Geometry. Then I took my crate.p3d with textures, packed them in a pho-file together with a modified config file I borrowed from a static object addon & tested it ingame.

And there It was, my lovely crate...burried halvway into the ground & without a single texture! "This is an outrage!" I cried out loud, cursed the damn thing & here I a. Begging for help.

Anyone?




Offline ScouseJedi

  • Members
  • *
Re:The crate from hell
« Reply #1 on: 14 Sep 2002, 22:17:14 »
The centre line of the oxygen is the ground level. Try moving all the models up a bit.
[edit to make it understandable]
The main horizontal line in O2 in the centre is the ground level. From your description you have made the crate in the exact centre of the grid area. Move your models up a bit..

Actually Im sure there is a LOD where you can specify the ground contact areas. Try Zdwar's site, From memory the jeep ground contact LOD (no idea of actual name) has just 4 vertexs in it. That might place your crate on the ground

[/edit]
« Last Edit: 14 Sep 2002, 22:20:42 by ScouseJedi »
'The truth is a beautiful and terrible thing, and should therefore be treated with great caution.'
Albus Dumbledore

SpclFrcsSnpr

  • Guest
Re:The crate from hell
« Reply #2 on: 14 Sep 2002, 23:16:05 »
What about weapons? Do you need anything other than the weapon and muzzleflash models?

brsseb

  • Guest
Re:The crate from hell
« Reply #3 on: 14 Sep 2002, 23:37:43 »
Thankz for the tip. The box was created with the center at the grid floor so moving the whole thing up solved a part of the problem. And yes, there is a LOD for indicating ground contact. But the tutorial I read said it was only mandatory for moving objects, not statics like crates.

So Ive got my  crate in the right positon (not burried into ground) & the collition detection works nice (geometry). But the textures are still gone! Still the same white boring box. As Ive said, I have 3 different crate-textures. They was convertet from jpg to pac in TexView1.1 & I applied them to all of the box sides using:  Select face, "A" (Enter texture mode), dragging a box around the face, load texture & finally "B" to apply the texture.

Looks nice in Bulldozer, but here is the catch:
When I opened the box.p3d file again (right after texturing) Bulldozer told me that my model was a "Bad object". What does that mean?It seems that I get this message whenever I have applied textures to a model!


Offline ScouseJedi

  • Members
  • *
Re:The crate from hell
« Reply #4 on: 14 Sep 2002, 23:50:05 »
are your textured referencing \data\ or the actual folder where the .pac's are?

Are the textures in the same directory as the p3d file?

Thats about as far as I can tell you. Oh, Suma from Bis says that Viewer does funny things unless its in the root directory of a drive c:\, d:\. I put my textures into there and have no trouble.


There are some posts on the Breathe forum section of the flashpoint1985 site that may help you.

I d/l O2 today and have not even completed my first model (Its what OFP has needed for too long - a rubbish skip), if you find the answer there please post it here.

Good luck :)
'The truth is a beautiful and terrible thing, and should therefore be treated with great caution.'
Albus Dumbledore

brsseb

  • Guest
Re:The crate from hell
« Reply #5 on: 14 Sep 2002, 23:57:08 »
Textures are in the same dir as the p3d file. And the viewer is installed correctly (on a "fake" root dir using the SUBST-tip in the installation guide). Here is my config-file anyway. Havent specified anything about textures in it, didnt think it was necesary:

Code: [Select]

class CfgPatches
{
   class BCS_crate
   {
      units[] = {BCS_crate};
      weapons[] = {};
      requiredVersion = 1.75;
   };
};
class CfgVehicles
{
   class All {};
   class Static: All {};
   class Building: Static {};
   class NonStrategic: Building {};
   class TargetTraining: NonStrategic {};
   class TargetGrenade: TargetTraining {};
   class BCS_crate: TargetGrenade
   {
      model="\crate\crate";
      armor=20000;
      scope=2;
      displayName="BCS crate";
   }
}

« Last Edit: 14 Sep 2002, 23:58:37 by brsseb »

Offline ScouseJedi

  • Members
  • *
Re:The crate from hell
« Reply #6 on: 15 Sep 2002, 00:08:29 »
Knew I had seen white model post somewhere

Zwadar :

You must have textures in yours pbo! In budozer you can have textures in buldozer's data directory, but there aren't be in game "data.pbo" file. You must put texture to your's pbo. And rewrite path in your's model.
E.g. You pbo will be "sign.pbo", so you must put there yours textures, than open model, in list of textures double click on texture name with "ctrl" pressed. That will select every faces which are using this texture. Than RMB to some viewport with "aLt" pressed (you will active this viewport), than press "E" for open face proparties window. In bottom right os path to texture, so change "data\texture.pac" to "sign\texture.pac"
That may help!  

/Zwadar

http://www.flashpoint1985.com/cgi-bin/ikonboard301/ikonboard.cgi?s=3d836e644c78ffff;act=ST;f=38;t=18611
'The truth is a beautiful and terrible thing, and should therefore be treated with great caution.'
Albus Dumbledore

brsseb

  • Guest
Re:The crate from hell
« Reply #7 on: 15 Sep 2002, 00:31:48 »
YESS!!!! SUCCESS!!!!

The crate is in-game with full textures!  ;D Im SO proud!

Yep, is was the texture path that was the problem. In a way. The texture paths wasnt set to the Data-folder, but it was set as it SHOULD be. But heres the catch:

Bulldozer is installed in the root of my fake Z:drive (SUBST). Inside that folder (actually C:\Oxygen) I made a folder named "Projects". So my crate & textures was in "Z:\Projects\Crate". Now all the texture paths (The one in the bottom of the dialog i got when pressing 'E') was in the editor set up to "projects/crate/texture_name.pac". So I moved my crate-folder out of "projects" so it laied directly in the viewer folder & rerouted my texture to read: "crate/texture_name.pac".

NOW everything went OK. strange. Looks like the addon folder must be in the root & not in any subfolder?!





« Last Edit: 15 Sep 2002, 00:46:37 by brsseb »

Offline KTottE

  • Former Staff
  • ****
Re:The crate from hell
« Reply #8 on: 15 Sep 2002, 13:57:53 »
More specifically the addon folder must be in the same folder as buldozer.exe

Short 'n simple ;D
"Life is not a journey to the grave with the intention of arriving safely in a pretty and well preserved body, but rather to skid in broadside, thoroughly used up, totally worn out, and loudly proclaiming 'WOW What a Ride!'"