Is there a string or something to uses other than player chracter

Started by Icey, Thu 27/01/2011 22:09:58

Previous topic - Next topic

Icey

In my game you are able to switch between 4 character in you party. I wanted to know if there is a command I can use for stuff like this

NPC.facechracter(player);
                              ^
I dont want to have the add a lot of code just for the npc to face the player character and not every one in the party

Khris

What's wrong with actually using that:

Code: ags
  cGuy.FaceCharacter(player);


?

Icey


ddq


Icey

sometimes it's hard to search for things in there unless you spell it how it is shown.

I find it way easier and better to talk to a human. Not to put you out there Khris but mostly every topic I made Khris has giving me an answer that really kept me going in my games.

Dualnames

Quote from: ddq on Thu 27/01/2011 23:12:06
It's called the manual. Read it.

What kind of behavior is that!! I DEMAND HIGH RESPECT. By the way, strangely when I type Face character on my manual, the FaceCharacter command is in the results.

*GASP*
Worked on Strangeland, Primordia, Hob's Barrow, The Cat Lady, Mage's Initiation, Until I Have You, Downfall, Hunie Pop, and every game in the Wadjet Eye Games catalogue (porting)

monkey0506

I think the issue was in finding the "player" keyword. The keyword is not referenced in the index, and a search actually yields quite a lot of results which might not be helpful for someone who isn't already aware that player is a literal keyword which can be used directly in the script (since it's a Character* which is internally updated anytime the player character is changed..but that too is probably a confusing concept to new users as well if they don't come from a programming background already).

Gilbert

I think it's for historical reasons that the player keyword isn't referenced that much in the manual, mainly because it previously didn't correctly reflect the current player character. It always pointed to the starting character, even after the player character has been changed with-in the game, so the player keyword was a bit useless. Only until quite recent versions (V2.7), that this behaviour was fixed and the keyword is thus much more useful than ever.

SMF spam blocked by CleanTalk