Autor |
Mensagem |
Matheus Dantas
Usuário
![Usuário Usuário](images/2.gif)
![](images/avatars/9671607557d6df3908f8f.gif)
Registrado: 23/04/13 Mensagens: 249 Localização: São Paulo, Mogi das Cruzes |
|
|
Sex Out 03, 2014 11:41 pm |
![Exibir perfil de usuários Exibir perfil de usuários](templates/Jet/images/lang_english/icon_profile.gif) |
![](templates/Jet/images/spacer.gif) |
Matheus Dantas
Usuário
![Usuário Usuário](images/2.gif)
![](images/avatars/9671607557d6df3908f8f.gif)
Registrado: 23/04/13 Mensagens: 249 Localização: São Paulo, Mogi das Cruzes |
|
Foi mal |
|
Acabei criando as solução sem querer... Mas obrigado mesmo assim
![](templates/Jet/images/code_header.gif) | ![](templates/Jet/images/spacer.gif) | //Botão A
if iskeypress(65) = false then
begin
WriteGlobalVar('atk_time',0);
end;
if iskeypress(65) = true then
begin
WriteGlobalVar('atk_time', ReadGlobalVar('atk_time')+1);
if ReadGlobalVar('atk_time') = 1 then
begin
loadmainactorweapon('Chute');
SetObjectAnimationMode('MainActor', 'Loop');
end;
if ReadGlobalVar('atk_time') = 50 then
begin
SetObjectAnimationMode('MainActor', 'PlayOnce');
end;
if ReadGlobalVar('atk_time') = 100 then
begin
loadmainactorweapon('Sem Arma');
SetObjectAnimationMode('MainActor', 'Loop');
end;
end;
//
//Botão S
if iskeypress(83) = false then
begin
WriteGlobalVar('atk_time2',0);
end;
if iskeypress(83) = true then
begin
WriteGlobalVar('atk_time2', ReadGlobalVar('atk_time2')+1);
if ReadGlobalVar('atk_time2') = 1 then
begin
loadmainactorweapon('Soco');
SetObjectAnimationMode('MainActor', 'Loop');
end;
if ReadGlobalVar('atk_time2') = 50 then
begin
SetObjectAnimationMode('MainActor', 'PlayOnce');
end;
if ReadGlobalVar('atk_time2') = 200 then
begin
loadmainactorweapon('Sem Arma');
SetObjectAnimationMode('MainActor', 'Loop');
end;
end;
//
/////////////////////////////////////////////////////////////////////////////
if ReadGlobalVar('atk_time') > 1 then
begin
//
if iskeypress(38) = true then
begin
SetObjectAnimationMode('MainActor', 'PlayOnce');
end;
if iskeypress(40) = true then
begin
SetObjectAnimationMode('MainActor', 'PlayOnce');
end;
if iskeypress(37) = true then
begin
SetObjectAnimationMode('MainActor', 'PlayOnce');
end;
if iskeypress(39) = true then
begin
SetObjectAnimationMode('MainActor', 'PlayOnce');
end;
//
end;
//
//
if ReadGlobalVar('atk_time2') > 1 then
begin
//
if iskeypress(38) = true then
begin
SetObjectAnimationMode('MainActor', 'PlayOnce');
end;
if iskeypress(40) = true then
begin
SetObjectAnimationMode('MainActor', 'PlayOnce');
end;
if iskeypress(37) = true then
begin
SetObjectAnimationMode('MainActor', 'PlayOnce');
end;
if iskeypress(39) = true then
begin
SetObjectAnimationMode('MainActor', 'PlayOnce');
end;
//
end;
/////////////////////////////////////////////////////
if ReadGlobalVar('atk_time') > 100 then
begin
if iskeypress(38) and iskeypress(38) then
begin
//
if iskeypress(38) = true then
begin
SetObjectAnimationMode('MainActor', 'Loop');
end;
if iskeypress(40) = true then
begin
SetObjectAnimationMode('MainActor', 'Loop');
end;
if iskeypress(37) = true then
begin
SetObjectAnimationMode('MainActor', 'Loop');
end;
if iskeypress(39) = true then
begin
SetObjectAnimationMode('MainActor', 'Loop');
end;
//
end;
//
end;
////////////////////////////////////////////////////
if ReadGlobalVar('atk_time2') > 200 then
begin
if iskeypress(38) and iskeypress(38) then
begin
//
if iskeypress(38) = true then
begin
SetObjectAnimationMode('MainActor', 'Loop');
end;
if iskeypress(40) = true then
begin
SetObjectAnimationMode('MainActor', 'Loop');
end;
if iskeypress(37) = true then
begin
SetObjectAnimationMode('MainActor', 'Loop');
end;
if iskeypress(39) = true then
begin
SetObjectAnimationMode('MainActor', 'Loop');
end;
//
end;
//
end;
////////////////////////////////////////////////////
|
_________________ //Contato
YouTube:
https://www.youtube.com/channel/UCCBpgDU7UrI1V8YvoKg86QA
Wordpress (Projetos):
http://dantasgames.wordpress.com/
Page(Facebook):
https://www.facebook.com/mathdantasgames
Deviantart:
http://dantasgames.deviantart.com/
Profile(Facebook):
https://www.facebook.com/matheus.dantas.1000
Instagram:
matheusdantassantana
Twitter:
@MatheusDantasDG |
|
Sáb Out 04, 2014 12:48 am |
![Exibir perfil de usuários Exibir perfil de usuários](templates/Jet/images/lang_english/icon_profile.gif) |
![](templates/Jet/images/spacer.gif) |
Lima
Usuário
![Usuário Usuário](images/2.gif)
![](images/avatars/1167015805287aa56387d7.jpg)
Registrado: 16/11/13 Mensagens: 100
|
|
|
|
Acho que entendi.. a variável atk-time aumenta de 0 á 50 se você pressiona um botão, e esse é justamente o tempo que a animação demora para acabar, é isso?
|
|
Sex Nov 14, 2014 11:47 am |
![Exibir perfil de usuários Exibir perfil de usuários](templates/Jet/images/lang_english/icon_profile.gif) |
![](templates/Jet/images/spacer.gif) |
Matheus Dantas
Usuário
![Usuário Usuário](images/2.gif)
![](images/avatars/9671607557d6df3908f8f.gif)
Registrado: 23/04/13 Mensagens: 249 Localização: São Paulo, Mogi das Cruzes |
|
|
Sex Nov 14, 2014 4:35 pm |
![Exibir perfil de usuários Exibir perfil de usuários](templates/Jet/images/lang_english/icon_profile.gif) |
![](templates/Jet/images/spacer.gif) |
Lima
Usuário
![Usuário Usuário](images/2.gif)
![](images/avatars/1167015805287aa56387d7.jpg)
Registrado: 16/11/13 Mensagens: 100
|
|
|
|
Eu fiz um parecido há um tempo atrás! mas ele só funcionava em computadores com placa OnBoard, (o meu ainda é), o loop é mais lento nesses computadores!
|
|
Sex Nov 14, 2014 6:57 pm |
![Exibir perfil de usuários Exibir perfil de usuários](templates/Jet/images/lang_english/icon_profile.gif) |
![](templates/Jet/images/spacer.gif) |
welgomes
Usuário
![Usuário Usuário](images/3.gif)
![](images/avatars/95998694250d5d6cb51a5e.png)
Registrado: 10/07/11 Mensagens: 827 Localização: São Paulo - Capital |
|
|
|
Usa o tempo do PC assim como aqueles exemplos: mostrar mensagem por 5 segundos ou mostrar imagem por 5 segundos.
Desta forma não depende da velocidade do computador.
|
|
Sex Nov 14, 2014 7:30 pm |
![Exibir perfil de usuários Exibir perfil de usuários](templates/Jet/images/lang_english/icon_profile.gif) |
![](templates/Jet/images/spacer.gif) |
Lima
Usuário
![Usuário Usuário](images/2.gif)
![](images/avatars/1167015805287aa56387d7.jpg)
Registrado: 16/11/13 Mensagens: 100
|
|
|
|
isso mesmo! valeu cara! sua sugestão foi perfeita! vou fazer isso.
|
|
Sex Nov 14, 2014 8:08 pm |
![Exibir perfil de usuários Exibir perfil de usuários](templates/Jet/images/lang_english/icon_profile.gif) |
![](templates/Jet/images/spacer.gif) |
Matheus Dantas
Usuário
![Usuário Usuário](images/2.gif)
![](images/avatars/9671607557d6df3908f8f.gif)
Registrado: 23/04/13 Mensagens: 249 Localização: São Paulo, Mogi das Cruzes |
|
|
Sáb Nov 15, 2014 12:47 am |
![Exibir perfil de usuários Exibir perfil de usuários](templates/Jet/images/lang_english/icon_profile.gif) |
![](templates/Jet/images/spacer.gif) |
|