Text and sound not loading. Please help!

Monkey Forums/Monkey Programming/Text and sound not loading. Please help!

ondesic(Posted 2012) [#1]
I thought this was a html5 problem, but I am having the same problem with XNA.

Basically, when I run my game in HTML5 from the IDE, it runs fine. All the text shows and sound plays. However, when I take the .build folder's content and put it on the web, the text and sound doesn't show or play. There are no errors just no text or sound. The images show fine.

When I create an XNA project, the same thing happens. No sound or text but the images show fine. Has anone run into this problem before? Any solutions?


Jesse(Posted 2012) [#2]
Are you using the default folder for all of your data?
For example: if your game is called war.monkey then you need to create a folder by the name war.data and put all of your media files in it.

If that is not the problem you are going to have to post a more detail description of what you are doing.


ondesic(Posted 2012) [#3]
Yes, I am using the .data folder. Again, there are no errors, meaning, it must e finding all the files. It just isn't displaying the text.


Jesse(Posted 2012) [#4]
there might be someone here that can help you but for me I would need to look at your graphics and images to figure out what is wrong.

can you create a minimalistic example that has the same problem and post it here?


Midimaster(Posted 2012) [#5]
try to do it with a new program, which only loads one of your text files and displays text on the screen. what happens?

[monkeycode]Strict
Import mojo

Class Test Extends App
Global TheString$

Method OnCreate%()
TheString=LoadString("MyText.txt")
SetUpdateRate 30
Return 0
End

Method OnUpdate%()
If KeyHit(KEY_ESCAPE) Then Error ""
Return 0
End

Method OnRender%()
Cls 55,255,55
DrawText "Test=" + "123456",10,30
DrawText "Len=" + TheString.Length(),10,60
DrawText "T=" + TheString + "!",10,90
Return 0
End

End


Function Main%()
New Test
Return 0
End


[/monkeycode]