WiiLi Wiki frontpage Include your post in the News Get links Hoteles Quito
WiiLi.org Forum Index WiiLi.org
a new revolution
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Problem with wow script.

 
Post new topic   Reply to topic    WiiLi.org Forum Index -> Wii Scripts
View previous topic :: View next topic  
Author Message
Demolition49



Joined: 03 Jan 2007
Posts: 8

Digg It
PostPosted: Wed Jan 03, 2007 6:34 pm    Post subject: Problem with wow script.

So i was browsing through youtube, and i found a video about using your wii mote with wow, when i saw this vid i was quite amazed.

So i researched in to doing so with my computer.

I have glovepie and i am using Deetees GlovePIE wow script i obtained this from the axemen wow clan site (cant post link)

here is the script

Quote:

// Original code by Kasten
// Modified to fit the needs of Deetee.

/* Here you want to change the offset so it matches your mote. To do this, you
first have to put the wiimote down on a flat surface, then running the script.

When running the script, you will notice some X, Y, Z numbers on the rightside
of the run button. You want these to be 0,28,0 - so change the numbers under
to make your X,Y,Z fit these.

My numbers were -2, 30, -4 so I changed them to 0,28,0 by setting
x to 2
y to -2
z to 4

After you have done this, push the run button to make sure its 0,28,0.*/

var.xOffset = 2
var.yOffset = -2
var.zOffset = 4

// This controls the cursorspeed - set it higher to get faster mouseaction.
var.speed = 1

// These settings controls the jittering of the control. If you have very steady
// hands, you can lower these settings, if you are a very jittery person
// ( like the one in duskwood ) you set the values higher
var.xCutoff = 4
var.zCutoff = 4

// Sets the mote straight by using the offset we used as inputs earlier in
// the script, and print it out at the debug screen.
var.xRot = Wiimote.RawForceX + var.xOffset
var.yRot = Wiimote.RawForceY + var.yOffset
var.zRot = Wiimote.RawForceZ + var.zOffset

debug = 'X:' + var.xRot + ', ' + 'Y:' + var.yRot + ', ' + 'Z:' + var.zRot

// The code for making the mouse move. Incorporates mouse x,y to the wiimotes
// X,Y,Z system
if var.xRot > var.xCutoff then mouse.x = mouse.x - .001 * var.speed * (var.xRot - var.xCutoff)
if var.xRot < -var.xCutoff then mouse.x = mouse.x - .001 * var.speed * (var.xRot + var.xCutoff)
if var.zRot > var.zCutoff then mouse.y = mouse.y - .001 * var.speed * (var.zRot - var.zCutoff)
if var.zRot < -var.zCutoff then mouse.y = mouse.y - .001 * var.speed * (var.zRot + var.zCutoff)

// Setting up the wiimote so that the controls on top of the wiimote works
// as WASD that is commonly used in FPS and other games.
w = Wiimote.Up
s = Wiimote.Down
a = Wiimote.Left
d = Wiimote.Right

// Here I set the nunchuk so it corresponts with my direction keys.
Right = 1 > Wiimote1.Nunchuk.JoyX > 0.5
Left = -1 < Wiimote1.Nunchuk.JoyX < -0.5
down = 1 > Wiimote1.Nunchuk.JoyY > 0.5
up = -1 < Wiimote1.Nunchuk.JoyY < -0.5

// Bind some keys to the mote, you can bind your own.
h = Wiimote.Plus
q = Wiimote.Minus
tab = Wiimote.Home
j = Wiimote.One
k = Wiimote.Two
// Nunchuck
u = Wiimote.Nunchuk.CButton
f = Wiimote.Nunchuk.ZButton
// B for left click and A for right click
mouse.LeftButton = Wiimote.B
mouse.RightButton = Wiimote.A

// You can use a combination of keys by adding a + in between, like this - if
// you want to bind one of the buttons for SHIFT+Loot.
// shift + mouse.RightButton = Wiimote.A

// Nothin' like a little rumblin'
Wiimote.Rumble = Wiimote.A

// Using the leds when pressing the buttons. Almost like having a GF.
Wiimote.Led1 = w
Wiimote.Led2 = s
Wiimote.Led3 = a
Wiimote.Led4 = d
Wiimote.Led1 = j
Wiimote.Led2 = k
Wiimote.Led3 = h
Wiimote.Led4 = alt+g

// Sets the wiimote rotation bindings - for jumping and mounting.
// By flicking it upwards, you jump
// By flicking it to the side, you mount ( or whatever you bound to alt+g ).
// You could probably do an Z rotation too, but that movement is strictly
// for watching pr0n.
if var.yRot >= 100 then space = true else space = false
if var.xRot >= 100 then alt+g = true else alt+g = false


After setting up my wii mote all the button configurations worked great.

except my nunchuck attachment, the analogue stick does not recognise going foward (the analogue stick is in the groove) if i move it slightly left or right away from the groove that guide your analogue foward it will recognise this as foward. All other left right and backward movments work fine. I would really appriecieate the help.

I would also like to change the script so i can use the ir sensor bar for mouse movment instead of the motion sensor.

I am also unfamiliar with glovepie script and understand the basics. are there any tutorials about so i can get started and make my own script.

Thankyou.
_________________
-----------------------------------------
Back to top
View user's profile Send private message
phlanx



Joined: 04 Jan 2007
Posts: 1

Digg It
PostPosted: Thu Jan 04, 2007 8:13 am    Post subject:

Hello! I have used parts of that script for DAoC and also had problems and then came up with this after using the debug line to find out that my joystick reports -1.04 when it is all the way to the left! Laughing So try replacing this part of your script:

// Here I set the nunchuk so it corresponts with my direction keys.
Right = Wiimote1.Nunchuk.JoyX > 0.5
Left = Wiimote1.Nunchuk.JoyX < -0.5
down = Wiimote1.Nunchuk.JoyY > 0.5
up = Wiimote1.Nunchuk.JoyY < -0.5

As for IR, I still have to build my own sensor bar before i can try it Crying or Very sad

phlanx
Back to top
View user's profile Send private message
kunalkunal2



Joined: 13 Dec 2006
Posts: 279

Digg It
PostPosted: Thu Jan 04, 2007 3:27 pm    Post subject:

phlanx wrote:

// Here I set the nunchuk so it corresponts with my direction keys.
Right = Wiimote1.Nunchuk.JoyX > 0.5
Left = Wiimote1.Nunchuk.JoyX < -0.5
down = Wiimote1.Nunchuk.JoyY > 0.5
up = Wiimote1.Nunchuk.JoyY < -0.5


those commands dont work just as well that way (well thats for me).
because the up key and the down key are kinda messed up, but it is different for other people.
so why dont you try this

Code:

left = (-1.2 < wiimote.Nunchuk.JoyX < -0.5)
right = (0.5 < wiimote.Nunchuk.JoyX < 1.2)
Y = (-1.2 < wiimote.Nunchuk.JoyY < -0.5)
H = (0.5 < wiimote.Nunchuk.JoyY < 1.2)
Back to top
View user's profile Send private message
Demolition49



Joined: 03 Jan 2007
Posts: 8

Digg It
PostPosted: Thu Jan 04, 2007 3:52 pm    Post subject: Many thanks.

Many thanks guys, kunalkunal2 your script worked! im really pleased i can play wow properly now, it fixed the up and down problem.

Now all i need to do is mod the mouse cursor for the sensor bar.

P.S have any of you tryed using the script for counter strike source?

Again many thanks to you guys and carl kenner for making this possible.
_________________
-----------------------------------------
Back to top
View user's profile Send private message
Demolition49



Joined: 03 Jan 2007
Posts: 8

Digg It
PostPosted: Thu Jan 04, 2007 6:30 pm    Post subject: Script so far.

OK! so all i need now is to mod this script so glovepie recognises my movements using my sensor bar (2 candles LOL).

Here is what i have so far... any one know how i can change it to move the mouse using ir sensor.

Quote:

// Original code by Kasten
// Modified to fit the needs of Deetee.
// Re-Modified to fit needs of Demolition49 by Demolition49.

/* Here you want to change the offset so it matches your mote. To do this, you
first have to put the wiimote down on a flat surface, then running the script.

When running the script, you will notice some X, Y, Z numbers on the rightside
of the run button. You want these to be 0,28,0 - so change the numbers under
to make your X,Y,Z fit these.

My numbers were -2, 30, -4 so I changed them to 0,28,0 by setting
x to 2
y to -2
z to 4

After you have done this, push the run button to make sure its 0,28,0.*/

var.xOffset = 2
var.yOffset = -2
var.zOffset = 4

// This controls the cursorspeed - set it higher to get faster mouseaction.
var.speed = 1

// These settings controls the jittering of the control. If you have very steady
// hands, you can lower these settings, if you are a very jittery person
// ( like the one in duskwood ) you set the values higher
var.xCutoff = 4
var.zCutoff = 4

// Sets the mote straight by using the offset we used as inputs earlier in
// the script, and print it out at the debug screen.
var.xRot = Wiimote.RawForceX + var.xOffset
var.yRot = Wiimote.RawForceY + var.yOffset
var.zRot = Wiimote.RawForceZ + var.zOffset

debug = 'X:' + var.xRot + ', ' + 'Y:' + var.yRot + ', ' + 'Z:' + var.zRot

// The code for making the mouse move. Incorporates mouse x,y to the wiimotes
// X,Y,Z system
if var.xRot > var.xCutoff then mouse.x = mouse.x - .001 * var.speed * (var.xRot - var.xCutoff)
if var.xRot < -var.xCutoff then mouse.x = mouse.x - .001 * var.speed * (var.xRot + var.xCutoff)
if var.zRot > var.zCutoff then mouse.y = mouse.y - .001 * var.speed * (var.zRot - var.zCutoff)
if var.zRot < -var.zCutoff then mouse.y = mouse.y - .001 * var.speed * (var.zRot + var.zCutoff)

// Setting up the wiimote so that the controls on top of the wiimote works
// as WASD that is commonly used in FPS and other games.
w = Wiimote.Up
s = Wiimote.Down
a = Wiimote.Left
d = Wiimote.Right

// Here I set the nunchuk so it corresponts with my direction keys.
left = (-1.2 < wiimote.Nunchuk.JoyX < -0.5)
right = (0.5 < wiimote.Nunchuk.JoyX < 1.2)
up = (-1.2 < wiimote.Nunchuk.JoyY < -0.5)
down = (0.5 < wiimote.Nunchuk.JoyY < 1.2)

// Bind some keys to the mote, you can bind your own.
h = Wiimote.Plus
q = Wiimote.Minus
tab = Wiimote.Home
j = Wiimote.One
k = Wiimote.Two
// Nunchuck
u = Wiimote.Nunchuk.CButton
f = Wiimote.Nunchuk.ZButton
// B for left click and A for right click
mouse.LeftButton = Wiimote.A
mouse.RightButton = Wiimote.B

// You can use a combination of keys by adding a + in between, like this - if
// you want to bind one of the buttons for SHIFT+Loot.
// shift + mouse.RightButton = Wiimote.A

// Nothin' like a little rumblin'
Wiimote.Rumble = Wiimote.A

// Using the leds when pressing the buttons. Almost like having a GF.
Wiimote.Led1 = w
Wiimote.Led2 = s
Wiimote.Led3 = a
Wiimote.Led4 = d
Wiimote.Led1 = h
Wiimote.Led2 = j
Wiimote.Led3 = k
Wiimote.Led4 = l

// Sets the wiimote rotation bindings - for jumping and mounting.
// By flicking it upwards, you jump
// By flicking it to the side, you mount ( or whatever you bound to alt+g ).
// You could probably do an Z rotation too, but that movement is strictly
// for watching pr0n.
if var.yRot >= 100 then space = true else space = false
if var.xRot >= 100 then alt+g = true else alt+g = false


Thanks for all your help.l
_________________
-----------------------------------------
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    WiiLi.org Forum Index -> Wii Scripts All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group