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

#1
Quote from: Pablo on Mon 26/02/2007 07:55:38
If I'm wrong you can slap me back.

Slap, Slap, Slap!
#2
I just absolutly love these two games!!!
I laughed my head off when I played these!  ;D
What's your opinion?
#3
Yes just for refrence.
I'll fix up ccMer1.
It doens't have a closing brace because there's more code.
For Room 3, 4 and 5 and when more rooms come along I'll add more.
The room Code ends when the Talking code starts.
It all works fine  ;D

Didn't you read my reply in this thread?  :D
this thread

#4
Never mind about the timers Ashen (I needed to read the maual  :P).

When ever I am in the sam room as cMer1 He walks around, and says a randome message.

eg.
Code: ags

if (cMer1.Room != player.Room) {
return;
}
int ran2 = Random(9);
else {
if (cMer1.Moving == false) {
cMer1.WalkStraight(Random(320), Random(200), eNoBlock);
}
if (cMer1.Room == 1) {
  if (ran2 == 0) {
cMer1.Walk(0, cMer1.y, eNoBlock);
}
else if (ran2 == 1) {
  cMer1.Walk(230, 130, eNoBlock);
}

and that's how I have it for all my rooms.

For talking it's:
Code: ags

function game_start {

SetTimer(1, 80);

}
--------------------------
function repeatedly_execute {

int ran3 = Random(24);
if (IsTimerExpired(1)) {
if (ran3 == 0) {
  cMer1.SayBackground("Blah Blah Blah");
}
if (ran3 == 1) {
  cMer1.SayBackgorund("Yadda Yadda Yadda");
}
SetTimer(1, 80); //So it resets the timer to make him say it again, otherwise he'll never speak
}

You know what I'm on about don't you?
#5
Quote
1. The room borders don't work on a non-player characters. Might have to do some coding to get him to change rooms.

2. AGS has a fit when the other character is in a different room. I'm guessing this is because the walkable areas are no longer loaded so WalkStraight can't function. Might be best to not walk around if not in the same room, but randomly decide whether to appear in the player's room.

3. You might want to force the other character (at random times) to walk right up to the screen edge so that he does change rooms (once #1 is working). At the moment he wombles randomly around but seldom reaches the screen edges.

1. I use the rooms repeatedly_execute for this eg.
Code: ags

if (cMer1.x < 2) {
  cMer1.ChangeRoom(int Room, int x, int y);
}

you know what I'm on about.

2. I'm downloading one of the modules as I type for this problem.
EDIT: I found the module to hard to figure out, so this question will still be in the dark for now.

3. I know, just how?

about changing rooms that are accesed by doors:
Code: ags

if ((cMer1.x == 230) && (cMer1.y == 130) {
  cMer1.ChangeRoom(int Room, int x, int y);
}


I just need the
Code: ags

SetTimer(int Number, int Loops);

thing worked out
#6
Here I am, back with yet ANOTHER question.

How would I script a character (MER1 by the way) to wonder around the whole game world (all the rooms) aimlessly.

I tried this going for the current room with this:
Code: ags

if (cMer1.Room == player.Room) {
cMer1.Walk(Random(320), Random(200), eNoBlock, eWalkableAreas);
}

But of course he went spastic, trying to go everywhere at once.

Then I tried this:
Code: ags

if (cMer1.Room == player.Room) {
cMer1.Walk(Random(1), Random(1), eNoBlock, eWalkableAreas);
}

but he just stated walking, but not moving.

I'm completely stumped  ???
#7
EDIT: KhrisMUC's code removed - see 5 posts up for full thing.

All of this is really hard to understand, does doorx mean my own door or what.
and how this:

Code: ags
if (cWelder.Room==cEgo.Room)
 {
  cWelder.Walk(cEgo.x, c.Ego.y, eBlock, eWalkableAreas);
 }


Faulty?
#8
KrisMUC all that scripting scares me!!!

Quote

function repeatedly_execute
{
if (cWelder.Room==cEgo.Room)
{
  cWelder.Walk(cEgo.x, c.Ego.y, eBlock, eWalkableAreas);
}
if (cWelder.Room!=cEgo.Room)
{
  cWelder.FollowCharacter(cEgo, int distancefromcharacter, int eagerness);
}
if (cWelder.IsCollidingWithChar(cEgo)==1)
{
  // kill the player off functions
}
}

I'm gonna try this and see what happens.
#9
Thanx, I'll try it soon  :D
#10
How can I make two characters walk at the same time.
I mean i have two characters walking with the keyboard, one of them uses W,S,A and D, the other uses the arrow keys.
But I can't make a non-blocking script.

Little help PLZ???

(I ask too many questions don't I)
#11
Yeah Sometime 1 will play sometimes not.
My midi file is not corrupt, it plays in Quicktime and Windoes Media Player.
#12
I tried all those tactics, and it still won't play.
All my volumes are turned up all the way, my speakers are at ther max, (every little sound hurts my ears) and still the won't work.

What does this mean?:

Quote from: Ishmael on Wed 29/11/2006 13:04:07
Made sure you haven't disabled the midi device in the game setup?
#13
As I said:

Quote from: PIT on Mon 27/11/2006 22:54:58
Sometimes they won't play.

emphisis on 'Sometimes'
#14
Beginners' Technical Questions / MIDI Files
Mon 27/11/2006 22:54:58
I'm confused with my game MIDI files.
Sometimes they won't play.
It is named MUSIC1 and my game says PlayMusic(1);
but it still wont play
Does anyone else have this problem?
And could someone help me?
#15
Thanx, that worked  ;D
sorry for starting this topic, i shouldn't of been so stupid.
#16
Im using AGS 2.72 and I dont get an error, the icon is in my Compiled folder but my game .exe file is still the 2D cup icon, the Icon is a seperate file.  ???

I used Axelis (watever) liberian to compile my .ico file
#17
I am rying to make a custom Icon for my AGS game.
It is a proper .ico file but it doesn't work.
I read the manual very carfully and followed all instuctions.
Can someone help?
#18
Beginners' Technical Questions / Gun Battle?
Wed 08/11/2006 23:50:20
How would you script a bullet sprite to go from the edge of you're gun untill it hits something solid ie. a character or wall?
#19
Quote from: monkey_05_06 on Wed 01/11/2006 15:16:46
There's no need to use two labels. Just use one label and set it's text like I said before.

Yes I understand that now.
The reason the text wasn't showing up was because my label was too short.
I understand how to do the labels.
Thank-You all for your help.
#20
I want it to say Mana: #
and i want the number to corrospond with GlobalInt(2)
SMF spam blocked by CleanTalk