Sunday, May 06, 2007

XNA, clickonce and MSBuild

The last few months I have been working with XNA off and on. To be honest, mostly working on subversion and clickonce. I don't have a lot to show right now, but that is the nice thing about clickonce is that when I do get more of the game done then it will be automaticly updated.

I am hosting the site from my home computer right now through no-ip.com, so if the site may be down if my computer is off. Secondly, the bootstrap should install all the necessary prerequisites, but if it doesn't then the links are listed below. Here is my current progress. BTW, the images are SUPER large right now, so it might take awhile to download. I am currently working on reducing the size of the images and creating a Xbox 360 version.

XNA Prerequisites for the PC

.NET Framework 2.0
Microsoft XNA Framework Refresh

For those wonder how I got Clickonce to deploy the converted textures and not the source textures, I had to use a little MSBuild hack in the .csproj file. After poking around in MSBuildBinPath and looking through the Microsoft.Common.targets file I realized that some of the Publish functionality can be overriden by overriding MSBuild targets. All I needed to do was add the files to be published in the MSBuild script. Specificly, I needed to override the _DeploymentComputeClickOnceManifestInfo target and add files from my Content directory in my build output. Here is the code to do this:



<!--Override _DeploymentComputeClickOnceManifestInfo Manifest so I can add content files that I need-->
<Target
Name="_DeploymentComputeClickOnceManifestInfo"
Condition="'$(GenerateClickOnceManifests)'=='true'"
DependsOnTargets="_DeploymentGenerateTrustInfo">

<!-- Grab just the serialization assemblies for a referenced assembly. There may also be a symbols file in ReferenceRelatedPaths -->
<CreateItem Include="@(_ReferenceSerializationAssemblyPaths)" Condition="'%(Extension)' == '.dll'">
<Output TaskParameter="Include" ItemName="_SGenDllsRelatedToCurrentDll0" />
</CreateItem>
<CreateItem Include="@(_SGenDllsRelatedToCurrentDll0->'%(FullPath)')">
<Output TaskParameter="Include" ItemName="_SGenDllsRelatedToCurrentDll" />
</CreateItem>

<!-- Flag primary dependencies-certain warnings emitted during application manifest generation apply only to them. -->
<CreateItem Include="@(ReferencePath)" AdditionalMetadata="IsPrimary=true" >
<Output TaskParameter="Include" ItemName="_DeploymentReferencePaths"/>
</CreateItem>

<!-- Create list of items for manifest generation -->
<ResolveManifestFiles
EntryPoint="@(_DeploymentManifestEntryPoint)"
ExtraFiles="$(IntermediateOutputPath)$(TargetName).pdb;$(IntermediateOutputPath)$(TargetName).xml;@(_ReferenceRelatedPaths)"
Files="@(ContentWithTargetPath);@(_DeploymentManifestIconFile);@(AppConfigWithTargetPath)"
ManagedAssemblies="@(_DeploymentReferencePaths);@(ReferenceDependencyPaths);@(_SGenDllsRelatedToCurrentDll)"
NativeAssemblies="@(NativeReferenceFile);@(_DeploymentNativePrerequisite)"
PublishFiles="@(PublishFile)"
SatelliteAssemblies="@(IntermediateSatelliteAssembliesWithTargetPath);@(ReferenceSatellitePaths)"
TargetCulture="$(TargetCulture)">

<Output TaskParameter="OutputAssemblies" ItemName="_DeploymentManifestDependencies"/>
<Output TaskParameter="OutputFiles" ItemName="_DeploymentManifestFiles"/>

</ResolveManifestFiles>

<!--here is where I add the extra content-->
<CreateItem Include="$(OutDir)Content\**\*">
<Output ItemName="ExtraFiles" TaskParameter="Include" />
</CreateItem>

<CreateItem Include="@(ExtraFiles)" AdditionalMetadata="TargetPath=Content\%(RecursiveDir)%(Filename)%(Extension);IsDataFile=false;DependencyType=Install;">
<Output ItemName="_DeploymentManifestFiles" TaskParameter="Include" />
</CreateItem>
<!--END - here is where I add the extra content-->

<CreateProperty Value="ClickOnce">
<Output TaskParameter="Value" PropertyName="_DeploymentManifestType"/>
</CreateProperty>

<!-- Obtain manifest version from ApplicationVersion and ApplicationRevision properties -->
<FormatVersion Version="$(ApplicationVersion)" Revision="$(ApplicationRevision)">
<Output TaskParameter="OutputVersion" PropertyName="_DeploymentManifestVersion"/>
</FormatVersion>

<FormatUrl InputUrl="$(_DeploymentUrl)">
<Output TaskParameter="OutputUrl" PropertyName="_DeploymentFormattedDeploymentUrl"/>
</FormatUrl>

<FormatUrl InputUrl="$(SupportUrl)">
<Output TaskParameter="OutputUrl" PropertyName="_DeploymentFormattedSupportUrl"/>
</FormatUrl>

</Target>

Saturday, April 21, 2007

Publish resume using Google docs

Taking a que from a fellow employee I work with I decided to publish my resume which has gone neglected for some time. The process was easy enough and it is nice to simply be able to send a link out for whomever whats to look at the resume.

So, here is it. Feel free to critique it all you want. BTW, it is only half completed currently.

Monday, February 19, 2007

2 in 1

I just finished up with Halo 2 tonight and I finished Final Fantasy 3 this morning. Haha! Halo 2 was awesome! I am really looking forward to the Halo 3 now. Final Fantasy 3 wasn't all that great, but I felt obligated to finish it. Well, now that I have those two titles under my belt, I can rest easy tonight. I need the rest after 12 hours of video gaming. Goodnight! ;-)

Sunday, February 04, 2007

Subversion service (cont.)

As I was helping a friend setup a Subversion service I realized my last blog was missing some important information.

First of all, the service is NOT installed in the Subversion install by default. To get the service exe, which is a wrapper for svnservice, click here. I couldn't remember where I had gotten the svnservice wrapper so I had to search Google again, and this time came across a very helpful blog. This blog has all the information needed to setup a Subversion server/service from scratch.

Tuesday, January 09, 2007

Souls of Rebirth

After about 5 hours of game play I made it through the GBA Final Fantasy II bonus game, the Souls of Rebirth. It wasn't too tough except for the beginning part. Sometimes the game would force me to fight monsters that I couldn't defeat. I would have to save often and reload in these cases.

I noticed in the Souls of Rebirth that Blink is an awesome skill. I realized that it stacks! It can be cast repeatedly until the characters evasion is so high that they can't even be hit! Unfortunately, most monsters use spells at the end of the game, but the most devastating spell, confuse, doesn't effect the party much either because even the other party members can't hit each other.

Monday, January 01, 2007

Puzzling


Over Thanksgiving, my brother Jake and I worked on a jig saw puzzle. OMG, it was the hardest puzzle I have EVAAAR worked on. I suppose it would have been harder if we had done it upside down but just barely. I kept egging my brother on by saying, "Just keep helping, It will get alot easier real soon." Well, that was when we had about 100 pieces left. Then it was 50, 30, 20, 10, 5, ummmmmm still not easy. Honestly, when we had gotten down to the last 2 pieces we still didn't know which spot they went in without trying all the combinations to make them fit. Amazing.

It was a 1000 piece puzzle of the painting "Pleasant Day" by Cao Yong. The colors in the puzzle seemed like they may have been a bit faded, because it seemed like all the peices looked alike. The only sections that were easy was the sky and he water.

HAPPY NEW YEARS!

Last blog for today, I promise. ;-)

Final Fantasy II defeated!

I finally beat Final Fantasy II for the GBA. Man it took alot longer than I thought it would. I had went through the game before on a translated Famicom rom, but the GBA version is much better.

It took me 35:42 hours to go through the game but I went really slow, and even fell asleep a couple of times when I was playing. :-) Final Fantasy games always put me to sleep when I play for some reason. All of my characters where basically tanks. I used one handed weapons and a shield except for the rare occasion when a bow was more powerful. I only cast spells when I needed heals or when a monster had really high defense and was weak against a spell.

I think that this game is a BIG improvement over Final Fantasy I. The story is much more developed and the spells, weapons, monsters, and characters are much more interesting. I thought that the music and graphics were alittle bit better to. The only problem I had was that it took TOO long to level up spells. I wanted to see all the level 10 spells but it just took too long for me to level them up that far. All-in-all this was a very fun game and it definitely kept me busy through Christmas. Oh yeah, I still have the bonus game, Soul of Rebirth, to do too!

Looking forward to Final Fantasy III on the DS!

HAPPY NEW YEARS!

Subversion Service

Installing a subversion service on Windows is pretty straight forward, but I got tripped up on a couple of things installing it a second time.

  1. First, get Subversion and install using the MSI. The version I installed was 1.42.
  2. Install the windows service. I can't remember if the installer does this automaticly or not. To do it manually just run the following command: svnservice -install -d -r C:\YourRepositoryRoot. This will configure the Subversion service to run as a service and it will look in the C:\YourRepositoryRoot directory for Subversion repositories.
  3. To change the repository root later just run the with the setup argument: svnservice -setup -d -r C:\YourRepositoryRoot.
That should be all that is needed to get the Subversion service up and running. You will of course need to create subversion repositories in the root directory, but I'll leave that to another blog.

HAPPY NEW YEARS!