Aller au contenu

SOS probleme script wiimote pc (glovepie)


lyokohack

Messages recommandés

salut a vous a tout les gens de la generation de la wii

 

voila j'ai acheter un wiimote blanche et je veut l'utiliser au pc comme une souris

 

j'ai réussi a l’intégrer au pc via bluesoleil

 

mais mon vrais souci c'est un j'ai pas un bon script pour glovepie

 

j'ai regarder une vidéo l'a dedans

https://www.youtube.com/watch?v=Ptk8AF82POk

 

et ce gars n'utilise pas de sensor bar et il a un mouvement parfait

 

j'ai essayer de chercher son script sur Google de ne pas me tremper le voici qui s’appelle :

 

WiiMoseAccel

 

//Mouse Control Script
//by vkapadia
//vkapadia@vkapadia.com
//
//Calibration:
//Change these values until the debug line says all zeros when the wiimote is at rest.
var.trimx = 6
var.trimy = -31
var.trimz = 6
//
//Controls:
//Tilt Wiimote Up and Down = Move Mouse Up and Down
//Rotate Wiimote Left and Right = Move Mouse Left and Right
//D-Pad = Arrow Keys
//B-Button = Left Click
//Home = Middle Click
//A-Button = Right Click
//Plus and Minus = Control Volume
//One = Play/Pause (I have Win+C set to do that in Winamp.)
//Two = Next Song (I have Win+N set to do that in Winamp.) 
//
//If the pointer hits the edge of the screen, the Wiimote will rumble a bit.
//
//The LEDs attempt to emulate KITT's grill from Knight Rider

//Set the D-Pad to function as the Arrow Keys
if wiimote.Up
Up = true
Wait 200 ms
Up = false
endif
if wiimote.Down
Down = true
Wait 200 ms
Down = false
endif
if wiimote.Left
Left = true
Wait 200 ms
Left = false
endif
if wiimote.Right
Right = true
Wait 200 ms
Right = false
endif

//Mouse Buttons
Mouse.RightButton = Wiimote.A
Mouse.LeftButton = Wiimote.B
Mouse.MiddleButton = Wiimote.Home

//Plus and Minus handle Volume
if wiimote.plus then
  volumeup = true
  wait 60 ms
  volumeup = false
endif
if wiimote.minus then
  volumedown = true
  wait 60 ms
  volumedown = false
endif

//Winamp Hotkeys (Win+C = Play/Pause; Win+N = Next Song)
Windows+C = wiimote.One
Windows+N = wiimote.Two

//TODO: not satisfied with wiimote.One
//TODO: not satisfied with wiimote.Two
//TODO: not satisfied with wiimote.Plus
//TODO: not satisfied with wiimote.Minus
//TODO: not satisfied with wiimote.Home

//LEDs look somewhat like KITT's grill from Knight Rider
if 0 = 0 then
if var.kitt = 0 then
wiimote.Leds = 1
//wait 200 ms
endif
if var.kitt = 1 then
wiimote.Leds = 3
endif
if var.kitt = 2 then
wiimote.Leds = 6
endif
if var.kitt = 3 then
wiimote.Leds = 12
endif
if var.kitt = 4 then
wiimote.Leds = 8
//wait 200 ms
endif
if var.kitt = 5 then
wiimote.Leds = 12
endif
if var.kitt = 6 then
wiimote.Leds = 6
endif
if var.kitt = 7 then
wiimote.Leds = 3
endif
wait 100 ms
var.kitt = (var.kitt + 1) % 8
endif

//If the mouse reaches the end, rumble for 200 milliseconds
if mouse.x = 0 or mouse.x = 1 or mouse.y = 0 or mouse.y = 1 then
if var.rmbl = false
wiimote.Rumble = 1
wait 200 ms
wiimote.Rumble = 0
endif
var.rmbl = true
else
var.rmbl = false
endif

//****Everything past here deals with mouse movement*****

// set these to the offsets when the wiimote is at rest
// will be different for each wiimote most likely
var.x = Wiimote.RawForceX + var.trimx //trim to 0
var.y = Wiimote.RawForceY + var.trimy // trim to 0
var.z = Wiimote.RawForceZ + var.trimz //trim to 0

//precision
var.sense0 = 500
var.thresh0x = 5
var.thresh0y = 2

var.sense = 300
var.threshx = 10
var.threshy = 5

var.sense2 = 100
var.thresh2x = 15
var.thresh2y = 8

var.sense3 = 50
var.thresh3x = 20
var.thresh3y = 12

//first sensitivity setting
//xaxis
if var.x > var.thresh0x
mouse.x = mouse.x - 1/var.sense0
endif
if var.x < -var.thresh0x
mouse.x = mouse.x + 1/var.sense0
endif

//yaxis
if var.z > var.thresh0y
mouse.y = mouse.y - 1/var.sense0
endif
if var.z < -var.thresh0y
mouse.y = mouse.y + 1/var.sense0
endif


//second sensitivity setting
//xaxis
if var.x > var.threshx
mouse.x = mouse.x - 1/var.sense
endif
if var.x < -var.threshx
mouse.x = mouse.x + 1/var.sense
endif

//yaxis
if var.z > var.threshy
mouse.y = mouse.y - 1/var.sense
endif
if var.z < -var.threshy
mouse.y = mouse.y + 1/var.sense
endif

//third sensitivity setting
//xaxis
if var.x > var.thresh2x
mouse.x = mouse.x - 1/var.sense2
endif
if var.x < -var.thresh2x
mouse.x = mouse.x + 1/var.sense2
endif

//yaxis
if var.z > var.thresh2y
mouse.y = mouse.y - 1/var.sense2
endif
if var.z < -var.thresh2y
mouse.y = mouse.y + 1/var.sense2
endif

//fourth sensitivity setting
//xaxis
if var.x > var.thresh3x
mouse.x = mouse.x - 1/var.sense3
endif
if var.x < -var.thresh3x
mouse.x = mouse.x + 1/var.sense3
endif

//yaxis
if var.z > var.thresh3y
mouse.y = mouse.y - 1/var.sense3
endif
if var.z < -var.thresh3y
mouse.y = mouse.y + 1/var.sense3
endif

debug = var.x + " " + var.y + " " + var.z

 

le problème c'est que il m’éjecte le curseur en haut a gauche de l'ecran et il reviens vite a ce repaire et je suis obliger de se déconnecter de la session

 

j'ai aussi utiliser ce scripte l'a qui n'essecite la sensor bar

// Wiimote mouse script for Windows desktop
// Requires a sensor bar

var.ButtonFreezeTime = 250ms
var.PointerBump = KeepDown(Pressed(wiimote.A),var.ButtonFreezeTime) or KeepDown(Pressed(wiimote.B),var.ButtonFreezeTime)
Wiimote.Led1 = true

// Mouse movement
if wiimote.PointerVisible but not var.PointerBump then
 mouse.x = wiimote.PointerX
 mouse.y = wiimote.PointerY
end if

// Mouse Buttons
mouse.LeftButton = Wiimote.A and KeepDown(Wiimote.PointerVisible,0.5s)
mouse.RightButton = Wiimote.B and KeepDown(Wiimote.PointerVisible,0.5s)
mouse.MiddleButton = Wiimote.Home and KeepDown(Wiimote.PointerVisible,0.5s)
mouse.XButton1 = Wiimote.Minus
mouse.XButton2 = Wiimote.Plus

// Mouse Wheel
if wiimote.Up then
 mouse.WheelUp = true
 wait 30ms
 mouse.WheelUp = false
 wait 30ms
end if
if wiimote.Down then
 mouse.WheelDown = true
 wait 30ms
 mouse.WheelDown = false
 wait 30ms
end if

 

mai j'ai utiliser deux bougie ca a marcher pas bien le curseur part très vite et je le manie très difficilement

 

et je suis désoler pour l’orthographe car je ne le maitrise pas bien

 

j'usqu'a present j'ai pu crée de faire un clique droit et gauche et le bouton demarer de Windows

 

est ce qu'il ya un espoirs pour résoudre ca ?

Modifié par lyokohack
Lien vers le commentaire
Partager sur d’autres sites

Veuillez vous connecter pour commenter

Vous pourrez laisser un commentaire après vous êtes connecté.



Connectez-vous maintenant
  • Statistiques des membres

    23 028
    Total des membres
    963
    Maximum en ligne
    Subaru
    Membre le plus récent
    Subaru
    Inscription
  • Statistiques des forums

    128,1 k
    Total des sujets
    1,7 M
    Total des messages
×
×
  • Créer...