Server Help

ASSS Questions - Per Ship Weapon Settings

z.alpha+ - Thu Oct 12, 2006 4:30 pm
Post subject: Per Ship Weapon Settings
I've been trolling the web looking for ASSS module code for examples and the only thing i've really found is Smog's site and a few hyperspace mods on the wiki site. Are there any more mod depositories for asss mod's? Everything on SSDL looks like a mirror of smog's site.

At any rate, I'm looking for a way to have per player weapon settings, much like Hyperspace, in which you have to level up / purchase weapons.

I understand the basics of ASSS now, working with interfaces, creating callbacks etc. There are somethings that are eluding me, like creating custom packets without getting a checksum error, etc. At any rate, I was hoping to get more exampled, or pre-existing modules, so I could study them and see how they work.

Is there a way to have different settings such as multifire angles, bullet life time, bullet damage level, etc per player, or is this handled client side, and therefore only limited to different ship hulls.

Also, I was wondering if someone had some quick example code of writing to and from a mysql database. I've already connected to the mysql through asss, but I couldn't find anything that provided a pre-built interface for executing SQL statement to and from mysql.

Any help you regulars could throw my way would be appreciated. I've been dabbling with the code for a few days, and i'm wanting to start creating some exotic modules and was hoping to get a good boost in my learning curve.
Cyan~Fire - Thu Oct 12, 2006 5:34 pm
Post subject:
I'm not really qualified to answer all of your questions, but I can say a few things.

First of all, it's Smong. icon_razz.gif Anyway, you probably won't have to use mysql for this, you should be able to do just fine with persistent data (see the ASSS developer's guide).

Quote:
creating custom packets without getting a checksum error

What are you trying to send?

Quote:
Is there a way to have different settings such as multifire angles, bullet life time, bullet damage level, etc per player, or is this handled client side, and therefore only limited to different ship hulls.

Some of this could probably be accomplished with per-player settings, but I'm no expert on this, so I'm gonna wait for some one else to answer. icon_smile.gif

Just read through the developer's guide and look at some of the modules that come with ASSS (not the core stuff, but the cool stuff like the fg_ modules).

Thanks for the polite and easily understandable request.
z.alpha+ - Thu Oct 12, 2006 6:39 pm
Post subject:
i'm going to be using mysql to store some long term data, that i need to be very flexible with (ie , export to php, tab-delminited lists, etc). Mostly general web stuff, of course. In the long-term mysql is going to allow me to have a better handle on the data.

As far as creating a packet, i was messing around with the fake interface, and was needing to send some player position data, but was getting the badlen checksum error.

I was using the autoturret module as a learning resource, but could never quite get the packet stuff in place, which is pretty important because some of the modules i'm laying out now is going to require some custom packet work.

anyway thanks for the repsonse, i'll check out the fg_[..] modules, i don't think i've looked over them yet.

btw, sorry smong if i misspelled your name, there isn't much i don't misspell.
Bak - Thu Oct 12, 2006 8:37 pm
Post subject:
You can get a lot of modules in the ASSS Custom Code forum. As for the fake thing, isn't there a fakePosition function in the interface?
Smong - Fri Oct 13, 2006 5:25 am
Post subject:
I'm not sure how you can go wrong if you're working off the autoturret code.

If you go to the biller section on my site and download pocob2 there should be examples in there that use asss's mysql module.

It is true some (weapon) things are clientside. You need to understand how the game works to know what happens where, it doesn't look like you do. Just ask more specifically and we can give you an answer. To start you off multifire angle, weapon speed and weapon alive time are done client side. This doesn't leave you with much, think of per-player settings as just another way of granting prizes to people.

Weapon damage level is clientside too, but can be used for "half shields". I'm attaching a module called xp which was my attempt at a UWC3 (ultimate warcraft 3, a mod for cs1.6) mod for SS. There is a skill called "leather skin" that gradually reduces the amount of damage you received depending on how "leveled up" you are. It's commented out in the code since you can't do per-player settings from python.
Dr Brain - Fri Oct 13, 2006 7:17 am
Post subject:
For the most part, anything I don't change in Hyperspace shouldn't be changed. Bullet alive time and multifire angle are big no-no's. Bullet damage CAN be changed per player, but it changes it for all ships.
z.alpha+ - Fri Oct 13, 2006 9:25 am
Post subject:
fyi: ( i think most people reading this already know, but for the curious and uninformed.)

the interface for the database is located at:

src/include/reldb.h
z.alpha+ - Fri Oct 13, 2006 12:17 pm
Post subject:
Bak wrote:
isn't there a fakePosition function in the interface?


not that i see

fake.h:

Code: Show/Hide

/* dist: public */

#ifndef __FAKE_H
#define __FAKE_H


#define I_FAKE "fake-1"

typedef struct Ifake
{
   INTERFACE_HEAD_DECL
   /* pyint: use */

   Player * (*CreateFakePlayer)(const char *name, Arena *arena, int ship, int freq);
   /* pyint: string, arena, int, int -> player */
   int (*EndFaked)(Player *p);
   /* pyint: player -> int */
} Ifake;


#endif


am i missing something here?
z.alpha+ - Fri Oct 13, 2006 12:34 pm
Post subject:
the fakeposition is in the game interface.....
All times are -5 GMT
View topic
Powered by phpBB 2.0 .0.11 © 2001 phpBB Group