Jump to content


Photo

Ganon's Coding Questions


  • Please log in to reply
67 replies to this topic

#61 Ganon

Ganon

    What's this?

  • Project Team
  • 967 posts
  • Location:Ohio, United States
  • Projects:My Link Mod
  •  Code Scientist

Posted 23 September 2011 - 12:48 PM

Okay, I have another question. I'm wondering about this little code snippet:
Behavior LifetimeUpdate LifetimeTag
		WaitForWakeUp = Yes
	End

This time, it's code that I've seen many times, but I've never really known its purpose. Maybe somebody, (Deezire?) knows how it works?
Judging by the fact that only Mumakil, Trolls, and Boromir have it. I'm assuming it has something to do with the "Rampage" ability?

...I removed it from the Mountain Troll once, a long time ago, to see what would happen. IIRC the troll just died on creation.

#62 DeeZire

DeeZire
  • Members
  • 140 posts

Posted 24 September 2011 - 06:08 PM

It's used when you want an object to have a limited lifetime, summoned objects use it to vanish after a fixed period of time. In the case of Trolls etc they have WaitForWakeUp = Yes set which means this behaviour is invoked when the unit would otherwise die (defined in DelayedDeathBody), this is what allows them to rampage for a short fixed time before actually dying.

#63 Ganon

Ganon

    What's this?

  • Project Team
  • 967 posts
  • Location:Ohio, United States
  • Projects:My Link Mod
  •  Code Scientist

Posted 21 November 2013 - 04:29 AM

I don't suppose anyone know's how to edit the apt files well enough to create additional buttons on the Palantir?

Six just isn't enough. Even 7 or 8 would be great. I think it's probably possible, but I'm no good in that area.

 

...

 

Also, does anyone know of a way to disable/re-enable a command button using LUA?



#64 Spartan184

Spartan184

    :)

  • Project Team
  • 1,592 posts
  • Location:Moon
  • Projects:Random Modding Projects
  •  Coder, Map.ini Coder, Mapper, and Beta Tester

Posted 21 November 2013 - 04:37 AM

Why don't you use Turins more ability system? It lets you have 12 buttons in the Palantir



 

safsignature.png

 


#65 Ganon

Ganon

    What's this?

  • Project Team
  • 967 posts
  • Location:Ohio, United States
  • Projects:My Link Mod
  •  Code Scientist

Posted 21 November 2013 - 04:39 AM

I'll look into it. Thanks.  :thumbsuphappy:

 

I'm still curious about my second question though.



#66 Phil

Phil

    Force Majeure

  • Network Leaders
  • 7,976 posts
  • Location:Switzerland
  • Projects:Revora, C&C:Online
  •  Thought Police
  • Division:Revora
  • Job:Network Leader
  • Donated
  • Association

Posted 21 November 2013 - 07:13 PM

You can grant/revoke object upgrades or set/unset Model Conditions with Lua. That's a starting point.


Edited by Phil, 21 November 2013 - 07:14 PM.

revorapresident.jpg
My Political Compass

Sieben Elefanten hatte Herr Dschin
Und da war dann noch der achte.
Sieben waren wild und der achte war zahm
Und der achte war's, der sie bewachte.


#67 Ganon

Ganon

    What's this?

  • Project Team
  • 967 posts
  • Location:Ohio, United States
  • Projects:My Link Mod
  •  Code Scientist

Posted 21 November 2013 - 10:49 PM

Thank you. That's just the sort of thing I was looking for.

 

I'm a little rusty.  :dry:



#68 Meneldil

Meneldil
  • Members
  • 46 posts
  • Location:Yellowstone National Park, WY, USA

Posted 27 November 2013 - 04:09 AM

I found Turin's more ability system, but saw that it was only for BFME2 and ROTWK. In the past, I've used a double command set to achieve the equivalent of additional palantir buttons, but I'm guessing that's not what you are looking for, correct?






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users