[ X ]
Aircraft Carrier
new unit for OpenRA - ra
Post new topic   Reply to topic Goto page 1, 2, 3  »
View previous topic :: View next topic  
Author Message
xanax
Level: 36



Position: Registered User
Joined: 15 Mar 2013
Posts: 46
Kel: 50  [ Donate ]

Online Status: Offline
PostPosted: Sun Mar 31, 2013 11:52 pm    Post subject: Aircraft Carrier Reply with quote

Hello.

As requested by Scott on the IRC channel, I made a Aircraft Carrier unit.

Screenshot :
http://img11.hostingpics.net/pics/862838test05.png

And the full image with all 16 frames (width: 217 px) :
http://img11.hostingpics.net/thumbs/mini_168655aricraftcarrierlargenotindexed.png

The model is finished but I don't know how to export this large PNG file to SHP.
Of course I have tried with OpenRA.Utility.exe but I have got many problems with palette files.

I was able to create the .PAL file of this image (and even the .ACT file for Photoshop) but I don't know how to keep good colors once converted to SHP.

When I convert it to SHP (with the RA palette), the colors are ugly. They don't respect the original image (see the screenshot above).

If someone can help creating this SHP file (with some nice colours) I would really appreciate.

Thanks
bye
Back to top
View user's profile Find all posts by xanax Send private message ICQ Number
Cmd. Matt
Developer
Level: 60



Position: Registered User
Joined: 01 May 2012
Posts: 776
Kel: 244  [ Donate ]

Online Status: Offline
PostPosted: Mon Apr 01, 2013 7:17 am  Reply with quote

I did the quirky SHP conversion for you. Here is what my terminal says

Code:
mono --debug OpenRA.Utility.exe
Usage: OpenRA.Utility.exe [OPTION] [ARGS]

  --settings-value KEY     Get value of KEY from settings.yaml
  --shp PNGFILE FRAMEWIDTH     Convert a single PNG with multiple frames appended after another to a SHP
  --png SHPFILE PALETTE [--noshadow]     Convert a SHP to a PNG containing all of its frames, optionally removing the shadow
  --extract MOD[,MOD]* FILES     Extract files from mod packages
  --tmp-png MOD[,MOD]* THEATER FILES      Extract terrain tiles to PNG
  --remap SRCMOD:PAL DESTMOD:PAL SRCSHP DESTSHP     Remap SHPs to another palette
  --r8 R8FILE PALETTE START END FILENAME [--noshadow] [--infrantry] [--vehicle] [--projectile] [--building] [--wall] [--tileset]     Convert Dune 2000 DATA.R8 to PNGs choosing start- and endframe as well as type for correct offset to append multiple frames to one PNG named by filename optionally removing the shadow.
  --transpose SRCSHP DESTSHP START N M [START N M ...]     Transpose the N*M block of frames starting at START.
  --docs MOD     Generate trait documentation in MarkDown format.

mono --debug OpenRA.Utility.exe --extract ra temperat.pal
mono --debug OpenRA.Utility.exe --extract ra ss.shp
mono --debug OpenRA.Utility.exe --png ss.shp temperat.pal


I then opened up the ss.png file with GIMP and expanded the image size and copied your 862838test05.png into it and saved it as ac.png

Code:
mono --debug OpenRA.Utility.exe --shp ac.png 217
mono --debug OpenRA.Utility.exe --png ac.shp temperat.pal


WTF something went wrong. Background of ca.png is violet instead of black. Fill bucket everything black.

Code:
mono --debug OpenRA.Utility.exe --shp ac.png 217


Now put into the game. Copy the newly made ac.shp to mods/ra/bits. Add the following to mods/ra/sequences.yaml:

Code:
ac:
   idle:
      Start: 0
      Facings: 16


Now open up mods/ra/rules/ships.yaml and add this:
Code:
AC:
   Inherits: ^Ship
   Buildable:
      Queue: Ship
      BuildPaletteOrder: 50
      Prerequisites: syrd
      BuiltAt: syrd
      Owner: allies
      Hotkey: a
   Valued:
      Cost: 5000
   Tooltip:
      Icon: clock
      Name: Aircraft carrier
      Description: Seaborne landing platform for aircraft
   Health:
      HP: 2000
   Armor:
      Type: Heavy
   Mobile:
      ROT: 2
      Speed: 2
   RevealsShroud:
      Range: 10
   Selectable:
      Bounds: 32,32
   RenderUnit:
   AttackMove:
      JustMove: true
   Chronoshiftable:
   IronCurtainable:
   RepairableNear:


You are limited by the grey shade and team colors Red Alert uses. So texture you model with those only. Get the SHP from http://content.open-ra.org/?p=detail&table=units&id=289 and feel free upload a better one there.


Attachment:

ac-screeenshot.png

 Filename:  ac-screeenshot.png
 Description:  A screenshot of what it looks like in-game. Note the edges. Have a look at the ss.png which adds some water pixels around to work around this. Maybe also tweak the perspective a bit. Also only some parts of the start ramp line are remapped to player color
222.88 KB :: Viewed 4941 Time(s) :: [ Download ]

Back to top
View user's profile Find all posts by Cmd. Matt Send private message ICQ Number
raminator
Level: 87



Position: Registered User
Joined: 15 Mar 2005
Posts: 294
Kel: 270  [ Donate ]

Online Status: Offline
PostPosted: Mon Apr 01, 2013 12:58 pm  Reply with quote

the model itself looks nice =)

but you need to add remap and compare the perspective to the other ships...
another thing that bothers me is the size...i know that carriers are huge but it should be only a few px bigger then the battleship.

good work =)
Back to top
View user's profile Find all posts by raminator Send private message MSN Messenger ICQ Number
xanax
Level: 36



Position: Registered User
Joined: 15 Mar 2013
Posts: 46
Kel: 50  [ Donate ]

Online Status: Offline
PostPosted: Mon Apr 01, 2013 2:14 pm  Reply with quote

Thanks you Raminator.

I understand the size problem but how could the Aircraft Carrier park several aircrafts on it ?

Because this aircraft carrier could have some options :
- build aircrafts ?
- park aircrafts on its deck (or inside it, hiding them with an elevator) ?
..

Btw, the palettes problems are a pain to deal with.
I really hope too see a GUI for OpenRA.Utility. link

PS: Raminator, I would be happy to see you in the IRC channel.
Back to top
View user's profile Find all posts by xanax Send private message ICQ Number
Nukem
Level: 53



Position: Registered User
Joined: 10 Sep 2011
Posts: 130
Kel: 217  [ Donate ]

Online Status: Offline
PostPosted: Wed Apr 03, 2013 10:43 pm  Reply with quote

Also something to add to the art, make the bottom look like it is actually in the water.. see destroyer or cruiser to see what I mean.
Back to top
View user's profile Find all posts by Nukem Send private message Send e-mail ICQ Number
JOo
Level: 49



Position: Registered User
Joined: 25 Jan 2012
Posts: 111
Kel: 126  [ Donate ]

Online Status: Offline
PostPosted: Thu Apr 04, 2013 3:53 pm  Reply with quote

Nukem wrote (View Post):
Also something to add to the art, make the bottom look like it is actually in the water.. see destroyer or cruiser to see what I mean.


thats exaclty what i thought !

looks very good , but it looks currently a bit too good for openra ..
Back to top
View user's profile Find all posts by JOo Send private message Send e-mail ICQ Number
epicelite
Level: 43


Position: Registered User
Joined: 16 Oct 2012
Posts: 134
Kel: 166  [ Donate ]

Online Status: Offline
PostPosted: Thu Apr 04, 2013 3:56 pm  Reply with quote

Guys, how will the soviets defend their carrier against enemy aircraft? They have nothing water-based that can shoot aircraft.
Back to top
View user's profile Find all posts by epicelite Send private message Send e-mail ICQ Number
Cmd. Matt
Developer
Level: 60



Position: Registered User
Joined: 01 May 2012
Posts: 776
Kel: 244  [ Donate ]

Online Status: Offline
PostPosted: Thu Apr 04, 2013 3:58 pm  Reply with quote

It was made for an upcoming single-player mission.
Back to top
View user's profile Find all posts by Cmd. Matt Send private message ICQ Number
xanax
Level: 36



Position: Registered User
Joined: 15 Mar 2013
Posts: 46
Kel: 50  [ Donate ]

Online Status: Offline
PostPosted: Sat Apr 06, 2013 9:37 am  Reply with quote

I don't get it.

I did what you adviced me Mailaender:
- I extracted a ship from the game (with openra.utility, same command as you posted above)
- I expanded its canvas size in Photoshop (to match my large image with all positions of my aircraft carrier)
- I pasted my artwork over this indexed png file
- I saved the png file (I got this image: http://www.hostingpics.net/viewer.php?id=980388aircraftcarrier.png .. which looked good to me AND with indexed colors)
- and converted it to a SHP file
- I modified the yaml files as you adviced me

But here are the results I have :
http://img15.hostingpics.net/thumbs/mini_180016ScreenShot004.png http://img15.hostingpics.net/thumbs/mini_910816ScreenShot001.png http://img15.hostingpics.net/thumbs/mini_530425ScreenShot005.png

My problems are :
- the yellow colors I used for the Aircraft Carrier control tower, the landing lanes, .. are not all correct
- the control tower doesn't look good, there are messing pixels (but maybe I used a bad lightning when I modeled the Aircraft Carrier)

These palette files are REALLY ANNOYING and a pain to work with.
Back to top
View user's profile Find all posts by xanax Send private message ICQ Number
raminator
Level: 87



Position: Registered User
Joined: 15 Mar 2005
Posts: 294
Kel: 270  [ Donate ]

Online Status: Offline
PostPosted: Sat Apr 06, 2013 10:03 am  Reply with quote

try to edit the remap colors in the extracted ship/shp (the 16 sandy-yellow colors at the bottom left).
make them purple and rerender your carrier with purple instead of yellow...
that should fix this.
Back to top
View user's profile Find all posts by raminator Send private message MSN Messenger ICQ Number
Petrenko
Level: 56



Position: Registered User
Joined: 08 Apr 2011
Posts: 157
Kel: 63  [ Donate ]

Online Status: Offline
PostPosted: Sat Apr 06, 2013 5:39 pm  Reply with quote

Heyho,

would anyone be as kind to convert my .pngs?

Thank you in advance :3


Attachment:

civc.png

 Filename:  civc.png
2.37 KB :: Viewed 4659 Time(s) :: [ Download ]

Attachment:

civt.png

 Filename:  civt.png
1.56 KB :: Viewed 4659 Time(s) :: [ Download ]


_________________
Hail to the soviets!
Back to top
View user's profile Find all posts by Petrenko Send private message Send e-mail ICQ Number
Nukem
Level: 53



Position: Registered User
Joined: 10 Sep 2011
Posts: 130
Kel: 217  [ Donate ]

Online Status: Offline
PostPosted: Sat Apr 13, 2013 8:00 pm  Reply with quote

Here you go

Attachment:
 Filename:  civc_168.shp
 Description:  Mapped and Shp'd.
3.11 KB :: Downloaded 211 Time(s) :: [ Download ]

Attachment:
 Filename:  civt_805.shp
 Description:  Mapped and Shp'd.
3.11 KB :: Downloaded 206 Time(s) :: [ Download ]

Back to top
View user's profile Find all posts by Nukem Send private message Send e-mail ICQ Number
JOo
Level: 49



Position: Registered User
Joined: 25 Jan 2012
Posts: 111
Kel: 126  [ Donate ]

Online Status: Offline
PostPosted: Sun Apr 14, 2013 4:44 pm  Reply with quote

size like this here should be okay (imho)

http://i.imgur.com/WqvtSAm.png

http://i.imgur.com/zKF887A.png

note: just a sketch
Back to top
View user's profile Find all posts by JOo Send private message Send e-mail ICQ Number
BaronOfStuff
Level: 59



Position: Registered User
Joined: 22 May 2011
Posts: 358
Kel: 353  [ Donate ]

Online Status: Offline
PostPosted: Sun Apr 14, 2013 5:57 pm  Reply with quote

Agreed, that's a much more reasonable size/look.
Back to top
View user's profile Find all posts by BaronOfStuff Send private message ICQ Number
Cmd. Matt
Developer
Level: 60



Position: Registered User
Joined: 01 May 2012
Posts: 776
Kel: 244  [ Donate ]

Online Status: Offline
PostPosted: Thu Apr 18, 2013 3:43 pm  Reply with quote

We could use the giant one for single-player and the small one as a real multi-player unit.
Back to top
View user's profile Find all posts by Cmd. Matt Send private message ICQ Number
Display posts from previous:   
Post new topic   Reply to topic Goto page 1, 2, 3  »