Fortress Forever

Go Back   Fortress Forever > Editing > Mapping > Lua

Reply
 
Thread Tools Display Modes
Old 03-31-2008, 06:19 PM   #1
GambiT
Fortress Forever Staff
 
GambiT's Avatar
 
Join Date: Mar 2007
Location: Baton Rouge
Class/Position: Spy
Affiliations: -=DoM=-
Posts Rated Helpful 0 Times
force spectate by steam id?

lol, this is a serious question...

is it possible via LUA or some other means to have certain steam ids forced into spectate and spectate only?
__________________
-------------------------------FF_Rock2(WIP)------------------------------
---------------------------FF_RedGiant(Released)-------------------------
--------------------------FF_Fragzone_G(Released)------------------------
--------------------------FF_Civibash_G(Released)------------------------
-------------------FF_Conc_G1(WIP)--------------------
-------------------FF_Hollow_G(WIP)---------------------
GambiT is offline   Reply With Quote


Old 03-31-2008, 09:20 PM   #2
GambiT
Fortress Forever Staff
 
GambiT's Avatar
 
Join Date: Mar 2007
Location: Baton Rouge
Class/Position: Spy
Affiliations: -=DoM=-
Posts Rated Helpful 0 Times
nobody knows?

yes,no,maybe???

i have a very good reason for this but dont care to start a flame war...
__________________
-------------------------------FF_Rock2(WIP)------------------------------
---------------------------FF_RedGiant(Released)-------------------------
--------------------------FF_Fragzone_G(Released)------------------------
--------------------------FF_Civibash_G(Released)------------------------
-------------------FF_Conc_G1(WIP)--------------------
-------------------FF_Hollow_G(WIP)---------------------
GambiT is offline   Reply With Quote


Old 03-31-2008, 09:41 PM   #3
Dr.Satan
Wiki Team
Fortress Forever Staff
 
Dr.Satan's Avatar
 
Join Date: Sep 2007
Location: Greeley, CO
Class/Position: Med / Solly
Gametype: PAYLOAD
Affiliations: DET-
Posts Rated Helpful 19 Times
I think if you had a dev on your side it would be possible, but I'm going to doubt that currently there is a bit of code to get the steam ID of a person.

Possible sometime, yes.

Possible now, I doubt it.
__________________
(Released) conc_school | hellion_classic | ksour_PAYLOAD | mulch_faf
(Beta) alchimy_b1
(Lua) base_payload_2015
(Models) props_trainyard
Support FF:
Dr.Satan is offline   Reply With Quote


Old 03-31-2008, 09:46 PM   #4
cownaetion
Wizard of Milk
 
Join Date: Sep 2007
Location: Upstate NY, USA
Posts Rated Helpful 0 Times
Send a message via ICQ to cownaetion Send a message via AIM to cownaetion Send a message via MSN to cownaetion Send a message via Yahoo to cownaetion
I don't know anything about administering a server but when you ban someone doesn't it use their Steam ID as the unique identifier? If that's the case then could someone make a simple mod to map those Steam ID's on to a spectator list instead of a ban list? I'm sure your right by saying it's not possible now but I'm sure a simple mod could, no? This is all theory as I've never ran a server except when testing maps, which doesn't count...
cownaetion is offline   Reply With Quote


Old 03-31-2008, 09:54 PM   #5
Dr.Satan
Wiki Team
Fortress Forever Staff
 
Dr.Satan's Avatar
 
Join Date: Sep 2007
Location: Greeley, CO
Class/Position: Med / Solly
Gametype: PAYLOAD
Affiliations: DET-
Posts Rated Helpful 19 Times
yeah I'm sure someone could pull it off with SM or something.

Ask the guys at Allied Moderators if they can do it.
__________________
(Released) conc_school | hellion_classic | ksour_PAYLOAD | mulch_faf
(Beta) alchimy_b1
(Lua) base_payload_2015
(Models) props_trainyard
Support FF:
Dr.Satan is offline   Reply With Quote


Old 03-31-2008, 10:03 PM   #6
Tsukasa
 
Join Date: Sep 2007
Class/Position: O
Gametype: CTF
Affiliations: mimic-
Posts Rated Helpful 0 Times
Quote:
Originally Posted by GambiT
lol, this is a serious question...

is it possible via LUA or some other means to have certain steam ids forced into spectate and spectate only?
Gambit, title your shit better. possible or not? doesnt cut it.
Tsukasa is offline   Reply With Quote


Old 03-31-2008, 10:08 PM   #7
GambiT
Fortress Forever Staff
 
GambiT's Avatar
 
Join Date: Mar 2007
Location: Baton Rouge
Class/Position: Spy
Affiliations: -=DoM=-
Posts Rated Helpful 0 Times
ask nicely and i'll consider it...


EDIT: to put it as simply as i can put it(remembering that i am lua ignorant it is also the best i can put it)

"if player is "steam id" then force spectate"


thats what i want
__________________
-------------------------------FF_Rock2(WIP)------------------------------
---------------------------FF_RedGiant(Released)-------------------------
--------------------------FF_Fragzone_G(Released)------------------------
--------------------------FF_Civibash_G(Released)------------------------
-------------------FF_Conc_G1(WIP)--------------------
-------------------FF_Hollow_G(WIP)---------------------

Last edited by GambiT; 03-31-2008 at 10:15 PM.
GambiT is offline   Reply With Quote


Old 03-31-2008, 10:16 PM   #8
Skanky Butterpuss
Beware the Hammer
Buffalo Butterpuss
D&A Member
Fortress Forever Staff
 
Skanky Butterpuss's Avatar
 
Join Date: Mar 2007
Class/Position: Sabotaging your shit.
Affiliations: :}|, mimic, /KBN/
Posts Rated Helpful 0 Times
if you figure this out, code my steamID to get quad damage and inculnerability and no conc effect and infinite nades plz
__________________
Support FF:
Etzell: Skanky
Etzell: The Wings are fucking fantastic
Etzell: They really are
Etzell: But even SAYING that makes me want to vomit
Skanky Butterpuss is offline   Reply With Quote


Old 03-31-2008, 10:28 PM   #9
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.
Code:
local steamid = player:GetSteamID()
ConsoleToAll( "SteamID: "..steamid )
See what it comes out with and go from there.
__________________
#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-01-2008, 01:43 AM   #10
cownaetion
Wizard of Milk
 
Join Date: Sep 2007
Location: Upstate NY, USA
Posts Rated Helpful 0 Times
Send a message via ICQ to cownaetion Send a message via AIM to cownaetion Send a message via MSN to cownaetion Send a message via Yahoo to cownaetion
Quote:
Originally Posted by squeek
local steamid = player:GetSteamID() ConsoleToAll( "SteamID: "..steamid )


See what it comes out with and go from there.
I'm just copying/pasting here so I'm sure this isn't correct but maybe something like this:

Code:
function trigger_ff_script:spawn() 
	
     if IsPlayer( trigger_entity ) then
          local player = CastToPlayer( trigger_entity )
          
          //making up these lines
          for ( var i=0; i < listOfSteamIds.length; i++) {
               if (player.steamid == listOfSteamIds[i]) {
                    //no clue if these are right, just copy/paste/replaced with false
                    redspawn = { validspawn = false }
                    bluespawn = { validspawn = false }
                    greenspawn = { validspawn = false }
                    yellowspawn = { validspawn = false }
               end
          end
end
Will not automatically have them join Spectator but considering they can't or won't be able to spawn, nothing else really. I don't know if that's the method call to disable spawning, I just quickly browsed the LUA files and saw spawn
cownaetion is offline   Reply With Quote


Old 04-01-2008, 01:49 AM   #11
GambiT
Fortress Forever Staff
 
GambiT's Avatar
 
Join Date: Mar 2007
Location: Baton Rouge
Class/Position: Spy
Affiliations: -=DoM=-
Posts Rated Helpful 0 Times
so can i get a definite "code" on it?

with lets say 12345 and 6789 as the steam id's and i'll figure it out from there..
__________________
-------------------------------FF_Rock2(WIP)------------------------------
---------------------------FF_RedGiant(Released)-------------------------
--------------------------FF_Fragzone_G(Released)------------------------
--------------------------FF_Civibash_G(Released)------------------------
-------------------FF_Conc_G1(WIP)--------------------
-------------------FF_Hollow_G(WIP)---------------------
GambiT is offline   Reply With Quote


Old 04-02-2008, 09:16 PM   #12
GambiT
Fortress Forever Staff
 
GambiT's Avatar
 
Join Date: Mar 2007
Location: Baton Rouge
Class/Position: Spy
Affiliations: -=DoM=-
Posts Rated Helpful 0 Times
can somebody please give me a code i can test?


i have a very good reason for needing this...
__________________
-------------------------------FF_Rock2(WIP)------------------------------
---------------------------FF_RedGiant(Released)-------------------------
--------------------------FF_Fragzone_G(Released)------------------------
--------------------------FF_Civibash_G(Released)------------------------
-------------------FF_Conc_G1(WIP)--------------------
-------------------FF_Hollow_G(WIP)---------------------
GambiT is offline   Reply With Quote


Old 04-02-2008, 09:23 PM   #13
GeoKill----->
Community Member
Server Owner
Beta Tester
Forum Moderator
 
GeoKill----->'s Avatar
 
Join Date: Mar 2007
Location: Hawthorne, California
Class/Position: Soldier/Spy/Scout
Gametype: AvD
Affiliations: :e0:Eternal Order Leader
Posts Rated Helpful 12 Times
To not allow them to play your map? and just spec it?
__________________

:e0: Will live on Forever
Support FF:
GeoKill-----> is offline   Reply With Quote


Old 04-02-2008, 09:48 PM   #14
GambiT
Fortress Forever Staff
 
GambiT's Avatar
 
Join Date: Mar 2007
Location: Baton Rouge
Class/Position: Spy
Affiliations: -=DoM=-
Posts Rated Helpful 0 Times
i didnt want to turn this into a flame fest, but yes that is the reason.

this is for the beta maps mainly, i cant see doing this for finals, thats something you cant undo once done ya know.

why does it matter what my reason is? if you know how to get it to work then tell me how, i shouldnt have to explain my reasoning behind something in order to get the LUA team ppl to help me.
__________________
-------------------------------FF_Rock2(WIP)------------------------------
---------------------------FF_RedGiant(Released)-------------------------
--------------------------FF_Fragzone_G(Released)------------------------
--------------------------FF_Civibash_G(Released)------------------------
-------------------FF_Conc_G1(WIP)--------------------
-------------------FF_Hollow_G(WIP)---------------------
GambiT is offline   Reply With Quote


Old 04-02-2008, 09:50 PM   #15
cownaetion
Wizard of Milk
 
Join Date: Sep 2007
Location: Upstate NY, USA
Posts Rated Helpful 0 Times
Send a message via ICQ to cownaetion Send a message via AIM to cownaetion Send a message via MSN to cownaetion Send a message via Yahoo to cownaetion
I'll try to see if that piece of code will work later tonight Gambit and post the results. I can't guarantee anything so don't put all your hopes on me please
cownaetion is offline   Reply With Quote


Old 04-02-2008, 10:05 PM   #16
GeoKill----->
Community Member
Server Owner
Beta Tester
Forum Moderator
 
GeoKill----->'s Avatar
 
Join Date: Mar 2007
Location: Hawthorne, California
Class/Position: Soldier/Spy/Scout
Gametype: AvD
Affiliations: :e0:Eternal Order Leader
Posts Rated Helpful 12 Times
Well if you do this with Lua, it could be easily be edit out.
__________________

:e0: Will live on Forever
Support FF:
GeoKill-----> is offline   Reply With Quote


Old 04-03-2008, 06:23 PM   #17
fishBurger
get off my lawn
 
fishBurger's Avatar
 
Join Date: Mar 2007
Class/Position: O scout / demo
Gametype: killing
Posts Rated Helpful 0 Times
Yeah any server admin could adjust the lua to remove said restrictions, or restrict other players for their own purposes.
__________________
That means that either you are an American, or you are NOT an American. There is no hyphenated exception. -Iggy
fishBurger is offline   Reply With Quote


Old 04-03-2008, 06:32 PM   #18
GambiT
Fortress Forever Staff
 
GambiT's Avatar
 
Join Date: Mar 2007
Location: Baton Rouge
Class/Position: Spy
Affiliations: -=DoM=-
Posts Rated Helpful 0 Times
and??


what if i only run the map on my server? and dont let ppl download the LUA?? then they can ONLY play it on my server.

i can be a real dick about this, but im not, i havent gone into detail as to why i want this, mainly because its none of your damn business to be completely honest. if you know how to do it please tell me.




i was not being mean in this post
__________________
-------------------------------FF_Rock2(WIP)------------------------------
---------------------------FF_RedGiant(Released)-------------------------
--------------------------FF_Fragzone_G(Released)------------------------
--------------------------FF_Civibash_G(Released)------------------------
-------------------FF_Conc_G1(WIP)--------------------
-------------------FF_Hollow_G(WIP)---------------------
GambiT is offline   Reply With Quote


Old 04-03-2008, 09:23 PM   #19
Jester
Fortress Forever Staff
 
Jester's Avatar
 
Join Date: Sep 2007
Class/Position: O: Scout
Affiliations: {NFO} - New Family Order
Posts Rated Helpful 0 Times
Code:
if player:GetSteamID() == 1234 then
     switchteam( player, player:GetTeamId(), Team.kSpectator )
end
I saw the switchteam function in the quad LUA, but I don't know if this is how it can be used, worth a shot. Also, I would put this in the player_spawn function so it switches them each time they try to choose a team.

EDIT: I don't think the steamid checks will work I just tried this in a LAN:
Code:
if steamid == STEAM_ID_LAN then
	player:AddAmmo( Ammo.kGren1, 4 )
end
And no grenades were added(starting with 0 as a spy).
And steamid is being declared using squeek's code above.

Last edited by Jester; 04-03-2008 at 09:42 PM.
Jester is offline   Reply With Quote


Old 04-03-2008, 09:57 PM   #20
GambiT
Fortress Forever Staff
 
GambiT's Avatar
 
Join Date: Mar 2007
Location: Baton Rouge
Class/Position: Spy
Affiliations: -=DoM=-
Posts Rated Helpful 0 Times
sweet, now i just need Zips steam id





haha
__________________
-------------------------------FF_Rock2(WIP)------------------------------
---------------------------FF_RedGiant(Released)-------------------------
--------------------------FF_Fragzone_G(Released)------------------------
--------------------------FF_Civibash_G(Released)------------------------
-------------------FF_Conc_G1(WIP)--------------------
-------------------FF_Hollow_G(WIP)---------------------
GambiT 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 06:06 AM.


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