Quake3World.com Forums
     Level Editing & Modeling
        Quake 3: Bot making issue !


Post new topicReply to topic
Login | Profile | | FAQ | Search | IRC




Print view Previous topic | Next topic 
Topic Starter Topic: Quake 3: Bot making issue !

Recruit
Recruit
Joined: 10 Jun 2014
Posts: 5
PostPosted: 06-10-2014 02:35 PM           Profile Send private message  E-mail  Edit post Reply with quote


So I used to make bots with Bot Boom and never had any issues with it. But later I ventured into the coding of C in which the bots use. I still use the .bot files in my scripts, and I found a strange problem that I have no idea why it happens.

This is the Bot Boom file made.
// generated by Bot Boom 1.0
{
name MyBot
funname ^3My^4Bot
model anarki/blue
aifile bots/anarki_c.c
}

My file:
// New Bots :D
{
name AimBot
model sarge/roderick
aifile newbots/aimbot_c.c
}

And I do have all of the AI coding written.

// AIMBOT - Coded by ShoGun
// Date created: 6-9-14
// Version: 1
// Email : nick.james.237@gmail.com
// XFire : FateLord237

#include "chars.h" // Created by MrElusive

skill 1
{
CHARACTERISTIC_NAME "AimBot"
CHARACTERISTIC_GENDER "male"
CHARACTERISTIC_ATTACK_SKILL 0.7
CHARACTERISTIC_WEAPONWEIGHTS "newbots/aimbot_w.c"
CHARACTERISTIC_AIM_SKILL 1
CHARACTERISTIC_AIM_ACCURACY 0.75
CHARACTERISTIC_VIEW_FACTOR 0.95
CHARACTERISTIC_VIEW_MAXCHANGE 360
CHARACTERISTIC_REACTIONTIME 0.1 // Epic swingshot skills

CHARACTERISTIC_CHAT_FILE "newbots/aimbot_t.c"
CHARACTERISTIC_CHAT_NAME "AimBot"
CHARACTERISTIC_CHAT_CPM 400
CHARACTERISTIC_CHAT_INSULT 0.1
CHARACTERISTIC_CHAT_MISC 0.1
CHARACTERISTIC_CHAT_STARTENDLEVEL 0.1
CHARACTERISTIC_CHAT_ENTEREXITGAME 0.1
CHARACTERISTIC_CHAT_KILL 0.1
CHARACTERISTIC_CHAT_DEATH 0.1
CHARACTERISTIC_CHAT_ENEMYSUICIDE 0.1
CHARACTERISTIC_CHAT_HITTALKING 0.1
CHARACTERISTIC_CHAT_HITNODEATH 0.1
CHARACTERISTIC_CHAT_HITNOKILL 0.1
CHARACTERISTIC_CHAT_RANDOM 0.1
CHARACTERISTIC_CHAT_REPLY 0.1

CHARACTERISTIC_CROUCHER 0.05
CHARACTERISTIC_JUMPER 0.95
CHARACTERISTIC_WEAPONJUMPING 0.05
CHARACTERISTIC_GRAPPLE_USER 0.05

CHARACTERISTIC_ITEMWEIGHTS "newbots/aimbot_i.c"
CHARACTERISTIC_AGGRESSION 1
CHARACTERISTIC_SELFPRESERVATION 0.95
CHARACTERISTIC_VENGEFULNESS 1
CHARACTERISTIC_CAMPER 0.1

CHARACTERISTIC_EASY_FRAGGER 0.05
CHARACTERISTIC_ALERTNESS 0.95

CHARACTERISTIC_AIM_ACCURACY_MACHINEGUN 0.4
CHARACTERISTIC_AIM_ACCURACY_SHOTGUN 0.8
CHARACTERISTIC_AIM_ACCURACY_ROCKETLAUNCHER 0.8
CHARACTERISTIC_AIM_ACCURACY_GRENADELAUNCHER 0.5
CHARACTERISTIC_AIM_ACCURACY_LIGHTNING 0.5
CHARACTERISTIC_AIM_ACCURACY_PLASMAGUN 0.5
CHARACTERISTIC_AIM_ACCURACY_RAILGUN 0.9
CHARACTERISTIC_AIM_ACCURACY_BFG10K 0.9
CHARACTERISTIC_AIM_SKILL_ROCKETLAUNCHER 0.8
CHARACTERISTIC_AIM_SKILL_GRENADELAUNCHER 0.8
CHARACTERISTIC_AIM_SKILL_PLASMAGUN 0.3
CHARACTERISTIC_AIM_SKILL_BFG10K 0.2

CHARACTERISTIC_FIRETHROTTLE 0.4
}

skill 4
{
CHARACTERISTIC_NAME "AimBot"
CHARACTERISTIC_GENDER "male"
CHARACTERISTIC_ATTACK_SKILL 0.9
CHARACTERISTIC_WEAPONWEIGHTS "newbots/aimbot_w.c"
CHARACTERISTIC_AIM_SKILL 1
CHARACTERISTIC_AIM_ACCURACY 0.95
CHARACTERISTIC_VIEW_FACTOR 0.95
CHARACTERISTIC_VIEW_MAXCHANGE 360
CHARACTERISTIC_REACTIONTIME 0.1

CHARACTERISTIC_CHAT_FILE "newbots/aimbot_t.c"
CHARACTERISTIC_CHAT_NAME "AimBot"
CHARACTERISTIC_CHAT_CPM 400
CHARACTERISTIC_CHAT_INSULT 0.1
CHARACTERISTIC_CHAT_MISC 0.1
CHARACTERISTIC_CHAT_STARTENDLEVEL 0.1
CHARACTERISTIC_CHAT_ENTEREXITGAME 0.1
CHARACTERISTIC_CHAT_KILL 0.1
CHARACTERISTIC_CHAT_DEATH 0.1
CHARACTERISTIC_CHAT_ENEMYSUICIDE 0.1
CHARACTERISTIC_CHAT_HITTALKING 0.1
CHARACTERISTIC_CHAT_HITNODEATH 0.1
CHARACTERISTIC_CHAT_HITNOKILL 0.1
CHARACTERISTIC_CHAT_RANDOM 0.1
CHARACTERISTIC_CHAT_REPLY 0.1

CHARACTERISTIC_CROUCHER 0.05
CHARACTERISTIC_JUMPER 0.95
CHARACTERISTIC_WEAPONJUMPING 0.05
CHARACTERISTIC_GRAPPLE_USER 0.05

CHARACTERISTIC_ITEMWEIGHTS "newbots/aimbot_i.c"
CHARACTERISTIC_AGGRESSION 1
CHARACTERISTIC_SELFPRESERVATION 0.9
CHARACTERISTIC_VENGEFULNESS 1
CHARACTERISTIC_CAMPER 0.1

CHARACTERISTIC_EASY_FRAGGER 0.05
CHARACTERISTIC_ALERTNESS 0.95

CHARACTERISTIC_AIM_ACCURACY_MACHINEGUN 0.7
CHARACTERISTIC_AIM_ACCURACY_SHOTGUN 0.9
CHARACTERISTIC_AIM_ACCURACY_ROCKETLAUNCHER 0.9
CHARACTERISTIC_AIM_ACCURACY_GRENADELAUNCHER 0.9
CHARACTERISTIC_AIM_ACCURACY_LIGHTNING 0.9
CHARACTERISTIC_AIM_ACCURACY_PLASMAGUN 0.9
CHARACTERISTIC_AIM_ACCURACY_RAILGUN 1
CHARACTERISTIC_AIM_ACCURACY_BFG10K 0.9
CHARACTERISTIC_AIM_SKILL_ROCKETLAUNCHER 0.9
CHARACTERISTIC_AIM_SKILL_GRENADELAUNCHER 0.9
CHARACTERISTIC_AIM_SKILL_PLASMAGUN 0.5 // Can't use plasma well
CHARACTERISTIC_AIM_SKILL_BFG10K 0.9

CHARACTERISTIC_FIRETHROTTLE 0.8
}

skill 5
{
CHARACTERISTIC_NAME "AimBot"
CHARACTERISTIC_GENDER "male"
CHARACTERISTIC_ATTACK_SKILL 0.95
CHARACTERISTIC_WEAPONWEIGHTS "newbots/aimbot_w.c"
CHARACTERISTIC_AIM_SKILL 1
CHARACTERISTIC_AIM_ACCURACY 0.95
CHARACTERISTIC_VIEW_FACTOR 0.95
CHARACTERISTIC_VIEW_MAXCHANGE 360
CHARACTERISTIC_REACTIONTIME 0.01 // Epic quickshot

CHARACTERISTIC_CHAT_FILE "newbots/aimbot_t.c"
CHARACTERISTIC_CHAT_NAME "AimBot"
CHARACTERISTIC_CHAT_CPM 400
CHARACTERISTIC_CHAT_INSULT 0.1
CHARACTERISTIC_CHAT_MISC 0.1
CHARACTERISTIC_CHAT_STARTENDLEVEL 0.1
CHARACTERISTIC_CHAT_ENTEREXITGAME 0.1
CHARACTERISTIC_CHAT_KILL 0.1
CHARACTERISTIC_CHAT_DEATH 0.1
CHARACTERISTIC_CHAT_ENEMYSUICIDE 0.1
CHARACTERISTIC_CHAT_HITTALKING 0.1
CHARACTERISTIC_CHAT_HITNODEATH 0.1
CHARACTERISTIC_CHAT_HITNOKILL 0.1
CHARACTERISTIC_CHAT_RANDOM 0.1
CHARACTERISTIC_CHAT_REPLY 0.1

CHARACTERISTIC_CROUCHER 0.05
CHARACTERISTIC_JUMPER 0.95
CHARACTERISTIC_WEAPONJUMPING 0.05
CHARACTERISTIC_GRAPPLE_USER 0.05

CHARACTERISTIC_ITEMWEIGHTS "newbots/aimbot_i.c"
CHARACTERISTIC_AGGRESSION 1
CHARACTERISTIC_SELFPRESERVATION 1
CHARACTERISTIC_VENGEFULNESS 1
CHARACTERISTIC_CAMPER 0.05

CHARACTERISTIC_EASY_FRAGGER 0.05
CHARACTERISTIC_ALERTNESS 0.95

CHARACTERISTIC_AIM_ACCURACY_MACHINEGUN 1.0
CHARACTERISTIC_AIM_ACCURACY_SHOTGUN 1.0
CHARACTERISTIC_AIM_ACCURACY_ROCKETLAUNCHER 1.0
CHARACTERISTIC_AIM_ACCURACY_GRENADELAUNCHER 1.0
CHARACTERISTIC_AIM_ACCURACY_LIGHTNING 1.0
CHARACTERISTIC_AIM_ACCURACY_PLASMAGUN 1.0
CHARACTERISTIC_AIM_ACCURACY_RAILGUN 1.0
CHARACTERISTIC_AIM_ACCURACY_BFG10K 1.0
CHARACTERISTIC_AIM_SKILL_ROCKETLAUNCHER 1.0
CHARACTERISTIC_AIM_SKILL_GRENADELAUNCHER 1.0
CHARACTERISTIC_AIM_SKILL_PLASMAGUN 1.0
CHARACTERISTIC_AIM_SKILL_BFG10K 1.0

CHARACTERISTIC_FIRETHROTTLE 1.0
}


// Aimbot Chat - Coded by ShoGun
// Date created: 6-9-14
// Version: 1
// Email : nick.james.237@gmail.com
// XFire : FateLord237

chat "AimBot"
{
#include "teamplay.h"
//
//
type "game_enter" // Enters game
{
"Hello everyone!"
"Prepare to be annhilated."
"None of you have any chance"
"Hello! Goodluck and have fun!"
"You won't survive tonight."
"Heh, good luck I guess."
"Well, this place looks pretty big."
"Anyone up for some Freezetag after this round?"
"You come for another lesson?", 1, "I can supply that for sure!"
}
// When bot leaves game
type "game_exit"
{
"Catch ya later folks."
"Peace."
"L8R"
"TRS on TOP!! I'm out."
"Cya everyone"
"This lesson is now over."
"Bye"
}
// When the round begins
type "level_start"
{
"When I leave this server, your blood will be dripping from my face."
"Consider yourself beat already."
"Pray to your deity that you won't be thrown around too hard."
"Let's get it on."
"Let's dance warrior princess."
}
// When level ends, and bot is not first or last.
type "level_end"
{
"Through agonizing pain, as I look down, I see failure. Looking up I see what I have failed to achieve."
"Good Game, though I have not done my fair level."
}
// When bot wins
type "level_end_victory"
{
"All the blood falls onto me."
"Where's my medal?"
"Good game, although my aimbot is not working correctly."
"I could've eaten you up ten times worse."
"I killed you so fast, I saw blue blood."
}
// When bot gets last place
type "level_end_lose"
{
"I am a failure."
}
// When bot is hit when typing.
type "hit_talking"
{
"Hey!"
"I should ban you."
}
// Bot is hit with an opponent's shot, but does not die.
type "Hit_nodeath"
{
"Get your projectiles out of my walking zone."
"Nice hit. Now try killing me."
}
// Bot hits opponent but doesn't kill it.
type "hit_nokill"
{
"You shouldn't have moved out of my shot!"
"Target practice."
}
// Bot gets telefragged
type "death_telefrag"
{
"Ah, so now you take my space, eh?"
}
// Bot derps and falls too far
type "death_cratered"
{
"Hey, you might wanna watch your step right there."
"Ouch."
}
// When bot dies in lava
type "death_lava"
{
"And now the liquid of Hell burns into my flesh."
"Ouch."
}
// Bot dies in slime
type "death_slime"
{
"Nuclear toxins !! Ahh !! My all time fear!"
}
// Bot drowns
type "death_drown"
{
"And now I can't swim."
}
// When bot suicides, such as blows himself up with a rocket or similar.
type "death_suicide"
{
"Ow" // Creative, hmm?
}
// The rest of these speak for themselves..
type "death_gauntlet"
{
"That hellish saw rips into my flesh, causing eternal wounds."
"That might need a stitch or 2."
"Ouch."
}
type "death_rail"
{
"You hold a wasp, don't let it sting you."
"I will take that railgun of yours and bash you in the head with it."
"Nice railgun color xD"
"I think I have to go pee. Oh wait, I'm good.."
"Can I kill you?"
"I could really go for some muffins right now.."
}
type "death_bfg"
{
"What was that?!"
"A flash of green and I turn into red gibs."
"Weeeell where'd you get that machine? Does it believe in love at first sight?"
}
type "death_insult"
{
"I have a mess to clean up in my level now."
"When I come back I'll kill you in your dreams."
"You don't scare me."
}
type "death_praise"
{
"^5>^4*^7Nice^4*^5< >^4*^7Shot^4*^5<"
}
type "kill_rail"
{
"I have mastered the ways of the wasp. Thank you, Xaero."
"There's no escape from this weapon I possess. It is too fast."
"The rail moves at the speed of light, giving you a plank length to get the hell out of my shot."
"In one second, the rail I have shot to kill you will have rapped around Earth 8 times."
}
type "kill_gauntlet"
{
"You shouldn't have fell for that."
}
type "kill_suicide" // When the bot's opponent suicides.
{
"Good going, ", 0, "."
}
type "kill_insult"
{
"For I am the metaphorical elephant. What are you? An ant."
"Oh I just got bored of waiting for you to get me."
"The mold on the peasant's bread challenges me. What next?"
"Look at what they gave to me. Allow me to wipe your blood stain off your shirt."
"If the scrubs they challenge me with become more like this one, they'll cut my pay!"
"I'm bored, I want to go to Razer Freeze."
"Maybe the folk at Massacre Deathmatch aren't as bad as you."
}
type "kill_praise"
{
"Needn't worry,", botnames, " also fell to me."
"You aren't the first and only."
"A true warrior makes mistakes."
"Don't give up, you should see how miserable Crash fell to me."
"I can show you screenshots of even worse beatings than this."
"You are a true fighter, though I must have my sunshine."
}
type "random_insult"
{
"You shoot like a drunk man."
"Your miserable playing skills are giving me a headache."
"I fear that when I take a dump you'll fall out."
}
type "random_misc"
{
"Have you seen the movie I Am Legend?"
"I'd like to go to the Idiots With Rail 1V1 Server soon."
"Maybe someday the Mongolian Championship server will return."
"Angel is just a robot version of Lucy."
"Biker gives me nightmares."
}
} // End AimBot chat.


// Aimbot Weapon Weights - Coded by ShoGun
// Date created: 6-9-14
// Version: 1
// Email : nick.james.237@gmail.com
// XFire : FateLord237
//
// Weapon weights simply means which weapons the bot is most driven to.

#include "inv.h"

#define W_GAUNTLET 1
#define W_MACHINEGUN 15
#define W_SHOTGUN 50
#define W_GRENADELAUNCHER 5
#define W_ROCKETLAUNCHER 100
#define W_PLASMAGUN 60
#define W_RAILGUN 400
#define W_BFG10K 200
#define W_LIGHTNING 30
#define W_GRAPPLE 5

// Weaponweight Coding - By MrElusive
#include "fw-weap.c"


// Aimbot - Inventory Weights - Coded by ShoGun for >TRS< Server
// Date created: 6-9-14
// Version: 1
// Email : nick.james.237@gmail.com
// XFire : FateLord237

#include "inv.h"

// Initial Weapon Weights
#define W_GAUNTLET 1
#define W_MACHINEGUN 15
#define W_SHOTGUN 50
#define W_GRENADELAUNCHER 5
#define W_ROCKETLAUNCHER 100
#define W_PLASMAGUN 60
#define W_RAILGUN 400
#define W_BFG10K 200
#define W_LIGHTNING 30
#define W_GRAPPLE 5

// Armor/Health Weights
#define FS_ARMOR 20
#define FS_HEALTH 100

// The bot has the weapons, so the weights change a little.
#define GWW_GAUNTLET 10
#define GWW_MACHINEGUN 30
#define GWW_SHOTGUN 50
#define GWW_GRENADELAUNCHER 20
#define GWW_ROCKETLAUNCHER 70
#define GWW_PLASMAGUN 70
#define GWW_RAILGUN 300
#define GWW_BFG10K 150
#define GWW_LIGHTNING 20
#define GWW_GRAPPLE 10

// Flag Weight
#define FLAG_WEIGHT 200 // AimBot likes to get the flag.

// More weights :D
#include "fw_items.c"


The main issue is, the bot can be found on the bot selector in single player. However, it can't be added because somehow the skills can't be found. The exact error message is: "couldn't load newbots/aimbot_c.c" However, the files aimbot_c.c, aimbot_w.c, aimbot_i.c, and aimbot_t.c are in a pk3 file called sgbots-v1.pk3. And the .bot files for MyBot (by Bot Boom) and AimBot are both in the scripts folder located within the Baseq3 folder. As you can see, the Bot Boom generator can somehow load .c files from Pak0.pk3, but my .bot file can't load a .c file from another pk3 in the same directory as pak0.pk3.

Does anyone have a clue for this issue?



_________________
Quake 3 InGame Name: >TRS<ShoGun


Top
                 

Commander
Commander
Joined: 22 Jul 2011
Posts: 139
PostPosted: 06-11-2014 02:41 PM           Profile Send private message  E-mail  Edit post Reply with quote


No idea, just to say something: Did you put the bot files (the aimbot_c.c and the others) in botfiles/newbots, inside the pk3 file?




Top
                 

Recruit
Recruit
Joined: 10 Jun 2014
Posts: 5
PostPosted: 06-11-2014 05:27 PM           Profile Send private message  E-mail  Edit post Reply with quote


No, did I have to?
EDIT: Tried that, didn't work DX



_________________
Quake 3 InGame Name: >TRS<ShoGun


Top
                 

Commander
Commander
Joined: 25 Nov 2006
Posts: 101
PostPosted: 06-11-2014 08:49 PM           Profile Send private message  E-mail  Edit post Reply with quote


I think q3 only read botfiles from the botfiles/bots/
So the botfiles/newbots/ structure doesn't work...



_________________
slugs and rockets


Top
                 

Commander
Commander
Joined: 22 Jul 2011
Posts: 139
PostPosted: 06-12-2014 02:06 PM           Profile Send private message  E-mail  Edit post Reply with quote





Top
                 

Recruit
Recruit
Joined: 10 Jun 2014
Posts: 5
PostPosted: 06-12-2014 05:25 PM           Profile Send private message  E-mail  Edit post Reply with quote


The bots/aimbot_c.c didn't work , but thanks for the guide.



_________________
Quake 3 InGame Name: >TRS<ShoGun


Top
                 

\kill
\kill
Joined: 02 Apr 2003
Posts: 947
PostPosted: 06-13-2014 04:56 AM           Profile Send private message  E-mail  Edit post Reply with quote


What Takkie said ... botfiles can only be read from the botfiles/bots folder structure within a .pk3 which you can make yourself ... you can do all of this using a notepad to alter the .c files and you can make a .pk3 file using a Winzip program to make a pk3 file by naming it "botname.pk3". The easiest way to make your own bot, is by extracting the botfiles from one of the bots in the pak4.pk3 and then changing the number within the botfiles (sarge_c sarge_i sarge_t sarge_w) to your own preference. Create a yourbotsname.bot using a notepad as well and put it within a scripts folder. Drag the botfiles and the .bot in their folder structure into the Winzip program which you have named yourbotsname.pk3, then put the .pk3 within your baseq3 folder. Using a bot program is pointless when you can do it all manually this way.




Top
                 

Commander
Commander
Joined: 22 Jul 2011
Posts: 139
PostPosted: 06-13-2014 01:42 PM           Profile Send private message  E-mail  Edit post Reply with quote


Have you checked that sv_pure is 0?

It might help working with loose files instead of a pk3.

I don't know but since a bot is defined like this:
Code:
{
name      Orbb
model      orbb
aifile   bots/orbb_c.c
}

It makes sense that other folder than "bots" could be used, only if it's inside "botfiles".




Top
                 

Recruit
Recruit
Joined: 10 Jun 2014
Posts: 5
PostPosted: 06-14-2014 04:10 AM           Profile Send private message  E-mail  Edit post Reply with quote


This was resolved. I made it a but easier by using pk3 Editor called Slade3. (I know it's for Doom, but Quake has the same Compression Method and it can make quake 3 pk3's a well). Anyway, I just moved the aimbot_c etc to pak0 and in the aimbot.bot I just used botfiles/bots . Thank's for the help guys.



_________________
Quake 3 InGame Name: >TRS<ShoGun


Top
                 

Commander
Commander
Joined: 22 Jul 2011
Posts: 139
PostPosted: 06-14-2014 07:59 AM           Profile Send private message  E-mail  Edit post Reply with quote


Good, though inserting files in pak0 isn't very handy, I would keep trying to use loose files.

You can also make a pk3 with Winzip or Winrar but you have to choose "Zip" and "No compression".




Top
                 

Cool #9
Cool #9
Joined: 01 Dec 2000
Posts: 44139
PostPosted: 06-14-2014 10:54 PM           Profile   Send private message  E-mail  Edit post Reply with quote


Yeah, modifying pak0.pk3 is a very bad idea. In fact, now that you've added files to it, I'm not sure removing those files again will fix it because it might still be different than the original on a byte level. If your pak files are different than those on a pure server, you can't connect to it and play on it.

Best thing to do now is manually copy pak0.pk3 back from the CD to your hard disk.




Top
                 

Cool #9
Cool #9
Joined: 01 Dec 2000
Posts: 44139
PostPosted: 06-14-2014 10:57 PM           Profile   Send private message  E-mail  Edit post Reply with quote


You could try using the bot maker tool in the Quake Toolkit. It generates all the required files for you.

http://theenginesofcreation.com/Content ... r/qtoolkit




Top
                 
Quake3World.com | Forum Index | Level Editing & Modeling


Post new topic Reply to topic


cron
Quake3World.com
© ZeniMax. Zenimax, QUAKE III ARENA, Id Software and associated trademarks are trademarks of the ZeniMax group of companies. All rights reserved.
This is an unofficial fan website without any affiliation with or endorsement by ZeniMax.
All views and opinions expressed are those of the author.