View unanswered posts | View active topics


Post a new topicPost a reply
Previous topic | Next topic 

  Trainee TraineeMember since: 10.03.2012, 16:37Posts: 114 Likes: 1
 

 Post Topic: Game Input during runtime , and Output in the HUD
PostPosted 06.05.2012, 14:16 
Need help please , i don't have idea on how input and output works through game to the HUD or UI how ever it's correct to be called....


Alright so , a game input event has happend , like player has died ( example )
and wich ever is the variable in c++ like " playerhasdied=true " through GetActorState()
" however it works , i know it's not like this" :.....

So after that succes , Can you add a code line in actionscript 2 on your hud ,on for example
"on a button that would be a symbol , that it's functionality is that it turns red , when you give it an input "

so that would be if (pointertopalyerstate==1 , buttonstatered=true ) so button turns red igname

so the HUD code is able to read c++ code variables??
Or how else does it work to send game input to the HUD?

pls help i can get to understand it!

User avatar   Beginner BeginnerMember since: 04.05.2012, 09:15Posts: 9Location: Idaho, United States Likes: 0
 

 Post Topic: Re: Game Input during runtime , and Output in the HUD
PostPosted 08.05.2012, 07:40 
I just started a few days ago so I cannot give you a good, nor the best answer, but Hypothetically speaking I believe this will work.

In flash say you create a button, and in cryengine you press the button. In flash you would have a function

button1.onPress = function()
{
fscommand("dothings_1");
}

This is the only way I am aware of at the moment, so you can use it till you find a better way.

You must setup an xml file in the UIElements folder so it can recognize your UI, find richman1 tutorials if you need to see how.

Then make a flowgraph node under ui -> yourflash -> dothings_1

And whenever the button is pressed, you link up whatever you want to the node.


Hopefully that can give you a start, that's the best i have got right now


"Pain is only weakness leaving the body"
  Trainee TraineeMember since: 10.03.2012, 16:37Posts: 114 Likes: 1
 

 Post Topic: Re: Game Input during runtime , and Output in the HUD
PostPosted 08.05.2012, 14:14 
you wacthed the flash long tutorial of richmar no ?
well since i psoted this i've alredy got lots of experience with flash but thanks anyways : )
im really close to finish some HUD hard stuff now .