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 - Baron

#2821
Quote from: Trademark on Tue 19/10/2010 16:13:19
After a bit more digging I made a text window box, but those seem to only apply to text that uses Display, not Say, nor does it take effect on dialog. Using Lucasarts like I said before. How do I make it apply to text that uses Say to display as well?

You will probably have to create a custom function to replace Say.  This sounds hard, but once you've written the function it will be just as easy to implement as Say.

I have sort of the same thing in one of my projects.  I have Sierra speech, but I wanted this frog character to speak Lucas-Arts style, so I had to do the speech manually.  I wrote this function in my global script, exported it, and imported it to all other scripts through the .ash script header:

Code: ags
function frogtalk (String frogsays){ //the String frogsays replaces the string in Char.Say ("...")
 short frogwords = frogsays.Length; // a variable that records the length, in characters, of what the frog will say
 short textposition; //where will the text be on the screen (y value)?
 short text_x; //how far the box should migrate to stay close to the talking frog
 short textwidth; //how wide will the box be?
     if (frogsays.Length < 40) { //i.e. it's a short statement less than 40 characters long
              textposition =280;  //the height, above the character
              textwidth =frogsays.Length *10;  //multiply number of characters  by 10 (10 pixels per letter -seems to work) to get adquate text box width
              text_x = 400 - textwidth;  //moves the box over by a an amount dependent on how long the speech is, so that it stays next to the character's head.
      }
    else {  //if what the frog says is more than 40 characters long...
              textwidth =400; // effectively the maximum textbox width
              text_x =0; // the box doesn't have to move sideways (in my game), but it's still at 200 (see below)
              textposition = 280 - (frogsays.Length/4); //a formula for determining how far up to move it above frog's head.
      }
 cFrog.LockView (5); 
 cFrog.Animate (0, 0, eRepeat, eNoBlock); //a talking animation, without the talking
 cFrog.SayAt (200 + text_x, textposition, textwidth,  frogsays); //get string length +20...? //moves the INVISIBLE speaking portrait (remember Sierra style!) to next to visible character on screen.
 cFrog.UnlockView (); //stops frog from animating mouth after speech is over
}


Now I just write frogtalk ("I talk like a frog!");  and it looks just like the frog character is talking in place.

Now I'm no expert coder so this is just to give you ideas.  Obviously if you wanted to implement a multi-character text-box style talking bubble system you'd have to make this code more flexible (another variable at the top that relates character name or number and then reference it throughout the code so different characters can be called).  You'll need to dynamically change the textbox corners into speech arrows.  Also, moving characters would have to be taken into account with coordinates relative to character's positions (cFrog.x -150 instead of the absolute coordinates I could get away with), and you'll probably have to have several different scenarios depending on the speaking characters' locations on the screen (i.e. if they are too high on the screen you'll need to put the bubble below them, or if they are too far to the right the bubble will have to go the left, etc.).  But once you get that all into the function it will work much as char.Say when you need to call it from your scripts.
#2822
Quote from: Sslaxx on Wed 20/10/2010 17:47:18
Surprising that, given CJ's clear antipathy to open source, that he does not appear to have considered the opposite option - going commercial.

So. If he did decide to, say, set up a Blue Cup Ltd. to develop and support AGS as a commercial product, how many of you would buy it?

Quote from: Joseph DiPerla on Wed 20/10/2010 18:27:28
I would buy every update when its released... Even though I havent made a game, I am determined to one day do so. Buying and paying for AGS will motivate me further. I am willing to pay around $30 to $60 and $25 for each upgrade.

Quote from: abstauber on Wed 20/10/2010 18:57:17
Yeah, even though I would pay, I don't know about all the students and other poor people.

If AGS has to make money, I suggest selling a snob pro version that compiles games for smart phones :D

Clearly the appeal of AGS is its price ($0).  I don't think you can argue that the community would be as strong or the amazing games made with it nearly so numerous if you had to pay at the gate.  And if proliferating the genre and midwifing great adventure games into the world isn't the point of AGS, what is?

Having said that, the market potential for an "elite" version somewhere in the neighbourhood of $25-30 is probably sufficient to allow CJ to dedicate some work time (rather than leisure time) to AGS -pending the necessary flexibility in his current work arrangements, of course.  It would be hard to quantify the market precisely but there are 103 WiPs commented on in the forums in the last 6 mo. and reasonably an equal or greater number of projects that are unadvertised by their developers.  Add to that the folk that always mean to start a game or like to play around with the latest stuff and you might have a market of 300-400 per upgrade cycle.  We're not talking huge money here, but enough to justify the time spent.  Sexy upgrades (editor skins! Live in-editor chat!) may well increase the market.

A happy medium may invovle charging for new upgrades, but the upgrade version becomes free as soon as the next upgrade is released (and so on).  That way we keep our wonderful community of starving artists and starving students (with software 6 mo. to a year out of date), while the more serious developers (and those artists and students who can exercise enough self-discipline not to go to the bar for one night and save the $25...  ::) ) can play with the latest features.  This scenario also motivates CJ with a small amount of additional income, possibly replacing part of his work-week.  Heck, he could even get all capitalistic and farm-out some of the scripting grunt-work, leaving him with absolute control,  more spare time, and of course all the money.  Ah... the system works.
#2823
Quote from: ProgZmax on Mon 18/10/2010 20:32:45
Well, this has always been your baby and I'm well aware of how difficult it is just to release the source on it, so instead of doing that why not something like this:

1.  Form a panel similar to the ratings panel, made up of 6-7 senior AGSers that you trust with appropriate programming experience and interest.


     ProgZ had me at panel -I think there should be a proliferation of panels!  That way the community can take more ownership over itself.  If you think about it, most of the following ideas have been taken up by individuals at one point or another, but many have sputtered through lack of "succession" schemes.  The beauty of panels is that if an individual gets burnt-out there are other people around to carry on.  Some ideas:

          Ratings panel (existing)
          Source Code panel (proposed)
          Wiki panel
          Manual panel
          Demo game panel (existing/has existed, at least informally)
          Recruitment panel (anyone else noticing declining newbie numbers in the stats?)
          Training panel (creating web seminars/tutorials for best-practices, new features, gaps in documentation...)
          Pimping panel (to promote AGS and AGS games around the net)
          Mittens panel (facilitating organization)
          Worship panel (keep CJ's cult going strong)
          Newsletter panel
          Death panel
          Web Page panel
          AGS Awards panel (maybe organizing, maybe acting as an academy to judge....)
          Orphans panel (to find level-appropriate projects for interested members)
          Arch panel (a panel to oversee the other panels and bring them to heel if power goes to their heads)

      Yeah, some of the above are jokes, but seriously I've seen a lot of initiative in some of the above fields that simply can not be sustained by individuals alone over the long term.  Also, the more that we can defray CJ's workload the more he will be able to devote his limited spare time to what he does best -ensuring AGS is the awsmoest!
         
         
         
#2824
I agree with Theo's point about planning -the easiest way to winnow down the work load is to trim unnecessary work in the planning process.  A few clever short cuts, like mirror-able sprites or recyclable poses (reaching pose gets added to dance animation, for example), can really cut down on work.  Also a well-placed message or single picture cut-screen can still enrich the gaming experience without the intensive man-hours required by animation.

Having said that, you seem to have put a lot of thought into the project already and you thought the game would be richer for the 37 animations.  I don't  think 130 odd hours is an unreasonable amount of time to spend illustrating what will be a medium length game.  Pixelating sprites in MSPaint from scanned images is a bit of a pain (I'd monochrome the scans first, then switch back to your proper colour depth to save "cleaning", if possible), so that might increase that portion of the work load.  But already having a good idea of what you're doing will save all kinds of "Waffle Time", as I call it.  Also, with small sprites to animate at 320x200 you should have no problem keeping work times down with a little discipline (i.e. avoiding Theo's "Tweak Trap").  Furthermore, the funny thing about animation is that the more you do it, the faster you get (especially when it is the same character), so the marginal cost of doing more animation is less for each additional animation.

The only way I'm coming out of this with a sense of closure is for you to make the game and then report back your actual work hours.  The rest of us will start up a pool via PMs to make it interesting.
#2825
Quote
So here are the statistics as they are at the moment:
14 BGs
23 Sprites
37 Animations


So with the given statistics and above info, how long would such a game take you to create into a fairly polished product ready for play?

With distractions? (kids, work, etc...)
Without distractions?

Also, how many of you plan the statistics out beforehand?

Are distractions (kids, work...) optional?

It's truly hard to say how long it might take, as everything is contingent on the level of detail.  Is this a 320x200 game, or something high res?  Are you doing bitmap graphics or vector drawings?  Realistic style or cartoony?  Shading or flat colours?  Etc., etc.

But since you ask how long it would take me, I'll hazard an estimate.  I've been keeping track of my time spent on projects lately so that I can plan better, and I've become quite a bit better at it over the last year or so.  But, since I believe that work should only take as long as the time available for it, meeting my self-imposed deadlines might just mean I've sacrificed quality for predictable productivity.

14 backgrounds = 14 nights.  For me a night can be anywhere from 2-4 hours, depending on the health of my daughter and how much sleep I think I can get away without.  I never have the will to do anymore drawing after a background, but the thrill of finishing a BG usually gives me enough momentum to import it into AGS and set up the room so that I can test my character in it.

23 sprites = 12 hours if they are already sketched (even modestly) or at least rough models (pictures, etc.) already gathered.  So this would run me another 3-6 nights, depending.  Again, just like for backgrounds, I don't attempt a style that might be "above my level" because I know it will exponentially add to time spent.  On the other hand, if you don't have a good idea of what these things should look like, the time spent could easily double/triple. 

37 animations = 74 hours (very dependent on style, though).  Truthfully, most of my animations nowadays take 1 or 2 hours, but something complex (like a fighting yoda) or something that will be seen a lot (like a walkcycle) will take me several nights (10 hours min.).  If you can recycle most of a sprite each time that will really speed things up, but redrawing entire sprites, while rewarding to look at if done properly, really takes a lot of time.  So just a moving hand to "take" something I'd budget at 1/2 hr., but a bending over to pick something up could take 2hrs because of the body contortions. 

So graphically I have your game coming in at 128 honest work hours (distractions not included), or approximately 43 nights (at 3 hours a night).  Coding, debugging, importing, fiddling, music, sounds, dialogs, etc. etc. not included.

The depressing thing is, I would never have done some of (what I would consider to be) my better AGS work had I conducted this kind of exercise prior to plunging in.  Sometimes it's better not to know.  But as time becomes more of a precious commodity I find it helpful to know that what I've undertaken is feasible in a reasonable amount of time -otherwise, I probably wouldn't start at all now.  The best advice I could give you if you truly want to know ahead of time how much work will go into a project is to start keeping track of your time.  With each drawing you will gain a greater understanding of how long something will take you to do.  Since only you work like you, anyone else's estimates will only be rough approximations.
#2826
Quote from: bicilotti on Thu 07/10/2010 18:23:42

Not sure, but my productivity at work went up by a whopping 10e5%.

My productivity at home went up, too....  Maybe this could be incorporated as a "feature" in the new website?  You'd check a box saying "currently working on a game" and then your IP would be added to a list which would make the forums randomly inaccessible to you.   
       At any event, I predict either a glut of newly completed games or babies will be brought into the world nine months from now.
#2827
Well, what's going on here, then?  It sure looks like they're playing around with alpha-channels on GUI buttons, but having said that it doesn't seem to work for me when I attempt to employ the methods described.  Can anyone definitively clarify where AGS sits in terms of alpha-channels on GUI buttons as of version 3.2?
#2828
I've seen various threads (example) that purport to have solved this issue with using an alpha channeled GUI background.  Your background looks like it might have an alpha-channel, but it's hard to tell with the white border against the light blue background of the post.

     At any rate, I've also had no success in getting alpha-channel buttons to work on GUIs, so I'm afraid I can be of no further use.  I'd be very interested in seeing where we've been going wrong, though, since it does seem that some people have figured this out.
#2829
I'm ba-a-a-a-ck!
        I'm having a hard time with my speech setup.  I've tried various options out and I think the Sierra style with background will work the best with my game.  What I'd really like to implement is a speech bubble-esque arrow coming from one of the corners of a text window GUI to show the character talking, but I'm having problems actualizing this desire.  It seems like the Sierra-style portrait is "locked" to the top of the text-box, presenting a continuity problem in placing the speech bubble arrow.  If I put the arrow in the upper left corner then it looks like speech is coming from my character's head and not their mouth.  If I put the arrow at the lower left corner then the arrow can easily miss the mouth depending on the length of text displayed.  I've experimented with SayAt, trying to set the text location dynamically using GetTextHeight so that the bottom arrow will always point to the mouth, but instead SayAt moves the text AND the portrait -they seem to be locked together.   Is there a way to set the location of each element (the portrait, the text window) separately?  It doesn't have to be dynamic -I can use the top corner permanently if I could nudge the text lower relative to the portrait.

       Also, when using the "Alternate" option (so portraits appear on different ends of the screen when conversing), is there a way to change the text window gui on the fly so that the corner graphics can be switched around (or at least entire GUIs switched)?

       Thanks for all the help and ideas.
#2830
Thanks for the ideas Leafshade.  I tried the phantom character and didn't like the effect, so I've adapted your idea slightly:

Code: ags

function charturn (){ //turns the player frontwards on Walkto mouse click (or manually for Blocking event)
 int absy;
 if (mouse.y < cplayer.y) absy = (mouse.y - cplayer.y) *(-1);
 else absy = mouse.y - cplayer.y;
 if ((cplayer.Loop ==1)&&(mouse.x>cplayer.x) && (mouse.x -cplayer.x > absy)) {
           cplayer.Loop =0; 
           mouse.DisableMode (eModeWait); 
           Wait (5); 
           mouse.EnableMode (eModeWait);
  }
}


   This is called right before processing left-click if Walkto mode is enabled, and works well with "turn player character" turned on -I'm happy with the feature except for the left-to-right turn.  So, this function turns the character forwards if she is facing left but is likely to go right (and the turn player character does the rest).  It works perfectly, except my cursor flickers to wait when the turn is in process.  No matter, I thought to myself, I'll just disable it temporarily while the function runs its course, but no!  The cursor still flickers to the hourglass despite that cursor being disabled!  I'm so close -any ideas?

EDIT LATER THAT DAY: Nevermind, I've solved it by switching the Wait cursor graphic to the currently used one (probably walkto, but who knows) and then back.  Thanks for everyone's help!
#2831
QuoteI'm not bbuying a car though, so I'll be needing a form of transportation. One that'll last for some time too.

But.... But.....  A car has thousands of very complicated, very sophisticated parts!  A bicycle I can take apart and reassemble in a day!  Why would you, in a moment of sanity, ever consider spending $499 on a very simple piece of transportation technology?  My advice is look around: police auctions, garage sales, classifieds or online trade sites (Kijiji, Craig's List....), and find a decent used bicycle.   You can't tell me a $499 new bicycle runs 5x as fast or will last 5x as long as a $99 used bicycle (which is still too pricey, but acceptable if you don't want to do any work on it).  Unless you have money to throw away, I would not spend it on an overpriced bicycle.
      I guess if you were into biking down mountains or into tour racing you'd want the most up-to-date features, but just to get to work and back?  I biked the whole winter of 2003/2004 to work 8km away (in Canada) on a $30 bike - and I still use it!  Just keep it greased and it'll be fine.  Spend the other $469 on attending Mittens or impressing your girl or donating to the Snakes of Avalon Team -anything! 
      But I've said my piece -if you're really set on getting that top-of-the-line bike then I guess the wild rantings of some internet guy aren't going to dissuade you.
#2832
Well, gears are hard to diagnose online, but your wheel is just out of true.  If you get a spoke wrench you just need to tighten/loosen spokes until they pull everything back in line.  To test the line you need a straight line that doesn't hit the axle between the two sides of the rim -there's a special tool for this, or you could just rig a 2x4 with some blocks.  The trick is to rest it on the axle so that the blocks on the edges just touch the rim, then spin it to see where the rim is out of true.
      But I see your point -once there's enough wrong with a bike/car/computer, etc., you're probably better off to cut your losses.  But $499?  Seriously?  That's more than I paid for my first car.
#2833
I thought the game was about "lancing" penguins....  But then I live in a place where clubbing seals is considered normal.  :-\
#2834
I've seen this using 3.2 with XP.  I had checked the "make compatible with Game Explorer" box in general settings.  When I rebuilt my game it would sometimes come up with an error message, sometimes not.  When I unchecked the general settings box it would still give the error occasionally, but after I shut down the engine and reopened the game files it hasn't come back.
#2835
New tires, tire irons and air pump: $30 max, cheaper if you look around.  New chain, or chain link removing tool + white grease: $20 tops.  Brakes just slow you down, and bikes are made to GO!  But seriously, are the pads broken or wires snapped or something?  All of that can be fixed/replaced without too much trouble.  Any decent small-time bike shop will sell material/tools to you at decent prices, or even hook you up with used parts from wrecks they've inherited.
    I would never spend anything like $400 on a bike.  The only bicycle I ever purchased was for a cool $20 at a police auction -they usually have these 1-2 times a year to get rid of all the bikes they've seized from bike thieves (owners don't come forward or can't identify bike if it's been painted, etc.).  I say find a cheaper bike, and save your money for small-time indie adventure games!
#2836
@Calin: Thanks for the pointers on.... pointers.  You are correct to assume that I'm not yet entirely comfortable in their use and I did find your example educational.

@Dualnames: Yes, I will definitely use pointers where possible, but I don't think this is an instance where they will be.  As I understand it from Calin's post, pointers point to specific memory, but I really do need something that can store variable information.  So I think I'm doing my inventory system numerically this time around.  Thanks for all your help!

#2837
Khris definitely clarified how to use a pointer in a function, and I'd like to do it that way if I can iron out a few wrinkles.  Thanks.

Quote from: Dualnames on Fri 24/09/2010 11:55:47
Khris is definitely showing the way, if you still want to do it otherwise..

Code: ags

function Baron(String item) {
int i;
  while (i != Game.InventoryItemCount) {
      if ((cplayer.HasInventory(inventory[i]))  && (item == inventory[i].Name)) {
            cplayer.AddInventory(inventory[i]);
       }
  i++;
  }
}


If the player.HasInventory(inventory[i ]), why must cplayer.AddInventory(inventory[i ])? 

        Otherwise this is similar to the workaround I was using before -but it is still basically numeric (i is an int).  How do I take a String, which saves a specific item's name, and make it useful for the code again?  In ActionScript I can reconstruct variables by adding Strings together: "String"+"_01" can be read as variable Baron_01 (if String held the characters "Baron"), but AGS doesn't want to recognize my inventory script names if they are saved in Strings.  For example, String invslot1 saves the inventory name of the inventory item at InvMain.ItemAtIndex[0].  That item will change through the game when the original item is used (and lost), so I want to keep track of it with a variable.  Not only that, but "slot1" could rotate depending on what inventory is being viewed, so I really would like to keep track of this data as a versatile variable.  Anyway, in AGS I will get an error if I use invslot1 as a String here:
Code: ags

if (Mouse.Mode == eModeInteract) player.ActiveInventory =inventory[invslot1];


      But when invslot1 is an int (or char, actually), I can save the number and plug it back in to other code easily:
Code: ags

if (Mouse.Mode == eModeInteract) player.ActiveInventory =inventory[invslot1];


     Everything works, except I have to remember the inventory items by number (not a huge deal).  What I really want is to be able to use a String variable to record an inventory item pointed at -so I can remember what it is - and then be able to use that data usefully again in the script.  Is the solution to make invslot1 (and all the other slots) into pointers and use them like variables?  Is this possible?



     
#2838
Hi Again,
      I've upgraded to AGS 3.2 and I'm having a hard time making a function work.  It's my only function so far, and I'm a little rusty at this sort of thing, but still.... I used to be able to do this stuff.  I get the error mentioned in the subject line when my function is introduced.  Research gives me only this thread , which doesn't really seem to resolve anything.
      What I am trying to do: I have a "phantom inventory" that I'm using for the sake of it's built in index, while my function sorts inventory graphics according to their order in the index elsewhere.  But the error seems to occur right at the beginning of the function, so maybe I'm doing this in an outdated fashion.  Here's the error line:

Code: ags

function increaseInv (String item){


      I'm sure it's simple, but what am I doing wrong here?

--------------
Edit: Alright, apparently my "import function" statement in the header script was being interpreted as a declaration.  I'm off to figure out how the heck to use that header properly, but I've got a new error to work with:

GlobalScript.asc(17): Error (line 17): Type mismatch: cannot convert 'String*' to 'InventoryItem*'

In this line I am trying to dump the name of the inventory item just interacted with into an AddInventory command:

Code: ags

function increaseInv (String item){
  cplayer.AddInventory(item);


The error message clearly states that this is not possible, but I'm having a hard time figuring out how I can construct something similar (i.e. a variable that can save the inventory item I'm working with).  Must I resort to working with inventory items by number the old fashioned way?  Or is this InventoryItem* some sort of new syntax that I haven't figured out?
--------------------
Edit Again: Well, I can get it to work using (int item) instead of (String item) and some new syntax:

Code: ags

function increaseInv (int item){
  player.AddInventory(inventory[item]);


But I'm still not happy about having to use ints instead of Strings.  So one specific question:

1) How can I set a String variable to (or Pointer to?) an inventory item's name so that I can reference it in a function elsewhere?

#2839
Every now and then I get a little bit tired of listening to the sound of my tears.

But seriously folks, to the problem at hand.  I think I've found Leafshade's solution posted on the forums -I can't find the thread right now, but wasn't it something to do with a phantom player sprite which the visible player would follow?  This strikes me as a quick fix that might end up causing unforeseeable complications down the road in the development process.  So is the consensus that the clockwise turning is hardwired and there's no easy way out of this?  Maybe we'll just try it without the turning and see how it looks.
#2840
When using "characters turn before walking", is there an easy way to ensure that the character always turns towards the screen (frontal view) rather than away, unless the character is actually turning to go backwards?  For example, my character faces left, the walk icon is clicked, and then she moves right by turning away, instead of towards me.

SMF spam blocked by CleanTalk