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

#101
Hi I am trying to make like a whack-a-mole game in my game. The player is trying to catch a crab. I really want it to appear random to but haven’t gotten so far jet.
This is my problem, after the player catch the crab it is still visible on the screen?
This is my code:
Code: ags

function room_RepExec()
{
  if (clock>0) {
    clock++;
  }
  if (clock==20){
    oCrab3.Transparency=0;
    object[2].Move(360, 230, 10, eNoBlock, eAnywhere);
    object[0].Move(324, 300, 10, eNoBlock, eAnywhere);
    //character[2].y = 287;
  }
    else if (clock==400) {
      oCrab3.Transparency=100;
      object[2].Move(140, 230, 10, eNoBlock, eAnywhere);
      oCrab2.Transparency=0;
      object[1].Move(448, 287, 10, eNoBlock, eAnywhere);
      
      //character[3].x = 448;
      //character[3].y = 287;
      
  }
    else if (clock==600) {
      oCrab2.Transparency=100;
      object[1].Move(500, 300, 10, eNoBlock, eAnywhere);
      oCrab1.Transparency=0;
      object[0].Move(224, 128, 10, eNoBlock, eAnywhere);
      
      //character[2].x = 224;
      //character[2].y = 128;
      
  }
    else if (clock==800){
      oCrab1.Transparency=100;
      oCrab2.Transparency=100;
      oCrab3.Transparency=100;
      clock=1;
    
  }
  
  
}


It must be because the game check the visible in the game repeat but I must have there or?
I use 9verb and AGS 3.2

this is the code on the crab:

Code: ags

function oCrab1_AnyClick()
{
  // LOOK AT
  if(UsedAction(eGA_LookAt)) {
    player.Say("Its a crab with catching claws");
  }
  // OPEN
  else if (UsedAction(eGA_Open)) {
    Unhandled();
  }  
  // CLOSE
  else if (UsedAction(eGA_Close)) {
    Unhandled();
  }  
  // USE
  else if(UsedAction(eGA_Use)) {
    Unhandled();
  }
  // Push
  else if(UsedAction(eGA_Push)) {
    Unhandled();
  }
  // Pull
  else if(UsedAction(eGA_Pull)) {
    Unhandled();
  }  
  // PICKUP
  else if(UsedAction(eGA_PickUp)) {
    player.Say("Finelly");
    oCrab1.Visible=false;
    cEgo.AddInventory(iCrab);
  }
  //USE INV
  else if(UsedAction(eGA_UseInv)) {
    Unhandled();
  }
  // don't forget this
  else Unhandled();
}

#102
I like the white one most. If you go for a coffee mug the logo could be on the mug itself. I also think that maybe the "waves" on the "New Game Wizard splash should be behind the mug".
But all the pictures looks great! :)

#103
Thanks!  :D
#104
Hi, does this modules still exist?
#105
Thanks. I put that line in Game_start and it works now!  :D
#106
Hi
Trying out this template and I have one embarrassing problem.
How do you make cEgo clickable (the player)?
Like if I have an apple in inventory that I want him to eat.

I have tried with the same script as Bman but it dont work...
#107
Thanks it was the missing brackets that did it!  :D
I knew it was something simple  ::)

(Off topic, is it only me that’s having trouble logging in to the forum this week?)
#108
Hello
I need help with Global variables, please. This is the first I have made.

I have made a global variable named Hunger (int) with a value of 100.

In function room_RepExec() I got this code:

Code: ags

function room_RepExec()
{
  if(Hunger>150)
  cEgo.LockView(3);
  cEgo.Animate(0, 5, eOnce, eBlock);
  Hunger-=50;
  cEgo.UnlockView();
}


Now I want the player to do a animating if his hunger is greater than 100 and the stop. But as soon as the game starts the player starts walking and hunger is counting down.
If I put:

Code: ags

function room_RepExec()
{
  if(Hunger<150)
  cEgo.LockView(3);
  cEgo.Animate(0, 5, eOnce, eBlock);
  Hunger-=50;
  cEgo.UnlockView();
}


… the player does the animating endlessly and hunger is counting down. What do I wrong?

#109
Ok, thanks! :)
#110
I´m a little confused over  XNA, do I need to own a Xbox 360? ???
#111
Thanks all for your answers, as I feared there is a lot of different things to think of.
I been looking at different game engines like Unity but I see there is a lot more out there. Thanks for the links.

I really love AGS but it feels like it’s not build for making games like those I mentioned earlier and even in AGS I feel that if I want to make more advanced game I will have to learn to script.

I think to that I should start with a 2D games and a one that’s free, as long as the fees don’t get too big.  ;D

ProgZmax, that something to think of as well. But still to have someone to ask is a great help too.

Still, sounds like most of you say C# (don’t know XNA â€" have to look that one up)


Thanks for all help!!! (off to the bookshop we go…)
#112
General Discussion / Which language to learn?
Mon 20/09/2010 12:52:33
I have had an idea for a game for a long time. Now I have come to understand that I can’t do it without learning some programming.
But I don’t know which I should choose?

I understand that this game I thinking of will take a long time to make and that it probably never will be finish but that’s ok, I just don’t want to start with one language only to figure out that I can’t make it with that one.

To give you an idea; I’m thinking of a virtual world game. I want time to past in the game affecting the world: crops growing, people to have hunger and thirst, day and night. Think the Settlers, Sims and Civilization.
Someone will probably say that why don’t I go and play Runescape but that one like many of those games are really just about fighting and I want a game about growing and making things. And it would be fun to make it myself.

My brother works with flash and he think I should learn that as he can help me with it but as far as I have seen there is no game like the one I want to make with flash (?)

It would also be fun if it could be a game you could play over the internet.

Anyone care to point me in the right direction, please?
#113
Thats good news!  ;D
#115
Completed Game Announcements / Last Order
Tue 04/05/2010 10:02:03
Hi
Now is my second game ready. It’s just a small game for some people I know at my local pub but I hope that some of you will like it too.
Please leave comments if you play it so that I can improve on my game making until next time, thanks.

The story: You are on your way home and you are dying for one last pint before you go home. Just as you are going through the door you hear the last order bell ring, will you get one in time?



Link to download:

Last Order.rar

#116
Downloaded, trying it out now :)
#117
Quote from: Khris on Sat 10/04/2010 11:13:16
Just to elaborate a bit:

You can use
  if (!player.HasInventory(iRubberband_1) && ...
(Note the "!", signifying "not")

Alternatively, .InventoryQuantity needs an int as index; you can get that by appending ".ID":
  if ((player.InventoryQuantity[iRubberband_1.ID] == 0) && ...


Aha, so it was the "ID"and the right int that I was missing. Good to know for the future, thanks.
#118
Thanks! that worked for me!  :D
#119
Quote from: Dualnames on Sat 10/04/2010 10:43:16
You can replace this with:


Code: ags


function room_RepExec()
     if    ((player.HasInventory(iRubberband_1)) &&(player.HasInventory(iRubberband_2)) &&(player.HasInventory(iRubberband_3))) {
           player.ChangeRoom(8, 0, 0);
     }


But isnt that if the player got all things? I want the player to change room when he loose all the 3 items.  ???
#120
Once again I come to you all with a easy problem that I can’t solve. :-[

In my game the player starts with 3 things. When he has loosed all items the game is over.
But I gets this: Error: type mismatch: cannot convert ‘InventoryItem*’ to ‘int’

This is what I have tried:
Code: ags


function room_RepExec()
if ((player.InventoryQuantity[iRuberband_1]==0)&&(player.InventoryQuantity[iRubberband_2]==0)&&(player.InventoryQuantity[iRubberband_3]==0))
 {
   player.ChangeRoom(8, 0, 0);
 }



When that didn’t work I put in
Code: ags
 
// main global script file

int player.InventoryQuantity[3];


but that didn’t help. :(


SMF spam blocked by CleanTalk