Quote:
Originally Posted by Stefan
The volume depends on the position of the npc and the PLAYSOUND parameters, may be thats the problem?
|
It doesn't seem to be the problem, no. The sound plays fine when the NPC is visible. It does not play at all (or with a volume level of 0, who knows) when the NPC is invisible. Example code:
PHP Code:
//#CLIENTSIDE
function onCreated() {
setImg("block.png");
setShape(1, 32, 32);
}
function onPlayerTouchsMe() {
this.hide(); // take this out and the sound works
with (findImg(200)) {
x = thiso.x;
y = thiso.y;
ani = "swim";
}
}
Quote:
Originally Posted by Stefan
Having an example (server name, level name, script/weapon/command) would help
|
I'll set something up for you and then edit the post soon-ish.
Edit: It's on Atlantis, level name is at_v6_bug.nw. The level contains some bushes to also show the first bug (sound not playing) and then a block showcasing the crash bug. Touch the block to make the gani play, which in turn makes Graal crash. Block's class is "v6_bug", you can play around with that. The gani I used is "at_leaps2" in case you want to check that out. If you want to give the first bug a try, comment out line 164 in the "object" class (that's the hide() call); you'll then see that the sound plays
Also, while you're at it: mind restarting Atlantis' GServer? Maybe you remember, we're having some problems with a GMap and you suggested a restart, but apparently only you can do it.
Edit²: I've encountered another strange bug where I'm creating a GUI control like so:
PHP Code:
new GuiScrollCtrl("PauseBackground") {
x = y = 0;
width = GraalControl.width;
height = GraalControl.height;
profile = GuiBlueScrollProfile;
useOwnProfile = true;
profile.modal = false;
profile.border = 0;
profile.bitmap = "";
profile.fillcolor = { 0, 0, 0, 128 };
horizSizing = "width";
vertSizing = "height";
}
And instead of filling the whole client window, it's offset a couple pixels and smaller than GraalControl. When changing either x, y, width or height, the control gets its "real" position and size.
Edit³: More info on the GUI control bug: this only seemed to happen to the second control of two controls being created the same way (as shown above). I switched them in my code (so the former second one now gets created first) and both of them work perfectly fine now. I don't know why...