Jump to content

como crear Tablas


iFoReX

Recommended Posts

Posted
Buee como dice en el titulo siempre e querido aprender como crear tablas y para que sirven :D

tablas para expresar distintos datos para un math.random o hablas de las tablas de SQL que ordenan la informacion??

Developer @ MYVAL

Posted
nose ._.

jajaj es que puede ser tablas como las de:

local tablexd = 411, 410, 308 --Distintos ID 
  
function Vehiculocrear 
  
createVehicle ( math.random(#tablexd), 272, 384, 55, 0, 0, 90 ) --se Crearia Aleatoriamente un vehiculo con ID de los de arriba. 
  
addEventHandler("onResourceStart",Vehiculocrear) 

Es mejor aprender con otras cosas, esos tutoriales solo me confunden mas

Developer @ MYVAL

Posted

@Alexs_Steel: Eso no es una tabla, es una variable. Ademas tu script nunca funcionaria.

Una tabla es esto:

local table = { 411, 410, 308 } -- Una tabla con diferentes modelos de vehiculos. 
  
function Vehiculocrear ( ) 
    createVehicle ( table[ math.random ( #table ) ], 0, 0, 5 ) -- Crea un vehiculo un modelo aleatorio de la tabla. 
end 
addEventHandler ( "onResourceStart",resourceRoot, Vehiculocrear ) 

San Andreas Utopia RPG (SAUR) Owner & Developer.

560x95_FFFFFF_FF9900_000000_000000.png

Education is the most powerful weapon which you can use to change the world.

Posted
OK Y EL 0, 0, 5 que hace ?

Coordenadas de creacion del vehiculo xDD

PD: Tomalo como si fuera un createVehicle normal, pero en vez de un modelo lleva 3 que son creados aleatoriamente (random = aleatorio)

Developer @ MYVAL

Posted

Apenas entendes los argumentos de las funciones, no te aconsejo intentar estudiar MySQL aun.

San Andreas Utopia RPG (SAUR) Owner & Developer.

560x95_FFFFFF_FF9900_000000_000000.png

Education is the most powerful weapon which you can use to change the world.

Posted
dbConnect 
dbExec 
dbQuery 
dbPoll 
dbFree 

Clickea en cada funcion, tienen ejemplos.

San Andreas Utopia RPG (SAUR) Owner & Developer.

560x95_FFFFFF_FF9900_000000_000000.png

Education is the most powerful weapon which you can use to change the world.

Posted

Vos me estas tomando el pelo? querias estudiar lo basico de MySQL y te di las funciones para hacerlo.

San Andreas Utopia RPG (SAUR) Owner & Developer.

560x95_FFFFFF_FF9900_000000_000000.png

Education is the most powerful weapon which you can use to change the world.

Posted

Tema cerrado.

San Andreas Utopia RPG (SAUR) Owner & Developer.

560x95_FFFFFF_FF9900_000000_000000.png

Education is the most powerful weapon which you can use to change the world.

Guest
This topic is now closed to further replies.
  • Recently Browsing   0 members

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