View unanswered posts | View active topics It is currently Wed Jan 08, 2025 10:23 pm



Reply to topic  [ 12 posts ] 
 Limiting buy Menu? 
Author Message

Joined: Wed Dec 30, 2009 10:44 pm
Posts: 64
Location: Oregon USA
Reply with quote
Post Limiting buy Menu?
Is there any ini code i can add to limit the buy menu until certain requirements are met? This will be for a PvP Campaign map.


Wed Mar 17, 2010 12:44 pm
Profile
User avatar

Joined: Wed Jan 07, 2009 10:26 am
Posts: 4074
Location: That quaint little British colony down south
Reply with quote
Post Re: Limiting buy Menu?
No.
You'll need Lua for that.
Or you could just give each player 0 gold and no way to get gold until said conditions are met.


Wed Mar 17, 2010 12:49 pm
Profile WWW

Joined: Wed Dec 30, 2009 10:44 pm
Posts: 64
Location: Oregon USA
Reply with quote
Post Re: Limiting buy Menu?
FUUUUUUUUUUUUUUUUUU- i mean, Thanks. The basic idea was to have both players trying to control a point on the map. once one player takes control of the outpost he then orders a control chip. Once the chip is dropped in a certain area of the outpost, more buy options open up. I wanted to only allow the player to order dropships and basic units/weapons until he takes control of an outpost.


Wed Mar 17, 2010 1:04 pm
Profile
User avatar

Joined: Wed Jan 07, 2009 10:26 am
Posts: 4074
Location: That quaint little British colony down south
Reply with quote
Post Re: Limiting buy Menu?
Then you'd need Lua based buying and a script to otherwise disable all delivery apart from this system.


Wed Mar 17, 2010 1:23 pm
Profile WWW

Joined: Wed Dec 30, 2009 10:44 pm
Posts: 64
Location: Oregon USA
Reply with quote
Post Re: Limiting buy Menu?
So I would need to script in my own buying system then? O_o


Wed Mar 17, 2010 1:25 pm
Profile
User avatar

Joined: Wed Jan 07, 2009 10:26 am
Posts: 4074
Location: That quaint little British colony down south
Reply with quote
Post Re: Limiting buy Menu?
So you would have to have something that spawns units and deducts the gold value under the condition that the correct point has been unlocked as well as a script to stop players from ordering normally.


Wed Mar 17, 2010 1:31 pm
Profile WWW

Joined: Wed Dec 30, 2009 10:44 pm
Posts: 64
Location: Oregon USA
Reply with quote
Post Re: Limiting buy Menu?
So can i disable the buy menu with the mission activitys.ini then use lua to make my own buy menu?


Wed Mar 17, 2010 1:35 pm
Profile
User avatar

Joined: Mon Oct 06, 2008 2:04 am
Posts: 1559
Reply with quote
Post Re: Limiting buy Menu?
clOWN wrote:
So can i disable the buy menu with the mission activitys.ini then use lua to make my own buy menu?


No. What he really means is that it's impossible to just straight out 'disable' the buy menu. It's a hard-coded function into the game (as is everything on the pie menu), and you can't really modify it. What he's suggesting is to disable normal delivery through the buy menu, which currently you can only really do by giving the player no money to order with (unless I'm mistaken). Then make your own Lua based way of 'purchasing' units.

In other words you could have Lua make your own fake "gold" counter that goes up when players get actual gold (which would then have to be immediately deducted from the REAL gold counter to prevent buy menu actions), and then have the fake counter deduct gold when you want to spawn a certain unit from a limited selection onto the field or something similar.

Honestly because of the hard-coded elements you're trying to impossibly manipulate here, your relatively simple in concept effect actually requires a lot of difficult workarounds. Unless I'm being retarded again, which is also a possibility, this idea is a little too much work for the result.


Wed Mar 17, 2010 7:29 pm
Profile

Joined: Wed Dec 30, 2009 10:44 pm
Posts: 64
Location: Oregon USA
Reply with quote
Post Re: Limiting buy Menu?
So basically my first modding idea is a total pain :roll: . Well maybe my later Mods won't be so hard if I can get this done.


Thu Mar 18, 2010 2:40 am
Profile
User avatar

Joined: Wed Jan 07, 2009 10:26 am
Posts: 4074
Location: That quaint little British colony down south
Reply with quote
Post Re: Limiting buy Menu?
Yes. This is an fairly hard thing to do.


Thu Mar 18, 2010 6:38 am
Profile WWW

Joined: Mon Mar 15, 2010 11:46 pm
Posts: 67
Reply with quote
Post Re: Limiting buy Menu?
What you could do is set the gold of the players to 0, then add a very simple lua code that adds money to players when a player destroys object X or Y or kills player controlled/non player controlled unit X or Y.

I did it... and I think there's a much simpler version out there too.

I'm pretty sure that, if you're even able to get the 'controlling points' in there you can do this aswell...


Thu Mar 18, 2010 9:01 pm
Profile

Joined: Wed Dec 30, 2009 10:44 pm
Posts: 64
Location: Oregon USA
Reply with quote
Post Re: Limiting buy Menu?
Thanks for the Info. Yeah I'm gona try to think something up that isn't too code heavy.


Fri Mar 19, 2010 5:51 pm
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 12 posts ] 

Who is online

Users browsing this forum: No registered users


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by STSoftware for PTF.
[ Time : 0.029s | 15 Queries | GZIP : Off ]