Menu

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Messages - GrogGames

#1
very nice!!! ;-D

When i was a "kid", i learn programation with AGS, with the proskito's templates,
and i remember, thah i was very surprised with the "while-int i=0-i++" conjunction, i tought "oh, what a clever use of while" (i had no-idea of "for", or something like it).
I think, if "for" existed in AGS in that moment, then that no was happen. That was a great moment of my adolescence.

But, yes, is very, very useful for me (now more adult), the "for" sentence. At overall, for better understanding of the code.

I am studing "Informatic Enginering", and i no have idea of "continue" existence . That is very useful too. And i learn something new :)

And, obviulsy, "break" is useful, always that will be used with responsability.

in conclusion, very interesting propose!
#2
Quote from: JawCross on Tue 17/05/2011 09:40:58
I have also problems with Ubuntu. I first tried under 64 bit, but now I'm trying with 32 bit.

I copied instructions from forum to the wiki:
https://gitorious.org/ags/pages/HowToBuild#Building+under+Ubuntu
I fixed one non-printing character and ln -s libalfont.so.2.0.9. (Are these correct now?)


My problem is cmake is not founding alfont and libcda. Is there still some details missing in instructions?
YES!  =)
i found that details!
check the wiki now, i added that details.

A question, when you run "cmake .". Do you not receive a message "package allegro not found"?
With allegro 4.2 i receive that message, then i has to compile allegro 4.4, and the message disappeared.


with that instructions now compile! thanks  =)
#3
i tried to compile ags port from http://gitorious.org/ags  in ubuntu 11.04 i386 live cd.
I installed all the libraries with synaptic, except allegro libalfont and libcda. For libcda and libalfont i used this
for libalfont
Code: ags

gcc -fPIC -DPIC -O2 -m32 -Iinclude `freetype-config --cflags` -o src/alfont.o -c src/alfont.c
gcc -O2 -m32 -shared -Wl,-soname,libalfont.so.2 -o libalfont.so.2.0.9 src/alfont.o `freetype-config --libs` `allegro-config --libs |sed 's/-lalleg_unsharable//'`
install -m 755 libalfont.so.2.0.9 /usr/lib/
install -m 644 include/alfont*.h /usr/include/
ln -s libalfont.so.2.0.9 /usr/lib/libalfont.so.2
ln -s libalfont.so.2.0.9 /usr/lib/libalfont.so.2
ln -s libalfont.so.2.0.9 /usr/lib/libalfont.so


For libcda
Code: ags

gcc -O2 -m32 -fPIC -DPIC -o linux.o -c linux.c
gcc -O2 -m32 -g -shared -Wl,-soname=libcda.so.0 -o libcda.so.0 linux.o
install -m 755 libcda.so.0 /usr/lib/
mkdir /usr/include/libcda
install -m 644 libcda.h /usr/include/libcda/
ln -s libcda.so.0 /usr/lib/libcda.so

for allegro, i downloaded the 4.4 source and compiled.
that works fine, but when i try to compile ags, i received this message
Code: ags

Linking CXX executable ags
/usr/lib/libalfont.so: undefined reference to `_msize'
collect2: ld returned 1 exit status
make[2]: *** [Engine/ags] Error 1
make[1]: *** [Engine/CMakeFiles/ags.dir/all] Error 2
make: *** [all] Error 2



thanks for help, sorry if I express wrong, i speak spanish :P
#4
Well, i've been testing my Imuse sistem. This time, to improve the  synchronization i tried putting all instruments from the beginning and leaving a high volume only to the ones that have to be played.

However, with both methods (this one and the last one) the synchronization of the instruments has improved with the new beta, but it still needs to improve a bit more.

I ran the demo on a pentium 4 of 3.3 ghz and about 90% of the times they were synchronized but i also ran it on a pentium 4 of 1.8 ghz and the result is different. In this case, in most of the times they weren't synchronized.

I'm sending you this game as a demonstration, I used the new sistem I told you about on it. Because of being only 2 instruments there shouldn't be any problem. Just like the last time I repeated the same instrument to notice if they are synchronized. If you press F9 you'll notice that sometimes it loads more synchronized and other times less.

Demo:
http://www.mediafire.com/file/zmjwm2jmrg2/imuse bug new.rar

Well, I hope you can fix it, greetings and thank you very much.
Nahuel 36
#5
We are trying to make an imuse system where the instruments load in different ogg files (with the same length) and reproduce at the same time, so when you move from one region of the room to another some instruments will start playing while other may stop or the other way around. What should happen is that the new sounds should start looping following the reproduction time of the ones that are already playing while that isn't what's happening. Instead of that , they start with a little random lag, for example:
We have 2 oggs with 30 sec duration, battery and guitar. In region 1, battery is playing and in region 2 while battery is still playing the guitar starts playing too. Lets say that on sec 17 i move from region 1 to 2. What should happen is that the guitar file should start playing its 17th sec and on, but what actually happens is that it may start between sec 17-19 randomly thus changing the global rythm of the music.

This is the code where I add the differents instruments:

Code: ags

//Im combining a struct with array to store the imuse instruments
#define MAXINSTR 10

struct type_instrument{
  AudioClip* Clip;
  AudioChannel* Channel;
  bool waittoplay;
};

type_instrument instrument[MAXINSTR];

//To add and instrument, i change waittoplay to true (and change other less important stuff too), then i do this in repeatedly execute:
function repeatedly_execute()
{
  int NewClip = 0;
  while(NewClip  < MAXINSTR){
    if(instrument[NewClip].waittoplay){
      //search a Clip Playing and store the position
      int position = 0;
      int counter = 0;      
      int clipplaying = 0;
      while(counter < MAXINSTR){
        if(instrument[counter].Channel)
          clipplaying =  counter; 
        counter++;}
        position = instrument[clipplaying].Canal.Position;
      //then, play the clip in that position 
      instrument[NewClip].Channel= instrument[NewClip].Clip.PlayFrom(position, eAudioPriorityNormal, eRepeat);


Here is a sample, using the same instrument 2 times:
http://www.mediafire.com/?lzimgw33ozw
(In this demo i use position-300 in playfrom,  for a minor lag time)

Try walking to the green region, that lag is not always equal.


Thanks for your time
Nahuel36
#6
WOW, GREAT!!!

NowI'm doing and testing a IMuse module

I'll informate any bug  I find



EDIT:
the simultaneous reproduction works fine with ogg, but its not suported by midi, will you implement this feature in some future releases?




thanks
#7
Hmmm, no, that's not the problem I'm referring to.
You have to listen exactly the first time that changes. It's when the instruments' volume changes, once it changes it stays like that.
Mainly, at least in this case, the percussion's volume change is noticed, it's louder than the others. It wasn't like that originally.

If you still can't hear it, I can send you a wav with the exact moment recorded, but that's the idea; listening carefully during the beginning of the midi, and then go to the other area and listen.
I don't know if you can fix this or if it is a library problem, but I hope it's possible.

Thanks
Nahuel36
#8
ups, sorry
in that version we are trying to use ogg

this is the original version made in midi, with the bug
http://www.megaupload.com/?d=OTU7NS87

#9
 We don't know why, but the uploaded files only work if you download them from other browsers rather than Internet Explorer.
By the way, here is a mirror

http://www.megaupload.com/?d=JY9MV0BZ
#10
Ok, thanks for the answer. But I think that something is not clear. The bug is not that there isn't a multi track support, it's the instruments' volume change. That's why I uploaded the demo.


Quote
There's an AGSMuse module that emulates Imuse, the module is made by Monkey0506

Linky:
http://www.adventuregamestudio.co.uk/yabb/index.php?topic=28933.0
I know, that plugin does exactly what I am doing, and the mistake I'm explaining also happens.

Thanks guys
#11
We are trying to simulate Imuse on AGS.
Imuse is, for example, what happens on Monkey Island 2 while you´re walking by the wharf (and then you go to see the carpenter, Wally, etc.) where the game starts. The theme changes without altering the main melody.

As, actually, it´s not able to reproduce more than one midi at the same time. What we do is to use several midis at same times, and change from one to another using getmidiposition and seekmidi.
The problem is that during that change, the instruments´ volumes are badly heard, they doesn´t load on time, and then the change isn´t good.

I wonder if, maybe, on the next version or in a nearby future, you can fix that error or make AGS able to reproduce more than one midi at the same time.

www.groggames.com.ar/proyecto/imuse.zip

In this exaple, the same midi is used for the 3 areas. But  that is of no interest, what matters is how the instument's sound changes. If you go to the white area the sound stops and when going to the colour area the sounds will start fine. Then when going to another area the instuments will be heard with other volumes.

used in Repetaedly Execute of Room:
Code: ags

Region *reg= Region.GetAtRoomXY(player.x, player.y);
  if(GetCurrentMusic() != reg.ID)
   if((GetMIDIPosition()%4 == 0)||(GetCurrentMusic()==-1))//only change when a compass ends
      {
      int pos = GetMIDIPosition();  
      StopMusic();
      PlayMusic(reg.ID);
      SeekMIDIPosition(pos); 
    }



Thank you, Nahuel36
#12
Quote* The script would have no concept of Sound Channels. Instead, AGS would use the Priority setting of each Audio clip to destroy an existing lower-priority sound if it ran out of channels.
However, the audio.Play() method would return some sort of Channel/Sample object that you would be able to use later to adjust the volume or stop the audio.

Then,  to play a sound,  we'll use audio.Play(), but to stop or adjust volume we'll use chanel[ x ].Stop.
Then... we will need a command that returns the channel where an audio file is playing,
or -1 (or 0) if the file isn't exist or is not being played.


----------

Also, it would be useful to reproduce midis from files, during the game, such as it is able to load a bmp or pcx image with DynamicSprites, now that i´m making a tool for the creatives of our group.
#13
hi!

We are using a Tool that i've made in AGS. In this tool we can add image files for background, and play MIDI files too, but only if they have the name "music1.mid", or "music2.mid", etc.
I think that a playmusicfile("nameoffile") , compatible with MIDI, would be a great add.

thank you!
#14
I'm very sorry for this, sinceraly, because every times I tried my games or I played other projects in my Linux, I was saying: who was the person that port this to Linux...? He must be great. Much users enjoyed your port, I think, as I did.

For this, I want to tell you reasons and solutions for your work continue helping these linux users. About from the library, I think that SDL can resolve your problem. It's got a librery of help that it gives support to videos in differents formats, Moreover, it isn't difficult to program (knowing allegro), and the license allows don't release any code only with the prohibition of profit.

The plugins is another item, in my humble opinion. I think it's typical of the developers, make their own plugins, or port they and distribute. For these, there is a extense comunity in Linux and Windows.

From distributions, don't worry. With a deb file from Ubuntu, I will suffice to make packages for every distributions. I offer to collaborate with it.


Well, I think decision is all your. We can't more that influince it. We are waiting that you decide continue with the port, and thus, do happy much Linux users.


Thanks for your time
Nahuel36, GrogGames Programmer


PS: Sorry for my english. I speak spanish
#15
Quote from: subspark on Fri 09/05/2008 02:49:46
No need to be smart. I seem to be a bit confused though. :) What's this screenshot displaying from the Mac thread?
Is this not the editor running on a Mac?

Naturally, I assumed GrogGames was using this version.



Cheers,
Paul.
No, I am using XP with a personalized style called LeopardXP, its very cool


I don't understand why, but I tryed choosing the classic style and returning to the personalized, and it's worked. I don't know if it was the reason or not, but dont worry be happy   ;D
#16
Quote from: Pumaman on Fri 02/05/2008 20:38:57
Quotei have this error when i try to run the editor

Are you saying that 3.0.1 works but the 3.0.2 beta doesn't?
I think you get this error if the msvcm80/msvcr80.dll files are missing -- you did un-zip the whole ZIP and not just try and run the editor out of it, right?
I unziped the whole Zip. The dlls are in the folder.
#17
i have this error when i try to run the editor


I am using Windows XP Service Pack 3,  with .Net Framework 2.0
i dont know if this would help you,  but there aren't other anormal things. I hope yes
Ags 3.01 runs perfectly

Thanks!

PD: Sorry for my crappy english,  again,  i speak spanish




#18
(i don't speak english very well, I'm from argentina, sorry if you don't understand)

I get this error in our game

Code: ags
Error: Index was outside the bounds of the array.
Version: AGS 3.0.1.28

System.IndexOutOfRangeException: Index was outside the bounds of the array. ---> System.IndexOutOfRangeException: Index was outside the bounds of the array.
   at AGS.CScript.Compiler.Preprocessor.RemoveComments(String text)
   at AGS.CScript.Compiler.Preprocessor.Preprocess(String script, String scriptName)
   at AGS.Editor.AGSEditor.CompileScript(Script script, List`1 headers, CompileMessages errors, Boolean isRoomScript)
   at AGS.Editor.AGSEditor.CompileScripts(Object parameter)
   at AGS.Editor.BusyDialog.RunHandlerOnThread()
   --- End of inner exception stack trace ---
   at AGS.Editor.BusyDialog.Show(String message, ProcessingHandler handler, Object parameter)
   at AGS.Editor.AGSEditor.CompileGame(Boolean forceRebuild, Boolean createMiniExeForDebug)
   at AGS.Editor.Components.BuildCommandsComponent.CompileGame(Boolean forceRebuild)
   at AGS.Editor.Components.BuildCommandsComponent.CommandClick(String controlID)
   at AGS.Editor.ToolBarManager.ToolbarEventHandler(Object sender, EventArgs e)
   at System.Windows.Forms.ToolStripItem.RaiseEvent(Object key, EventArgs e)
   at System.Windows.Forms.ToolStripButton.OnClick(EventArgs e)
   at System.Windows.Forms.ToolStripItem.HandleClick(EventArgs e)
   at System.Windows.Forms.ToolStripItem.HandleMouseUp(MouseEventArgs e)
   at System.Windows.Forms.ToolStripItem.FireEventInteractive(EventArgs e, ToolStripItemEventType met)
   at System.Windows.Forms.ToolStripItem.FireEvent(EventArgs e, ToolStripItemEventType met)
   at System.Windows.Forms.ToolStrip.OnMouseUp(MouseEventArgs mea)
   at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
   at System.Windows.Forms.ToolStrip.WndProc(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

i am using the module Scrolling Dialog 2.0 Beta ,  i don't know if that is related with this error. But in Ags 3.0 don't happen.

thanks!
SMF spam blocked by CleanTalk