Server Help Forum Index Server Help
Community forums for Subgame, ASSS, and bots
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   StatisticsStatistics   RegisterRegister 
 ProfileProfile   Login to check your private messagesLogin to check your private messages   LoginLogin (SSL) 

Server Help | ASSS Wiki (0) | Shanky.com
%killer and %killed's bounty

 
Post new topic   Reply to topic Printable version
 View previous topic  Linux Firewall Ports (APF) Post :: Post Compiling .so files on windows  View next topic  
Author Message
.:IceRabbit:.
Newbie


Gender:Gender:Male
Joined: Aug 14 2006
Posts: 15
Offline

PostPosted: Tue Aug 15, 2006 2:46 am    Post subject: %killer and %killed's bounty Reply to topic Reply with quote

I am working on a module and I want to add the following features. I marked the ones I have done, but I listed them to help convey my idea.


  • Players starts with 0 bty on spawn. (Already done)
  • The player picks up a green and gets 1 bty. (Already done)
  • The player is killed and the %killer gets %killed exact bty added to his own. (<-- Need help)
  • The player goes to a rgn and the server takes his bty, adds it to another variable (stores it) and then resets his bty to 0. (<-- Need help)


So, in essence, I want to let the players deposit their bounties, but I would rather not have to make them respawn to get the 0 bty.

I know ?prize without the "#" adds to the player's bounty and I just found out ?shipreset resets the bounty too. So all I really need to know is how can I have the server read the player's bounty properly in both when they enter a rgn and on death (I read that the int bounty in CB_KILL is what the %killer gets, not what the %killed had...)

Thanks in advanced for any assistance.
Back to top
View users profile Send private message Add User to Ignore List
Chambahs
Power attack
Power attack


Joined: Jun 19 2005
Posts: 820
Offline

PostPosted: Tue Aug 15, 2006 8:29 am    Post subject: Reply to topic Reply with quote

Here, go check this out:

http://forums.minegoboom.com/viewtopic.php?p=61855#61855

Download the modules and look through chit.py. There is a lot of green/bounty coding in there. Something should help you out if you look through that.

Also this brings me to my other question. Are you coding in C or Python?
Back to top
View users profile Send private message Add User to Ignore List
Dr Brain
Flip-flopping like a wind surfer


Age:39
Gender:Gender:Male
Joined: Dec 01 2002
Posts: 3502
Location: Hyperspace
Offline

PostPosted: Tue Aug 15, 2006 10:30 am    Post subject: Reply to topic Reply with quote

Look in the player struct for the bounty. Should be in there.

You may be able to reset bounty by sending them a position packet with 0 bounty.
_________________
Hyperspace Owner

Smong> so long as 99% deaths feel lame it will always be hyperspace to me
Back to top
View users profile Send private message Add User to Ignore List AIM Address Yahoo Messenger MSN Messenger
.:IceRabbit:.
Newbie


Gender:Gender:Male
Joined: Aug 14 2006
Posts: 15
Offline

PostPosted: Tue Aug 15, 2006 11:07 am    Post subject: Reply to topic Reply with quote

@ Chambahs: I went back 7 pages of topics looking for an answer before I posted and the was on of the few I skipped thinking it had nothing to do with what I was looking for. >.<

@ Dr Brain: Is it there? I use Dev-C++ and if you ever used it, you would know how it had the little referance popup with pointers, like when you type "p->" it tries to finish it. "bounty" or "bty" was not in that window, but its my fault for being lazy and not looking myself.

Thanks again for the replies.
Back to top
View users profile Send private message Add User to Ignore List
Dr Brain
Flip-flopping like a wind surfer


Age:39
Gender:Gender:Male
Joined: Dec 01 2002
Posts: 3502
Location: Hyperspace
Offline

PostPosted: Tue Aug 15, 2006 1:11 pm    Post subject: Reply to topic Reply with quote

I'm sure it's in there somewhere. May be part of a substructure.
Back to top
View users profile Send private message Add User to Ignore List AIM Address Yahoo Messenger MSN Messenger
.:IceRabbit:.
Newbie


Gender:Gender:Male
Joined: Aug 14 2006
Posts: 15
Offline

PostPosted: Tue Aug 15, 2006 3:01 pm    Post subject: Reply to topic Reply with quote

Yup: "killed->position.bounty"

I kept trying killed->pos.bounty. >.<

Thanks for your help.

<You can close the topic now if you please. icon_smile.gif>
Back to top
View users profile Send private message Add User to Ignore List
Animate Dreams
Gotta buy them all!
(Consumer whore)


Age:37
Gender:Gender:Male
Joined: May 01 2004
Posts: 821
Location: Middle Tennessee
Offline

PostPosted: Wed Aug 16, 2006 10:03 am    Post subject: Reply to topic Reply with quote

Topics don't really get closed here, I have a theory that MGB secretly loves bumps.

Anyway, I think this is a really cool concept. I assume people will be depositing their war spoils off at a bank, or something? Anyway, you may want to look through the scoring modules as well. I won't say the scoring modules aren't good, because they do exactly what they're supposed to do which is emulating Subgame's scoring, but they definitely aren't very exciting. Anyway, if you are going to be storing the bounty that they deposit elsewhere, you may want to consider adding it to their score? Also, you may want to watch out... if your ships have items, people may abuse your region automatically ?shipresetting them. Personally, I'd just set it so you have to have at least a certain amount of bounty before you can deposit it.
Back to top
View users profile Send private message Add User to Ignore List Send email Visit posters website AIM Address MSN Messenger
.:IceRabbit:.
Newbie


Gender:Gender:Male
Joined: Aug 14 2006
Posts: 15
Offline

PostPosted: Tue Aug 22, 2006 2:36 am    Post subject: Reply to topic Reply with quote

I know what you mean by the ?shipreset, but actually it will do the opposite. The ship settings will be next to blank and people will buy items to add to their ships. Only difference from other zones is this will be mixed between the two current prizing styles; the items will be one time use, but say you buy 4 bursts and use 2, you will spawn with the remaining 2 when you die/enter the zone.

So really, the shipreset will wipe the player clean of all prizes, so I'll just make a function to reprize the player and call it here, right after death, and after login. icon_smile.gif
Back to top
View users profile Send private message Add User to Ignore List
Display posts from previous:   
Post new topic   Reply to topic    Server Help Forum Index -> ASSS Questions All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum
View online users | View Statistics | View Ignored List


Software by php BB © php BB Group
Server Load: 42 page(s) served in previous 5 minutes.

phpBB Created this page in 0.441579 seconds : 33 queries executed (93.8%): GZIP compression disabled