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

#1661
Ok I will try this.

Also I have 2 other rooms that have this edited version of the code. the first time I edited your code was in my beta room. it worked well but I was not planning on using that room any more. When I took the edited version and put it in two other rooms it worked just like how I had it the first time I used it.

I really want this to work so I am listening to you :)

#1662
Try changing the 0 - 1.
#1663
When I first used the code you gave me I could get it to work. So I tried some things until it worked. there are other fighting rooms with a enemy who has that code and it works.

Also, I do have my scripts like that so (I) understand them since I'm working on them. However ever when I post them I try to neaten them up for you guys.

Also, When I changed the script name Shiva.x/y to eye.X/y The gui shows but it just stays there until I tell it to go away.
[after battle]
or
[death to player]
#1664
It's hovering over a Object. Each enemy is named Shiva due to the fact that it make's it a lot more easier for me to code because all I have to do is change things around here & there.

Well I don't really understand that whole oat & cat thing. Seeing how monkey gave me this
Code: ags

function repeatedly_execute()
{
  Character *cat = Character.GetAtScreenXY(mouse.x, mouse.y);
  Object *oat = Object.GetAtScreenXY(mouse.x, mouse.y);
  gOver.Visible = ((cat != null) || (oat != null)); // where gOver is the name of the GUI you want to have turned on or off
}

I couldn't really get it to work so I edited it. It's been working up until now.
#1665
What do you mean by linked?

Just checked. The function is called.

Sorry. I have it like that to separate things in the script and so I remember were every thing is.

Code: ags

//Here is the code I use for the fight scenes. 


  Object *cat = Object.GetAtScreenXY(mouse.x, mouse.y);
  Object *oat = Object.GetAtScreenXY(mouse.x, mouse.y);

if(Shiva.X){
  if(Shiva.Y){
  enemyHP.Visible = ((cat != null) || (oat != null)); // where gOver is the name of the GUI you want to have turned on or off
  target.NormalGraphic = 521;// Shiva icon change
  OE.NormalGraphic = 183;
  
}
}
strengths.Text = String.Format("HP: %d", playerHP);//Menu health
    pairHP.Text = String.Format("HP: %d", playerHP);//pair health
   
   enemystats.Text = String.Format("HP: %d", EnemyST);//Enemy health

#1666
General Discussion / Re: Fancy dress anyone?
Sat 19/03/2011 05:49:38

#1667
For some reason one of my GUI's wont show in this room.

When the cursor goes over the enemy it displays a GUI
Code: ags

//Here is the code I use for the fight scenes. 


  Object *cat = Object.GetAtScreenXY(mouse.x, mouse.y);
  Object *oat = Object.GetAtScreenXY(mouse.x, mouse.y);

if(Shiva.X){
  if(Shiva.Y){
  enemyHP.Visible = ((cat != null) || (oat != null)); // where gOver is the name of the GUI you want to have turned on or off
  target.NormalGraphic = 521;// Shiva icon change
  OE.NormalGraphic = 183;
  
}
}
strengths.Text = String.Format("HP: %d", playerHP);//Menu health
    pairHP.Text = String.Format("HP: %d", playerHP);//pair health
   
   enemystats.Text = String.Format("HP: %d", EnemyST);//Enemy health



Now there is an X amount of room with fights. Each room contains this code in the Repeatedly execute area.
Each room it works in.

Another real fight room.


First beta fight.


Reason's why
The object is about as big as the room do to the animations used for it.
   - I tried setting the baseline to 200. = fail
   - I tried setting other obj's baseline to 1. = fail
   - I change the name Shiva in the script to eye(hence the eyes on the enemy) and the gui shows accept it just stays on.









#1668
That will work accept  he would have to put it in the "After room fades in" because it wont play. however,  He can make an all black gui and have it set to be visible before the video and have it set to be invisible right after the video.

I just thought I put that out there :)
#1669
Ok, but how do I do that?
#1670
Thanks. Now when I start the game it should be real easy now that thats out of the way. :)
#1671
Well I didn't really want to say the main reason cause I thought no one would help me. However I will tell you.

I might be planing to make a stereoscopic 3d game again. I want to have one chr on one side of the screen mean while I want a different character on the other side of the screen with the same view. If I can figure out that I can start the game but until then I dont think so.
#1672
So does anyone have any idea on how to do this?
#1673
Is it possible to control 2 characters with one mouse?
#1674
Wait I just thought about something. My PC shut off and the obj lost the command to do the stuff in the script yet every thing in the script was still there.
#1675
I edited the script to work with the obj. That's why I said when I take the first part of the script and copy it to the interaction area the code works.

I don't think that your a arrogant prat for saying that but I already know to do that.
#1676
For some reason I cant get the inv item on a obj. However I I can use the other command option on it like interact.

I thought something was blocking me for touch the Obj but I was wrong. The _UseInv was taking from another room which it worked in. If nothing else in the code works th "if" line + thing inside should work just fine.




Code: ags

function Shiva_UseInv()
{
  //Attack
if(Dave.ActiveInventory == com1)
{
    Dave.ChangeView(28);
    Dave.Animate(2, 3, eOnce, eBlock, eForwards);
   
  EnemyST -= 5;
   Dave.ChangeView(26);
   Dave.FaceObject(Shiva, eBlock);
  //Attack
 
  tifa.ChangeView(16);
    tifa.Animate(2, 4, eOnce, eBlock, eForwards);
 playerHP += 7;
 tifa.ChangeView(10);
   tifa.FaceObject(Shiva, eBlock);
  //----------------------------------------------------------
}
  
  if(EnemyST <= 0){
    adeath.Play(eAudioPriorityHigh); //Play death sound
  Shiva.TweenTransparency(1.0, 100);
 
  GiveScore(125);
  Shiva.Visible = false;
  HUD.TweenTransparency(0.5, 100);
  HUD.Visible = false;
  mouse.EnableMode(eModeTalkto);
  mouse.EnableMode(eModeWalkto);
  mouse.EnableMode(eModeLookat);
  gGui5.Clickable = true;
  party.Clickable = true;
    gGui5.TweenTransparency(0.1, 0);
    party.TweenTransparency(0.1, 0);
    gGui5.Visible = false;
party.Visible = false;

Dave.Say("Yeah we did it! Let's head back ok.");
//Play fanfare.
mouse.Visible = true;
Spoils.Visible = true;
qu3.Visible = false;
tifa.ChangeRoom(9, 312, 1206);
}
  //timer death---------------------------------<><><>

  
  //--------------------------------------------<><><>
  if(playerHP <= 1){
  playerHP -= 10;//player lose HP (Place here)
if(playerHP <= 0){
 CountDown.Stop();
 Dave.SayAt(8, 167, 320,"Dave:Is this it?.");
adeath.Play(eAudioPriorityHigh);
 Dave.Tint(204, 0, 0, 50, 0);
 tifa.Tint(204, 0, 0, 50, 0);
 gameover.TweenTransparency(0.1, 100);
Dave.TweenTransparency(1.5, 100);
  tifa.TweenTransparency(1.5, 100);
  aBoss1a.Stop();
  gameover.Visible = true;
  gameover.TweenTransparency(2.0, 0);
  Wait(19);
  RestartGame();
  
}
  }
}
function Shiva_Interact()
{
  Dave.SayAt(8, 167, 320,"Dave:Is this it?.");
//Attack
    Dave.ChangeView(28);
    Dave.Animate(2, 3, eOnce, eBlock, eForwards);
   
  EnemyST -= 5;
   Dave.ChangeView(26);
   Dave.FaceObject(Shiva, eBlock);
  //Attack
 
  tifa.ChangeView(16);
    tifa.Animate(2, 4, eOnce, eBlock, eForwards);
 playerHP += 7;
 tifa.ChangeView(10);
   tifa.FaceObject(Shiva, eBlock);
  //-------------------------
}
#1677
Thanks.

it Should work now.
#1679
Hum...
if my idea does not work try taking the line with the view change and place it after the second wait.
#1680


Btw, Thanks it works just fine however it seems when the timer is up for some reason it asks like (While) By this I mean when the time is up I have a game over gui that fades in however I lose control over the game and it just repeats whats inside the

  if ((countDownStarted) && (!CountDown.RawTimeRemaining))
  {
    // count down has expired..
  }
SMF spam blocked by CleanTalk