Author Topic: AI-ing (.py files, coding, nose-orienting R+D, and help)  (Read 160997 times)

Offline roboman2444

  • Ultra Heavyweight
  • Posts: 1212
  • Rep: 0
  • Linux, Nexuiz, Quake, and Darkplaces lover.
    • View Profile
    • http://www.freewebs.com/teamrckm
    • Awards
AI-ing (.py files, coding, R+D, and help)
« Reply #180 on: October 14, 2009, 09:05:18 PM »
there might be a way without coding...
just have the smartzone not a smartzone, but an actual component. and the sound that the components would make when something hits it or it hits something would be said sound.
is this practical?

the only problem is that i need it to do damage to the chassis when it gets hit... because the smartzone would just let the bullet thing through and hit the chassis.
oh this is for rdma2 and i need some good gunz(shotgun sniper machinegun, and maybe roket launcher, grenade launcher....)
i also want the robots to respawn when they die, but it would also put +1 pt for the robot who hit it last and -1 to the robot that died.

is there any way to do this in the arena py? or is there a different way.

plz,  need all the help i can get so rdma2 can be released sooner.
Real life robotics team www.teamrckm.tk
Real life game studio www.v2games.tk


Offline Pwnator

  • *
  • Posts: 6676
  • Rep: 15
  • Awards BOTM Winner
    • View Profile
    • http://pwnator.tumblr.com
    • Awards
  • See profile for gamer tags: Yes
AI-ing (.py files, coding, R+D, and help)
« Reply #181 on: October 15, 2009, 12:45:10 AM »
Ah, this is quite interesting. Is it possible to turn the SZ into a 'weapon' instead of 'power' and still have the 'passthru' capability working? If it does, just amp up the HPs to a high value and add a 'damagesounds' line. :D
Clash Cubes 1 - Grey Matter (Runner-Up)
King of Karnage - Sideshow Freak (Runner-Up, Best Engineered)
Rust In Pieces - Paper Cut 3 (Grand Champion, Most Dangerous Bot)
Wheely Tag Tournament - Ion Thruster (Grand Champion, along with Ounces' DiSemboweLment)
UK vs USA - Dark Striker (Grand Champion)
Rust In Pieces 2 - Claymore (Runner-Up, Favourite Bot)
BBEANS 6 - Infection 4 (Runner-Up)
RA2 Team Championships - Serious Business, Skeksis (Runner-Up, along with Scrappy, S_M, and Badnik)
RA2 Team Championships 2 - The Other Stig (Runner-Up, along with Scrappy, S_M, Badnik, 090901, and R1885)
Replica Wars 3 - Abaddon (Runner-Up, Luckiest Bot)
BroBots - wheebot & yaybot (Runner-Up)
Robo Zone 2 - Dipper (4th place, Survival Champion, & Best Axle Bot)
ARBBC - The Covenant (3rd place, BW Rumble Winner, Most Feared BW)

Offline JoeBlo

AI-ing (.py files, coding, R+D, and help)
« Reply #182 on: October 15, 2009, 01:03:49 AM »
I have a feeling (and I plan on testing it soon for my new anti ballast) the pass through ability is in the "base" smartzone inside the text file, Smartzones are just colored GMF boxes that are turned partially transparent if im not mistaken.

Edit: On second thought it might be possible with

passthru = smart_zone

I might try that out for you roboman

Offline JoeBlo

AI-ing (.py files, coding, R+D, and help)
« Reply #183 on: October 15, 2009, 01:19:38 AM »
it doesnt work,

smartzones need the "base" smartzone to be attached anywhere they want, which doesnt handle the damage sounds line in the txt file



another idea though.....

making a tiny component that can be wired to a control and when the control is hit it plays the noise, (seen it done before)

then add a smartzone to the robot with a name written in a .py to trigger that control

when the "projectile" goes through the smart zone it will trigger the control that will make the component play the noise

:-D

Offline Naryar

  • Posts: 23283
  • Rep: 21
  • hybrids oui oui
    • http://www.youtube.com/us
  • Awards BOTM Winner
    • View Profile
    • Awards
  • Skype: TheMightyNaryar
AI-ing (.py files, coding, R+D, and help)
« Reply #184 on: October 15, 2009, 05:51:21 AM »
https://gametechmods.com/uploads/files/SZSpinner.rar

Omni.py that uses a smartzone rather than a range value for activating it's spinning weapon.

Doesn't works :pissd:

Offline Pwnator

  • *
  • Posts: 6676
  • Rep: 15
  • Awards BOTM Winner
    • View Profile
    • http://pwnator.tumblr.com
    • Awards
  • See profile for gamer tags: Yes
AI-ing (.py files, coding, R+D, and help)
« Reply #185 on: October 15, 2009, 05:54:30 AM »
I tried using that to AI Magnetar before I used FBS_1. I won't stop spinning. XD
Clash Cubes 1 - Grey Matter (Runner-Up)
King of Karnage - Sideshow Freak (Runner-Up, Best Engineered)
Rust In Pieces - Paper Cut 3 (Grand Champion, Most Dangerous Bot)
Wheely Tag Tournament - Ion Thruster (Grand Champion, along with Ounces' DiSemboweLment)
UK vs USA - Dark Striker (Grand Champion)
Rust In Pieces 2 - Claymore (Runner-Up, Favourite Bot)
BBEANS 6 - Infection 4 (Runner-Up)
RA2 Team Championships - Serious Business, Skeksis (Runner-Up, along with Scrappy, S_M, and Badnik)
RA2 Team Championships 2 - The Other Stig (Runner-Up, along with Scrappy, S_M, Badnik, 090901, and R1885)
Replica Wars 3 - Abaddon (Runner-Up, Luckiest Bot)
BroBots - wheebot & yaybot (Runner-Up)
Robo Zone 2 - Dipper (4th place, Survival Champion, & Best Axle Bot)
ARBBC - The Covenant (3rd place, BW Rumble Winner, Most Feared BW)

Offline Trovaner

  • *
  • Posts: 1222
  • Rep: 32
    • View Profile
    • Awards
AI-ing (.py files, coding, R+D, and help)
« Reply #186 on: October 15, 2009, 12:20:27 PM »
Quote from: Somebody;72957
Is there a way to make an AI for flail spinners that would use something along the lines of Melty brain to move? i know that I can drive those spinners but AI doesn't work for it.
So you want a SnS AI that can rotate its weapons and chassis while still moving toward the opponent... I think all you would need to do is add these (don't repeat things if they are already there, though). Later if I have time, I'll do some actual testing and uploading but I'm pretty sure I have everything you need listed below: (I took it directly from Omni.py so it could be optimized a little better but it should work like this)
Code: [Select]
   def __init__(self, **args):
        self.triggers = ["Fire"]
        self.spin_range = 3.0

    def Tick(self):
        # fire weapon
        if self.weapons:

            # spin up depending on enemy's range
            enemy, range = self.GetNearestEnemy()
           
            if enemy is not None and range < self.spin_range:
                self.Input(&quot;Spin&quot;, 0, 1)
            elif self.GetInputStatus(&quot;Spin&quot;, 0) != 0:
                self.Input(&quot;Spin&quot;, 0, 0)


Quote from: roboman2444;72975
there might be a way without coding...
just have the smartzone not a smartzone, but an actual component. and the sound that the components would make when something hits it or it hits something would be said sound.
is this practical? This would be completely possible. All that I think you would need to do is include 'damagesounds = sounds\Whatever.wav' in the text file (although, I've never tried do this with cannons, I'm pretty sure it would still work).

the only problem is that i need it to do damage to the chassis when it gets hit... because the smartzone would just let the bullet thing through and hit the chassis. I'm not sure exactly but I think by removing the collisions (from either the GMF or the text file) would result in damagesounds, piercing and concussion to not work.

If you were to add a little bit of possibly laggy programming to the Arena.py, I think you could make any damage done to the other components (could be made to work with only specific components, too) result in damage to the chassis or both the chassis and the component.


oh this is for rdma2 and i need some good gunz(shotgun sniper machinegun, and maybe roket launcher, grenade launcher....) If you haven't already, take a look at Megaturdbomb's cannons and use the resizer that I made and linked to somewhere on these forums (or one of the other two component resizers) to manipulate/distort them into new shapes and sizes that would resemble any of the components that your asking for. Just be sure to change the folders, names, and text files so that it doesn't cause problems for other people...

i also want the robots to respawn when they die, but it would also put +1 pt for the robot who hit it last and -1 to the robot that died. Madiaba and I have been looking for coding that could respawn bots back into their original positions but, currently, it looks like it is coded within the EXE and is only available to the Practice Arena. You could make bots drive/get pushed back or towards a location but just be aware that it is very difficult to flip/turn a bot back into the upright position. Adding and subtracting points is completely possible from within the Arena.py or the AI.py using 'plus.addPoints(BotID, Points)'. To subtract points, just use a negative number.

By checking headings and coordinates between bots, you could make the Arena.py generate the sounds and do the damage but it may get a little laggy at times.

Hope this helps.

Edit: For those of you listing AI stuff (above), he also wants it work with human controlled bots so anything that has to do with using a SZ wouldn't work because, to my knowledge, none of the codes in my notes are capable of reading the contents of a SZ attached to a human controlled bot. Also, for an AI bot to play a noise you wouldn't need a custom component with a button to activate a sound because there are codes that allow you to play sound files from within the .py file.

Offline roboman2444

  • Ultra Heavyweight
  • Posts: 1212
  • Rep: 0
  • Linux, Nexuiz, Quake, and Darkplaces lover.
    • View Profile
    • http://www.freewebs.com/teamrckm
    • Awards
AI-ing (.py files, coding, R+D, and help)
« Reply #187 on: October 15, 2009, 01:57:17 PM »
thanks... i am not good at coding in py but ill try.
Real life robotics team www.teamrckm.tk
Real life game studio www.v2games.tk


Offline roboman2444

  • Ultra Heavyweight
  • Posts: 1212
  • Rep: 0
  • Linux, Nexuiz, Quake, and Darkplaces lover.
    • View Profile
    • http://www.freewebs.com/teamrckm
    • Awards
AI-ing (.py files, coding, R+D, and help)
« Reply #188 on: October 16, 2009, 04:39:29 PM »
dp!!!!!
weeeeel i think i have a simpler solution(and it will also help w/ the character animations)
can a bots ai take keyboard input? if so i can just have the bots be aied and have keyboard input for all of the control stuff.
Real life robotics team www.teamrckm.tk
Real life game studio www.v2games.tk


Offline nicsan2009

  • Ultra Heavyweight
  • Posts: 1836
  • Rep: 5
  • Here we go again!
    • View Profile
    • Awards
  • See profile for gamer tags: Yes
AI-ing (.py files, coding, R+D, and help)
« Reply #189 on: October 16, 2009, 05:53:28 PM »
If you have a chopbot and want to replace a spinner how would that work?
Hosted 2 Legit 2 Quit tourney Congrats Somebody
Hosted 2 Legit 2 Quit 2 congrats to Plazmic Inferno as well as Somebody (again)
Hosted RA2 World Cup Congrats to Senstro
Hosted TGRR congrats to 090901
ITAT Tournament- Champion
Beetle Bashers- Champion
Father and Son Tournament 2- Champion
GTM All Stars- HW Champion; MW runner up
Father and Son Tournament- Runner up
All Time Record 51-36

Offline Trovaner

  • *
  • Posts: 1222
  • Rep: 32
    • View Profile
    • Awards
AI-ing (.py files, coding, R+D, and help)
« Reply #190 on: October 16, 2009, 09:53:30 PM »
Keyboard input is currently not accessible via python in RA2. You can read up on the subject if you would like here, though... Currently, the closest things to it would be to use the practice arena buttons (which are only available to the practice arena) or some python coding from within the FPS window...

@nicsan2009: I'm not sure I know what you mean...

Offline roboman2444

  • Ultra Heavyweight
  • Posts: 1212
  • Rep: 0
  • Linux, Nexuiz, Quake, and Darkplaces lover.
    • View Profile
    • http://www.freewebs.com/teamrckm
    • Awards
AI-ing (.py files, coding, R+D, and help)
« Reply #191 on: October 17, 2009, 08:53:37 AM »
the main.py imports all of the c++ commands... hmmm can we make a c++ script that gets imported? if so we might be able to even have explosions in it!(for rokets and grenade launchers)
Real life robotics team www.teamrckm.tk
Real life game studio www.v2games.tk


Offline Badnik96

  • tired of your shit
  • *
  • Posts: 17537
  • Rep: 3
  • Awards BOTM Winner
    • View Profile
    • Awards
AI-ing (.py files, coding, R+D, and help)
« Reply #192 on: October 17, 2009, 09:15:43 AM »
Quote from: Trovaner;73318
Keyboard input is currently not accessible via python in RA2. You can read up on the subject if you would like here, though... Currently, the closest things to it would be to use the practice arena buttons (which are only available to the practice arena) or some python coding from within the FPS window...

@nicsan2009: I'm not sure I know what you mean...


what i think he means is that in Bindings.Py, if you have an axebot under Chopper.Py and you want to replace it with a spinner that uses Spinner.Py.

I wish to know too because I have been curious about this for AGES.

Offline Madiaba

AI-ing (.py files, coding, R+D, and help)
« Reply #193 on: October 17, 2009, 10:44:20 AM »
Several of us have been looking for a way to facilitate keyboard input. But so far no one's found a practical, worth-while way. And yes, there are MANY things that could be done if this became possible. Would be nice.
Input is appreciated. :)
-Arrogance is a quantity devoid of quality...
-As a client once told me "This is my story, and it's sticking to me!"
-Relationships these days are like the 'Arrival' section of the airport: a lot of baggage is being revealed in one place, and not a lot of it is being correlated to its real owners...

Offline roboman2444

  • Ultra Heavyweight
  • Posts: 1212
  • Rep: 0
  • Linux, Nexuiz, Quake, and Darkplaces lover.
    • View Profile
    • http://www.freewebs.com/teamrckm
    • Awards
AI-ing (.py files, coding, R+D, and help)
« Reply #194 on: October 17, 2009, 12:29:30 PM »
what about the main.py if that imports scripts, then we could just have it import the needed scripts for the headshot, respawn, character animation...
Real life robotics team www.teamrckm.tk
Real life game studio www.v2games.tk


Offline Naryar

  • Posts: 23283
  • Rep: 21
  • hybrids oui oui
    • http://www.youtube.com/us
  • Awards BOTM Winner
    • View Profile
    • Awards
  • Skype: TheMightyNaryar
AI-ing (.py files, coding, R+D, and help)
« Reply #195 on: November 16, 2009, 10:53:13 AM »
https://gametechmods.com/uploads/files/FBSPlus.rar

Yes, that's the AI that supports my last showcased bots. FBS.py with supported spinning weapon.

I am confident it can improve the movement of a shell spinner if wired right.

Last note: make sure both the spinner and the bot spin in the same direction or you'll ruin everything.

Offline G.K.

  • *
  • Posts: 12157
  • Rep: 10
  • Striving for a good personal text since 1994.
    • View Profile
    • Awards
Re: AI-ing (.py files, coding, R+D, and help)
« Reply #196 on: December 01, 2009, 02:32:17 PM »
what .py should I use for a robot that is primarily a rammer but also has a spinning disc? Help would be much appreciated. Thanks.
My above post explains everything about everything.

Host of: Wheely Tag, Back To The Beginnings, BTTB 2, BTTB 3, BTTB 4, & BTTB V.

Heavy Metal: Champion (Mockery of the Whole Concept)
Robotic International Wars Series 1: Champion (Minifridge 6)
RA2 Team Championships 1 & 2: Champion (High Speed Train & Upthrust - as part of Naryar's Not Quite Evil Council of Doom)

Runner Up in: The Amazing Rage (Team Fedex), R0B0NOVA (Zaphod Stock), Steel Warzone (Inception of Instability), Box of Nightmares (Gicquel), Wheely Tag (Minifridge the Second)

Clash Cubes IV: 5th place (Fretless)
BBEANS 6: Rumble Winner & 6th Place (Minifridge 4)

Offline somestrangeguy

  • *
  • Posts: 2068
  • Rep: 2
  • If you can read this, your monitor is turned on.
  • Awards BOTM Winner
    • View Profile
    • Awards
Re: AI-ing (.py files, coding, R+D, and help)
« Reply #197 on: December 01, 2009, 02:33:33 PM »
I say OmniRam because that atleast supports smartzones, i dont remember if it suppoerted spining weapons aswell.

Offline G.K.

  • *
  • Posts: 12157
  • Rep: 10
  • Striving for a good personal text since 1994.
    • View Profile
    • Awards
Re: AI-ing (.py files, coding, R+D, and help)
« Reply #198 on: December 01, 2009, 02:38:18 PM »
Thanks SSG.
My above post explains everything about everything.

Host of: Wheely Tag, Back To The Beginnings, BTTB 2, BTTB 3, BTTB 4, & BTTB V.

Heavy Metal: Champion (Mockery of the Whole Concept)
Robotic International Wars Series 1: Champion (Minifridge 6)
RA2 Team Championships 1 & 2: Champion (High Speed Train & Upthrust - as part of Naryar's Not Quite Evil Council of Doom)

Runner Up in: The Amazing Rage (Team Fedex), R0B0NOVA (Zaphod Stock), Steel Warzone (Inception of Instability), Box of Nightmares (Gicquel), Wheely Tag (Minifridge the Second)

Clash Cubes IV: 5th place (Fretless)
BBEANS 6: Rumble Winner & 6th Place (Minifridge 4)

Offline G.K.

  • *
  • Posts: 12157
  • Rep: 10
  • Striving for a good personal text since 1994.
    • View Profile
    • Awards
Re: AI-ing (.py files, coding, R+D, and help)
« Reply #199 on: December 04, 2009, 10:54:39 AM »
Another problem, can topknot.py be used for a rammer?
(It uses four pistons, but I'd rather not give too much away about my bot, I'm going to soon showcase it)
My above post explains everything about everything.

Host of: Wheely Tag, Back To The Beginnings, BTTB 2, BTTB 3, BTTB 4, & BTTB V.

Heavy Metal: Champion (Mockery of the Whole Concept)
Robotic International Wars Series 1: Champion (Minifridge 6)
RA2 Team Championships 1 & 2: Champion (High Speed Train & Upthrust - as part of Naryar's Not Quite Evil Council of Doom)

Runner Up in: The Amazing Rage (Team Fedex), R0B0NOVA (Zaphod Stock), Steel Warzone (Inception of Instability), Box of Nightmares (Gicquel), Wheely Tag (Minifridge the Second)

Clash Cubes IV: 5th place (Fretless)
BBEANS 6: Rumble Winner & 6th Place (Minifridge 4)