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

#1
Hello everyone, it's me again! I've finished the first part of my demo, so now I have two other parts to go.

The next part I'm tackling is less programming intensive, but it's still one I'm not sure how to tackle. So in this part, the playable character is supposed to interrogate this thug boss, and he'll be grabbing the boss by the collar.

What I'm trying to figure out is if they will all have to merge into one character sprite/character, or if I will have to separate them into two sprites, so one would have a separate talking animation while the other one talks, making it LOOK like one animation.



There will be some special animations in mid-dialogue like swinging the bad guy around, so should it be one view or two separate views? Thanks!
#2
Thanks, Khris! I tried coding in the dialog at first, but it didn't really work.

Now that I know that there's a trick to it, everything's working the way I want it to now.
#3
EDIT: Finally got it working. Special thanks to Khris and a PM by Adeel S. Ahmed for helping me with this! ;-D


Hello!

I'm progressing through my adventure game, and almost have the first room fleshed out. The only thing that is standing in my way is trying to trigger a global variable in the code.

In dRadio Dialog Script (altered for the sake of spoilers):
Code: ags

@2
EGO: "Can you pull up a profile on the victim?"
DISP: "Right. Searching now..."
DISP: ...
DISP: "Here we go. He was arrested many times for swindling bystanders."
DISP: "He apparently belonged to a ring of grifters. He definitely was no saint."
EGO: "Interesting."
EGO: "So I'm investigating the murder of a petty criminal."
DISP: "Keep in mind, this man was guilty of pulling scams."
DISP: "Murder is a far more serious crime."
EGO: "I am well aware of that."
DISP: "Well now we know the victim, let's get back to investigation."
EGO: "Right."
option-off-forever 2
return


Ideally, I have this Global Variable called "vVicConart" which would trigger an event if it's value became 1 instead of 0. What should I do to tackle this problem?

If there's an alternate way of achieving what I would like to go for, I'm all ears.
#4
Thank you very much, Khris and Crimson! :-D You've both helped me out very well!

Quote from: Crimson Wizard on Thu 07/08/2014 18:25:10
In room script:
Code: ags

function on_call(MyRoomEvent event) { // yes, this actually works! because "enum" is technically identical to "int" :)
  if (event == ePlayerUsedInventoryOnSelf) {
    if (player.ActiveInventory == iRadio) {
      // player used radio on themselves
    }
  }
}


That is interesting! I really didn't know too much about the enum until now, so this will definitely help making things easier in searching for code in case the character calls the radio guy in a different room!

Either way, the second solution worked wonders in the test, so all I have to do is add in the dialog code and I'm all set! Thank you again!

Quote from: Khris on Thu 07/08/2014 18:00:47
The import line is completely unnecessary, why do you have that?

Oh, yes. I used that code because I was running out of options, and I misread one of the manual lessons by accident. Sometimes the brain does strange things when trying to get things to work, haha!
#5
Hi there!

That does seem strange! So does the GUI bar show up during the dialog, and it quits on you, or does the GUI bar crash regardless of dialog and such?
#6
EDIT: Many thanks to Crimson Wizard and Khris for helping me out. The problem has been solved.

Hello everyone! I am trying to create a mystery/vigilante sort of adventure game with AGS.

Unfortunately, the specific sort of scripting I'm trying to go for is not in the manual (or at least from what I can read.) What I would like to do is have the playable character USE their radio on themselves, and trigger a conversation that would only happen in that specific room.

Basically if they used the radio at a crime scene, they would ask for details to look for, and if they were at a criminal hideout, they would ask to record conversations among thugs, and so forth.

I tried using:
Code: ags

import function cEgo_UseInv();

function cEgo_UseInv()
{
 if (player.ActiveInventory == iRadio) {
      Display("The radio clicks on.");
}
}


But with no luck. Can someone help me?
SMF spam blocked by CleanTalk