10-17-2007, 01:11 PM | #1 |
Join Date: Sep 2007
Posts Rated Helpful 0 Times
|
LUA stuff
Can any one give me a lua for a hammer teleporter
Last edited by sir_frags; 11-06-2007 at 04:23 PM. |
|
10-17-2007, 03:23 PM | #2 |
OHH! OHHH NOOO!
Wiki Team
Beta Tester Join Date: Mar 2007
Posts Rated Helpful 0 Times
|
Why would you want this? More info would help, then I could try to find out.
__________________
What was left of my sanity implored me not to enter...but that voice was just a whisper now. |
|
10-17-2007, 04:10 PM | #3 |
Nutcracker
|
Code:
classteleport = trigger_teleport:new({ }) hwguyteleport = classteleport:new({ class = Player.kHwguy } function classteleport:allowed( allowed_entity ) if IsPlayer( allowed_entity ) then local player = CastToPlayer( allowed_entity ) if player:GetClass() == self.class then return true end return false end end |
|
10-17-2007, 10:37 PM | #4 |
Nutcracker
|
Code:
weirdteleport = trigger_teleport:new({ }) function weirdteleport:allowed( allowed_entity ) if IsPlayer( allowed_entity ) then local player = CastToPlayer( allowed_entity ) if player:GetClass() == Player.kScout or player:GetClass() == Player.kSniper or player:GetClass() == Player.kMedic then return false end return true end end |
|
10-18-2007, 12:23 AM | #5 |
Nutcracker
|
I've been programming small stuff since I was 12 or something. All I need to do is learn the syntax of the language and I can do the basic stuff with it. I actually know why the code does what you needed, not just what it does
|
|
10-19-2007, 10:55 AM | #6 |
Join Date: Mar 2007
Posts Rated Helpful 0 Times
|
a little more then only the syntax
all the custom ff commands and constants are required knowledge if you want to code fast and efficiently, but therefore i like to have a doc page where they explain the parameters for all the functions, becouse the errors you get ingame are quite difficult to understand: for ex: player:GetTeamId() will cast an error that the parameter required is nil, why becouse i didn't declarate the "player" var, while other languages just say that player is unknown to the interpreter. |
|
10-19-2007, 03:00 PM | #7 |
Join Date: Oct 2007
Posts Rated Helpful 0 Times
|
Is there some API for the game that you can use? You mentioned something about some documentation, do you have a link?
|
|
10-19-2007, 03:05 PM | #8 |
Join Date: Sep 2007
Posts Rated Helpful 0 Times
|
I would guess, that could only come from the FF team
|
|
10-19-2007, 03:42 PM | #9 | |
Join Date: Mar 2007
Posts Rated Helpful 0 Times
|
Quote:
|
|
|
10-20-2007, 10:06 AM | #10 |
Nutcracker
|
I'm sure they're working on it... be patient
|
|
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
|
|