Fortress Forever

Go Back   Fortress Forever > Editing > Mapping > Lua

Reply
 
Thread Tools Display Modes
Old 04-10-2009, 07:57 AM   #1
hlstriker
QUAD ROCKET
Server Owner
Fortress Forever Staff
 
hlstriker's Avatar
 
Join Date: Jul 2007
Class/Position: Soldier
Gametype: Rocket Jumping
Affiliations: -g1 ]qS[ -eC- :e0: [ESAD]
Posts Rated Helpful 11 Times
More callbacks than listed?

Are there other callbacks than the ones Mulchman listed in the sticky post?

Edit:
Is there a COMPLETE list of functions too?

This post has some but not all:
http://forums.fortress-forever.com/s...89&postcount=4

Last edited by hlstriker; 04-10-2009 at 08:02 AM.
hlstriker is offline   Reply With Quote


Old 04-10-2009, 08:50 AM   #2
squeek.
Stuff Do-er
Lua Team
Wiki Team
Fortress Forever Staff
 
squeek.'s Avatar
 
Join Date: Mar 2007
Location: Northern California
Class/Position: Rallygun Shooter
Gametype: Conc tag (you just wait)
Affiliations: Mustache Brigade
Posts Rated Helpful 352 Times
Send a message via AIM to squeek.
Thanks for bringing this up. Searching through the code I've come up with these:

Code:
player_onprimegren1( player_entity )
player_onprimegren2( player_entity )
buildable_ondamage( buildable_entity, damage_info )
As an aside, some very strange variables were added to func_button:ondamage() without any documentation.

Code:
info_damage (int)
info_attacker (base entity/player)
info_classname (string weapon name)
Here's an example code from a dev map I found:
Code:
bob = func_button:new({})
function bob:ondamage()
    if IsPlayer( info_attacker ) then
        local player = CastToPlayer( info_attacker )
	ConsoleToAll(player:GetName().." shot button with a "..info_classname.." for "..info_damage.." damage")
	if info_classname == "ff_weapon_spanner" then
		PressButton(entname)
	end
    end
end
As for functions... no, there isn't... yet.
__________________
#FF.Pickup ¤ Fortress-Forever pickups

My Non-official Maps
Released FF_DM_Squeek - FF_2Mesa3_Classic - FF_Siege_Classic
Beta FF_Myth - FF_Redlight_Greenlight

Sick of the people on the internet, always moanin'. They just moan.
- Karl Pilkington
squeek. is offline   Reply With Quote


Old 04-10-2009, 06:48 PM   #3
hlstriker
QUAD ROCKET
Server Owner
Fortress Forever Staff
 
hlstriker's Avatar
 
Join Date: Jul 2007
Class/Position: Soldier
Gametype: Rocket Jumping
Affiliations: -g1 ]qS[ -eC- :e0: [ESAD]
Posts Rated Helpful 11 Times
Alright, I was just wondering about the functions too because I remember you posting the SetVelocity() in the feature request forum and didn't see it in the function list.

Also, now I don't have to ask how to concatenate strings (who would have guessed 2 dots)!
hlstriker is offline   Reply With Quote


Old 04-10-2009, 08:57 PM   #4
squeek.
Stuff Do-er
Lua Team
Wiki Team
Fortress Forever Staff
 
squeek.'s Avatar
 
Join Date: Mar 2007
Location: Northern California
Class/Position: Rallygun Shooter
Gametype: Conc tag (you just wait)
Affiliations: Mustache Brigade
Posts Rated Helpful 352 Times
Send a message via AIM to squeek.
Quote:
Originally Posted by hlstriker View Post
Alright, I was just wondering about the functions too because I remember you posting the SetVelocity() in the feature request forum and didn't see it in the function list.

Also, now I don't have to ask how to concatenate strings (who would have guessed 2 dots)!
Yeah... I think there are quite a few undocumented functions. I'll try to get a list of them sometime.
__________________
#FF.Pickup ¤ Fortress-Forever pickups

My Non-official Maps
Released FF_DM_Squeek - FF_2Mesa3_Classic - FF_Siege_Classic
Beta FF_Myth - FF_Redlight_Greenlight

Sick of the people on the internet, always moanin'. They just moan.
- Karl Pilkington
squeek. is offline   Reply With Quote


Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 03:35 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2024, vBulletin Solutions, Inc.