Skip to content

Instantly share code, notes, and snippets.

Avatar
😎
I love to code and can do it all day long ;)

Dilmer Valecillos dilmerv

😎
I love to code and can do it all day long ;)
View GitHub Profile
@dilmerv
dilmerv / TelloState.py
Created September 1, 2021 21:44
Tello State with Python
View TelloState.py
import socket
from time import sleep
INTERVAL = 0.2
if __name__ == "__main__":
local_ip = ''
local_port = 8890
socket = socket.socket(socket.AF_INET, socket.SOCK_DGRAM) # socket for sending cmd
View ARPlacementInteractableSingle.cs
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.XR.ARFoundation;
using UnityEngine.XR.ARSubsystems;
using UnityEngine.XR.Interaction.Toolkit.AR;
public class ARPlacementInteractableSingle : ARBaseGestureInteractable
{
[SerializeField]
[Tooltip("A GameObject to place when a raycast from a user touch hits a plane.")]
@dilmerv
dilmerv / PlacementWithManySelectionWithScaleController.cs
Created February 5, 2020 23:55
Enforcing one object selection and scaling
View PlacementWithManySelectionWithScaleController.cs
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.EventSystems;
using UnityEngine.UI;
using UnityEngine.XR.ARFoundation;
[RequireComponent(typeof(ARRaycastManager))]
public class PlacementWithManySelectionWithScaleController : MonoBehaviour
{
[SerializeField]
@dilmerv
dilmerv / OculusBuildProcessor.cs
Created December 21, 2019 19:31
Oculus Build Processor Changes Required to Get Oculus Unity Integration to work with version 12
View OculusBuildProcessor.cs
#if UNITY_ANDROID
using System.Reflection;
using System.Xml;
using UnityEngine;
using UnityEngine.Rendering;
using UnityEditor.Android;
using UnityEditor.Build;
using UnityEditor.Build.Reporting;
namespace UnityEditor.XR.Oculus
View AndroidManifest.xml
<?xml version="1.0" encoding="utf-8" standalone="no"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
android:installLocation="auto">
<uses-feature android:name="android.hardware.vr.headtracking" android:version="1" android:required="true" /><!-- Request the headset DoF mode -->
<uses-feature android:name="oculus.software.handtracking" android:required="true" /><uses-permission android:name="oculus.permission.handtracking" /><!-- Request the headset handtracking mode -->
<application
android:label="@string/app_name"
android:icon="@mipmap/app_icon">
<activity
android:theme="@android:style/Theme.Black.NoTitleBar.Fullscreen"
View vwCustomerUpload.sql
CREATE VIEW [dbo].[vwCustomerUpload]
AS
SELECT
MAX([ocp].[OnlineCustomerPersonID]) as [OnlineCustomerPersonID],
MAX([ocp].[Email]) as [Email],
MAX([ocp].[Password]) as [Password],
MAX([ocp].[DemoID]) as [DemoID],
MAX([ocp].[FirstName]) as [FirstName],
MAX([ocp].[LastName]) as [LastName],
@dilmerv
dilmerv / Build.sh
Created July 25, 2017 22:05
Build.sh for MAC
View Build.sh
#!/bin/bash
echo "Copying provisioning profile..."
cp ./embedded.provisionprofile ./Cubiques.app/Contents/
echo "Copying plist template..."
cp ./Info.plist ./Cubiques.app/Contents/
echo "Starting Signing..."
codesign -f --deep -s "3rd Party Mac Developer Application: Dilmer Valecillos" --entitlements "./Cubiques.entitlements" ./Cubiques.app/Contents/Frameworks/MonoEmbedRuntime/osx/libmono.0.dylib
codesign -f --deep -s "3rd Party Mac Developer Application: Dilmer Valecillos" --entitlements "./Cubiques.entitlements" ./Cubiques.app/Contents/Frameworks/MonoEmbedRuntime/osx/libMonoPosixHelper.dylib
@dilmerv
dilmerv / MAC_Build_Sign_Game.sh
Created March 29, 2017 05:21
MAC_Build_Sign_Game.sh
View MAC_Build_Sign_Game.sh
#!/bin/bash
echo "Copying provisioning profile..."
cp ./embedded.provisionprofile ./YourGameName.app/Contents/
echo "Starting Signing..."
codesign -f --deep -s "3rd Party Mac Developer Application: [Your Name]" --entitlements "./YourGameName.entitlements" ./YourGameName.app/Contents/Frameworks/MonoEmbedRuntime/osx/libmono.0.dylib
codesign -f --deep -s "3rd Party Mac Developer Application: [Your Name]" --entitlements "./YourGameName.entitlements" ./YourGameName.app/Contents/Frameworks/MonoEmbedRuntime/osx/libMonoPosixHelper.dylib
codesign -f --deep -s "3rd Party Mac Developer Application: [Your Name]" --entitlements YourGameName.entitlements "./YourGameName.app/"
echo "Done Signing..."
@dilmerv
dilmerv / YourGameName.entitlements
Created March 29, 2017 05:19
YourGameName.entitlements
View YourGameName.entitlements
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>com.apple.security.app-sandbox</key>
<true/>
<key>com.apple.developer.game-center</key>
<true/>
</dict>
</plist>
@dilmerv
dilmerv / MAC_Build_Plist_Example.plist
Created March 29, 2017 05:11
MAC_Build_Plist_Example.plist
View MAC_Build_Plist_Example.plist
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>English</string>
<key>CFBundleExecutable</key>
<string>[YourGameName]</string>
<key>CFBundleGetInfoString</key>
<string>Your Game Name (c) 2017 Dilmer Games. All rights reserved.</string>