Jump to content




(Openperipherals For Mc 1.6.2) Robot / Mech Target Program


4 replies to this topic

#1 darkrising

  • Members
  • 234 posts
  • LocationScotland

Posted 30 September 2013 - 01:29 AM

Hi all, this is just a simple program I wrote which allows the newly added robots from OpenPeripherals to shoot at a specific player.

I also added a yaw fix so the robot hits the player.

I'm working on a predictive movement program too but thought you might be interesting in what I have so far. :)/>/>

Code:
Spoiler

If you don't know how to use OpenPeripheral Mechs, just place down a robot contoller next to a computer, right click to open it and place your robot inside, this will give it an ID.

You then wrap the peripheral and use the robot ID in each function you want to execute.

Screenshot:
Posted Image

Pretty cool huh? :P/>/>


Note: If you want an API list for the mechs I made one on my wiki!

Edited by darkrising, 02 January 2014 - 04:27 PM.


#2 TechMasterGeneral

  • Members
  • 149 posts
  • LocationUnited States

Posted 11 November 2013 - 10:18 PM

Do you have a pastebin code?

#3 kelevra.1337

  • Members
  • 31 posts

Posted 02 January 2014 - 04:11 PM

Hey darkrising,

I also made some mech Utils lately, including a basic prefire system, getting and sorting a list of mobs nearby and such.
If youre interested in using/improving it i could post the pastebin here

#4 darkrising

  • Members
  • 234 posts
  • LocationScotland

Posted 02 January 2014 - 04:14 PM

View Postkelevra.1337, on 02 January 2014 - 04:11 PM, said:

Hey darkrising,

I also made some mech Utils lately, including a basic prefire system, getting and sorting a list of mobs nearby and such.
If youre interested in using/improving it i could post the pastebin here

Sounds interesting, ye sure drop me a pastebin link :)

#5 kelevra.1337

  • Members
  • 31 posts

Posted 02 January 2014 - 04:32 PM

http://pastebin.com/3CYg39b1

its pretty messy but it should work.....

getMobsByType(id,type) adds "id" to the content of the table so you can easily get mob IDs by doing

local mobs = getMobsByType(0,"Chicken")
local id = mobs[1]["id"]

The prefire (fixedIterations(id, mobID,projectileVel)) isnt really reliable but works technically:







1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users