LUA question

In this forum you will find and post information regarding the modding of Star Wars Battlefront 2. DO NOT POST MOD IDEAS/REQUESTS.

Moderator: Moderators

Post Reply
RepSharpshooter
Gametoast Staff
Gametoast Staff
Posts: 1351
Joined: Tue Jul 10, 2007 4:10 pm

LUA question

Post by RepSharpshooter »

Is there a lua call to get player points? Where is this data stored? All I need something like getPlayerPoints(character). I want my game mode to end when a player reaches a certain amount of points (the mode is pretty much done and functional except for this regard). I've already read an re-read the docs, as well as a lot shipped luas. I was thinking something may be in like ifs_personalstats or some lua to that effect, but I can find nothing of value.

edit: also removing awards didn't work, was wondering if these guys had any success http://www.gametoast.com/forums/viewtop ... move+award (I did what they said to no avail)
User avatar
Maveritchell
Jedi Admin
Jedi Admin
Posts: 7366
Joined: Mon Aug 21, 2006 11:03 pm

Re: LUA question

Post by Maveritchell »

I don't know if there is one, but why not just use a dummy variable to track player points as they're amassed? Something that adds 1 to the variable for every kill, etc.
RepSharpshooter
Gametoast Staff
Gametoast Staff
Posts: 1351
Joined: Tue Jul 10, 2007 4:10 pm

Re: LUA question

Post by RepSharpshooter »

Well I was thinking about that as a last resort. I could have a table of characters and their points. The only source of points is by controlling the center ring, so it would make it doable.
User avatar
Teancum
Jedi Admin
Jedi Admin
Posts: 11080
Joined: Wed Sep 07, 2005 11:42 pm
Projects :: No Mod project currently.
Games I'm Playing :: Destiny
xbox live or psn: No gamertag set
Location: Indiana

Re: LUA question

Post by Teancum »

http://www.secretsociety.com/forum/down ... erence.txt

All lua functions that are documented. Looks like team points only, but that doesn't mean there's not an undocumented function. I ripped all of em out of the exe once and posted them. Let me see if I can find the thread.


Found it:

http://www.gametoast.com/forums/viewtop ... 27&t=12469
RepSharpshooter
Gametoast Staff
Gametoast Staff
Posts: 1351
Joined: Tue Jul 10, 2007 4:10 pm

Re: LUA question

Post by RepSharpshooter »

Teancum wrote:http://www.secretsociety.com/forum/down ... erence.txt
Already had and looked through that

I searched through all the "get"s in that thread and found nothing. I just went with the second option, but would still like a callback if someone knew it existed :lol: my guess is it's a C variable though
Post Reply