Heine

  • home
  • drupal
  • drupal core commits
  • about
Home

First steps

XNA SoundEffect ContentLoadException

Heine — Wed, 28/01/2009 - 21:59

It took me about 10 minutes to find out why the code below for a SoundEffect throws a ContentLoadException:

explosionSoundEffect = Content.Load<SoundEffect>("filename");

Error loading "[filename]". File contains Microsoft.Xna.Framework.Media.Song but trying to load as Microsoft.Xna.Framework.Audio.SoundEffect.

To save you the trouble:

  1. Select the file filename in the Solution Explorer.
  2. Go to its Properties tab.
  3. Set the Content Processor to Sound Effect - XNA Framework.

Done.

  • First steps
  • XNA
  • 3 comments
Syndicate content

Recent posts

  • Planet Drupal past and current
  • Help! - Cannot access a global variable.
  • Why is my module's update hook not listed on update.php's selection form?
  • How do I add a class to a link generated with l()
  • ZeroDayScan - Full path disclosure bug in Drupal 6.16 (0day)
more

Security reviews

  • Afraid custom code makes your site vulnerable?
  • You don't really trust that module you just downloaded from Drupal.org?

Sleep better after a security review.

Tags

Captcha CSRF Drupal embed Input Format modx OpenID Performance Planet Drupal rants Security Varnish
more tags
  • home
  • drupal
  • drupal core commits
  • about

Copyright © 2010 by Heine Deelstra. All rights reserved.