Jump to content

Code for absolute Zero Camera Movement?


Gimp

Recommended Posts

So i've remade one of my old scripts and it works 100%. But it is slowed down by the client randomly turning the camera, before attacking an npc, before clicking the bank booth, etc. Is there a code to just keep the camera angle in one position the whole time throughout every interaction like below? Thx

 

 

skuB8CF.png

Link to comment
Share on other sites

k I'll write you a snippet below using (without IDE so please forgive and typos) - I'm on mobile too lol

RS2Object o = objects.closest("Bank");

//null checks here blah

InteractionEvent e = new InteractionEvent(o,"Use");

e.setOperateCamera(false);

execute(e);

Apa

PS you should read up on interaction event here - http://osbot.org/api/org/osbot/rs07/event/InteractionEvent.html#setOperateCamera-boolean-

It's really useful

Edited by Apaec
  • Like 1
Link to comment
Share on other sites

k I'll write you a snippet below using (without IDE so please forgive and typos) - I'm on mobile too lol

RS2Object o = objects.closest("Bank");

//null checks here blah

InteractionEvent e = new InteractionEvent(o,"Use");

e.setOperateCamera(false);

execute(e);

Apa

PS you should read up on interaction event here - http://osbot.org/api/org/osbot/rs07/event/InteractionEvent.html#setOperateCamera-boolean-

It's really useful

 

Thx, i couldn't understand how to use them properly

Link to comment
Share on other sites

k I'll write you a snippet below using (without IDE so please forgive and typos) - I'm on mobile too lol

RS2Object o = objects.closest("Bank");

//null checks here blah

InteractionEvent e = new InteractionEvent(o,"Use");

e.setOperateCamera(false);

execute(e);

Apa

PS you should read up on interaction event here - http://osbot.org/api/org/osbot/rs07/event/InteractionEvent.html#setOperateCamera-boolean-

It's really useful

 

Works perfectly, thank you

  • Like 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...