more updates to namedvars

This commit is contained in:
Fish 2007-01-02 15:15:30 +00:00
parent e0241bdcbc
commit cf36a76eb1
3 changed files with 29 additions and 3 deletions

View file

@ -46,7 +46,12 @@ static hash_t *bothash;
nv_struct nv_bots[] = {
{ "name", NV_STR, offsetof(Bot, name), NV_FLG_RO, -1},
{ "flags", NV_STR, offsetof(Bot, flags), NV_FLG_RO, -1},
{ "set_ulevel", NV_STR, offsetof(Bot, set_ulevel), NV_FLG_RO, -1}
{ "set_ulevel", NV_STR, offsetof(Bot, set_ulevel), NV_FLG_RO, -1},
{ "nick", NV_STR, offsetof(BotInfo, nick), NV_FLG_RO, offsetof(Bot, botinfo)},
{ "altnick", NV_STR, offsetof(BotInfo, altnick), NV_FLG_RO, offsetof(Bot, botinfo)},
{ "user", NV_STR, offsetof(BotInfo, user), NV_FLG_RO, offsetof(Bot, botinfo)},
{ "host", NV_STR, offsetof(BotInfo, host), NV_FLG_RO, offsetof(Bot, botinfo)},
{ "realname", NV_STR, offsetof(BotInfo, realname), NV_FLG_RO, offsetof(Bot, botinfo)}
};
@ -517,6 +522,7 @@ int ns_cmd_botlist( const CmdParams *cmdparams )
}
}
irc_prefmsg( ns_botptr, cmdparams->source, __( "End of Module Bot List", cmdparams->source ) );
dump_namedvars("");
return NS_SUCCESS;
}

View file

@ -48,7 +48,13 @@ nv_struct nv_server[] = {
{ "info", NV_STR, offsetof(Client, info), NV_FLG_RO, -1},
{ "version", NV_STR, offsetof(Client, version), NV_FLG_RO, -1},
{ "flags", NV_INT, offsetof(Client, flags), NV_FLG_RO, -1},
{ "hostip", NV_STR, offsetof(Client, hostip), NV_FLG_RO, -1}
{ "hostip", NV_STR, offsetof(Client, hostip), NV_FLG_RO, -1},
{ "users", NV_INT, offsetof(Server, users), NV_FLG_RO, offsetof(Client, server)},
{ "awaycount", NV_INT, offsetof(Server, awaycount), NV_FLG_RO, offsetof(Client, server)},
{ "hops", NV_INT, offsetof(Server, hops), NV_FLG_RO, offsetof(Client, server)},
{ "numeric", NV_INT, offsetof(Server, numeric), NV_FLG_RO, offsetof(Client, server)},
{ "ping", NV_INT, offsetof(Server, ping), NV_FLG_RO, offsetof(Client, server)},
{ "uptime", NV_INT, offsetof(Server, uptime), NV_FLG_RO, offsetof(Client, server)}
};

View file

@ -49,7 +49,21 @@ nv_struct nv_client[] = {
{ "info", NV_STR, offsetof(Client, info), NV_FLG_RO, -1},
{ "version", NV_STR, offsetof(Client, version), NV_FLG_RO, -1},
{ "flags", NV_INT, offsetof(Client, flags), NV_FLG_RO, -1},
{ "hostip", NV_STR, offsetof(Client, hostip), NV_FLG_RO, -1}
{ "hostip", NV_STR, offsetof(Client, hostip), NV_FLG_RO, -1},
{ "hostname", NV_STR, offsetof(User, hostname), NV_FLG_RO, offsetof(Client, user)},
{ "username", NV_STR, offsetof(User, username), NV_FLG_RO, offsetof(Client, user)},
{ "vhost", NV_STR, offsetof(User, vhost), NV_FLG_RO, offsetof(Client, user)},
{ "awaymsg", NV_STR, offsetof(User, awaymsg), NV_FLG_RO, offsetof(Client, user)},
{ "swhois", NV_STR, offsetof(User, swhois), NV_FLG_RO, offsetof(Client, user)},
{ "userhostmask", NV_STR, offsetof(User, userhostmask), NV_FLG_RO, offsetof(Client, user)},
{ "uservhostmask", NV_STR, offsetof(User, uservhostmask), NV_FLG_RO, offsetof(Client, user)},
{ "flood", NV_INT, offsetof(User, uservhostmask), NV_FLG_RO, offsetof(Client, user)},
{ "is_away", NV_INT, offsetof(User, is_away), NV_FLG_RO, offsetof(Client, user)},
{ "modes", NV_STR, offsetof(User, modes), NV_FLG_RO, offsetof(Client, user)},
{ "Umode", NV_INT, offsetof(User, Umode), NV_FLG_RO, offsetof(Client, user)},
{ "smodes", NV_STR, offsetof(User, smodes), NV_FLG_RO, offsetof(Client, user)},
{ "Smode", NV_INT, offsetof(User, Smode), NV_FLG_RO, offsetof(Client, user)},
{ "ulevel", NV_INT, offsetof(User, ulevel), 0, offsetof(Client, user)}
};