zoukankan      html  css  js  c++  java
  • 实战pragmadev的SDL教程

    打开pragmadev,new一个project,在project上添加child element,选择Active architecture的System,语言选择SDL Z100。
    创建一个叫PingPong的系统

    点击PingSide block,画

    点击PongSide block,画

    点击PingPlayer process,画

    点击PongPlayer process,画

    回到项目结构,点击PingPong 系统项,再点击Execute按钮,出现仿真页面,Options-Timers设置为Real time timers,点击按钮调出MSC跟踪树窗口,Run the system运行画出的SDL图,console中出现下述提示

    现在设外界(GameStart)向PingPlayer输入一个包含参数(counter)为5的play消息

    点击发送,PingSide和PongSide开始交互,跟踪的MSC图

    表明最后PingSide赢了。
    如果运行页面的计时器不按上述设置而采用默认方式的话,MSC图跟踪出来的结果是计时器不会有timeout状态,win的状态判断不出来
    本来学弟来请教我计时器问题的,我不会,然后他又教了教我,被助教了:D。

  • 相关阅读:
    基本sql查询语句练习
    SZU:J38 Number Base Conversion
    SZU:B54 Dual Palindromes
    SZU:A66 Plastic Digits
    HOJ:2031 进制转换
    SZU:G34 Love code
    SZU:A25 Favorite Number
    Vijos:P1001谁拿了最多奖学金
    SZU:A26 Anagram
    SZU:A12 Jumping up and down
  • 原文地址:https://www.cnblogs.com/tellw/p/13865194.html
Copyright © 2011-2022 走看看